inversion - How can I reverse the colors of an image with the tool ColorMatrix? -


what values have put in matrix?

dim clmatriz imaging.colormatrix = new imaging.colormatrix(new single()() _ {new single() {¿?, 0, 0, 0, 0}, _  new single() {0, ¿?, 0, 0, 0}, _  new single() {0, 0, ¿?, 0, 0}, _  new single() {0, 0, 0, ¿?, 0}, _  new single() {0, 0, 0, 0, ¿?}) 

though not sure how particular version of color matrix works , if pixel values in range 0-255 or 0-1 here's how should work:

in case pixel range 0-255:

dim clmatriz imaging.colormatrix = new imaging.colormatrix(new single()() _ {new single() {-1, 0, 0, 0, 255}, _ new single() {0, -1, 0, 0, 255}, _ new single() {0, 0, -1, 0, 255}, _ new single() {0, 0, 0, 1, 0}, _ new single() {0, 0, 0, 0, 1}) 

in case 0-1:

dim clmatriz imaging.colormatrix = new imaging.colormatrix(new single()() _ {new single() {-1, 0, 0, 0, 1}, _ new single() {0, -1, 0, 0, 1}, _ new single() {0, 0, -1, 0, 1}, _ new single() {0, 0, 0, 1, 0}, _ new single() {0, 0, 0, 0, 1}) 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -