How to use thread and block for my code shown in belo ?

I m new with cuda. I m writing code for image processing in cuda.
My c and cuda code is below and i tried to convert into cuda, but it not works well.

My C code :

int main(int argc, char **argv)
    {
     /* here i define and initialize some variable */
    
    	int point=0;
     for(int i=0;i<1050;i++,point+=1580)
     {
        
    	/* doing some image process  using that point value on 16 bit grayscale image.*/
     } 
    
     
     return 0;
    }

i tried to convert my c code into cuda, but its wrong.
So, my cuda code that what ever i tried is below.

__global__ void processOnImage(int pointInc)
    {
    	 int line = blockIdx.x * blockDim.x + threadIdx.x;
    	 int point=((line)*pointInc));
          /* here i m not getting exact vaue of point variable as same like in c code */
    	/* doing image processing here using point value */
    
    }
    
    
    int main(int argc, char **argv)
    {
     /* here i define and initialize some variable */
    	
    	int pointInc=1580;
    	static const int BLOCK_WIDTH = 25;
    	int x = static_cast<int>(ceilf(static_cast<float>(1050) / BLOCK_WIDTH));
    	const dim3 grid (x,1);
    	const dim3 block(BLOCK_WIDTH,1);
    	processOnImage<<<grid,block>>>(pointInc);
     
     return 0;
    }

In processOnImage function of cuda code i m not getting exact value of point(int point) variable as in above c code. so what i m doing wrong in cuda code. Or how to use that block and thread for my code in c.

In your example is missing a line to copy the data to the gpu. Are you doing that in your code?

ya i had done that.

i have one dout that in my code of cuda, how to use point varible ?
means in my c code, point= point+lineInc, but in cuda code there is no for loop, so how to add my point variable or use it ?

Does the point computed for int line = blockIdx.x * blockDim.x + threadIdx.x; depend on results from other threads? In your C code ever interation increases also the value of point. In CUDA you can only do that by defining a global variable and using atomic functions.
for example:
_device int pointc; //at the beginning of the code, this defines a global variable seen by all kernels

previouspp=atomicadd(&pointc,1580); // this line in the kernel

Just try to make an exercise with your mind. If you have a variable and you do this line:
pointc=pointc+1580;. This means tht some threads will read the variable pointc in the same time and add 1 and then return the same number.This is why you need atomic operations to ensure that the value of pointc is updated correct.