1 __global__ void kernel_Median3RegTri9( short *output, int i_dim, int j_dim)
4 // coordonnees absolues du point
5 int j = __mul24(blockIdx.x,blockDim.x) + threadIdx.x ;
6 int i = __mul24(blockIdx.y,blockDim.y) + threadIdx.y ;
8 /**************************************************************************
10 **************************************************************************/
11 int a0, a1, a2, a3, a4, a5, a6, a7, a8 ;
13 /********************************************************************************
14 * affectation des valeurs
15 ********************************************************************************/
16 a0 = tex2D(tex_img_ins, j-1, i-1) ;
17 a1 = tex2D(tex_img_ins, j , i-1) ;
18 a2 = tex2D(tex_img_ins, j+1, i-1) ;
19 a3 = tex2D(tex_img_ins, j-1, i) ;
20 a4 = tex2D(tex_img_ins, j , i) ;
21 a5 = tex2D(tex_img_ins, j+1, i) ;
22 a6 = tex2D(tex_img_ins, j-1, i+1) ;
23 a7 = tex2D(tex_img_ins, j , i+1) ;
24 a8 = tex2D(tex_img_ins, j+1, i+1) ;
27 bubTriReg9(&a0, &a1, &a2, &a3, &a4, &a5, &a6, &a7, &a8);
30 output[ __mul24(i, j_dim) +j ] = a4 ;