Original Post
Hi all who can help me write the Gaussian filter in C++ and the program running on GPU using the Cg language! i know the Cg part code but i cannot write the C++ part code! please write the code to me. now i write other program must use the Gaussian filter on GPU version not just C++. help me ok? i am so...... :( ========================== Cg code here! ======================= void gauss(in float2 vUV :TEXCOOED0, out half vOut : COLOR, const uniform samperRECT oIamge, const uniform half aKernel[49]) { half4 vSum; int i,j,k; vOut=half4(0,0,0,0); k=0; for(i=0,i<7;i++) for(j=0,j<7;j++) { vSum +=texRECT(oImage, vUV+half2(i,j)*aKernel[k]; k++; } vOut =vSum; } =========================================