Forums > Java

JitterMatrix copying


Jun 13 2009 | 9:57 am

I have noticed that there are functions like copyVectorToArray to copy line by line the contents of the JitterMatrix to an array. There are times you need to get all the contents of JitterMatrix to array and process them and put them back.

Is there a function copy contents of JitterMatrix to an array at once?

Jun 13 2009 | 4:29 pm

>>Is there a function copy contents of JitterMatrix to an array at once?

yes, the method CopyMatrixToArray as i sayed to you in the other topic.

Jun 13 2009 | 7:46 pm

In my JitterMatrix I hold an image. When you copy the array using CopyMatrixToArray what is the format it goes to the array
Alpha, r, g , b , …
or
each plane separately like alpha plane first, then red plane etc

Jun 14 2009 | 8:57 am

it’s Alpha, r, g , b , …

Jun 16 2009 | 5:27 pm

I used following code to modify the array content. What I expected was a dimmed image but the output was totally different. Am I processing the array properly?

int[] rippleAllPlanes         = new int[width*height*planecount];

back_draw.copyMatrixToArray(rippleAllPlanes);

for (int y=0;y

Jun 17 2009 | 10:45 am

i think you’re wrong on this line:

for (int k=1;k

i should be:

for (int k=0;k

(ex: if it’s 4 planes, it’s 0 to 3 … )

Jun 17 2009 | 10:55 am

I didn’t want to change the alpha value that is why I started from 1. It is the first element in right?

Do you see anything else wrong?

Jun 17 2009 | 11:16 am

It is the first element in right? yes

Do you see anything else wrong? no,sorry..

Jun 17 2009 | 11:19 am

Do you have a sample program processing an array like this?

Jun 17 2009 | 11:28 am
Sep 14 2012 | 3:27 pm

Wijesijp’s code is working fine here.

Viewing 11 posts - 1 through 11 (of 11 total)

Forums > Java