how to using Linear Filtering

I have to write a code with the function of picture upsampling and downsampling. Therefore I want to use texture memory with Linear Filtering function.
Could anyone tell me how to use this function?

I have read Programming guide :

texture<float, 2, cudaReadModeElementType> texRef;
textureReference* texRefPtr;
cudaGetTextureReference(&texRefPtr, “texRef”);
cudaChannelFormatDesc channelDesc;
cudaGetChannelDesc(&channelDesc, cuArray);
cudaBindTextureToArray(texRef, cuArray, &channelDesc);

But does have anything result how to use Linear filtering. Also it cannot compile in vs 2005 [I think it may need write “cudaBindTextureToArray(texRefPtr, cuArray, &channelDesc);” ]

Thank you very much