I have a problem about using GFOR and host(). Here is my code

- Code: Select all
`gfor(array iPoint, num_of_landmark)`

{

array curLand = curPoint(iPoint,span);

float *t = curLand.host<float>();

int curX = t[0];

cout << " CUR X " << curX << endl;

print(curLand);

} // end for each landmark

You can see the result in the attachment. I only have 1 curX value even I have 76 version of curLand.

Please help me with the solution for this problem.

I want to convert the array value into integer because I will use the integer in the SEQ function

for example:

- Code: Select all
`myImg(seq(curX - 10, curX + 10), span)`

Thank you very much