code: public static int cuTexRefSetFormat(CUtexref hTexRef, int fmt, int NumPackedComponents)
      {
          return checkResult(cuTexRefSetFormatNative(hTexRef, fmt, NumPackedComponents));
      }
docs: Sets the format for a texture reference.
  
  <pre>
  CUresult cuTexRefSetFormat (
  CUtexref hTexRef,
  CUarray_format fmt,
  int  NumPackedComponents )
  </pre>
  <div>
  <p>Sets the format for a texture reference.
  Specifies the format of the data to be read by the texture reference
  <tt>hTexRef</tt>. <tt>fmt</tt> and <tt>NumPackedComponents</tt> are
  exactly analogous to the Format and NumChannels members of the
  CUDA_ARRAY_DESCRIPTOR structure: They specify the format of each
  component and the number of components per array element.
  </p>
  </div>
  
  @param hTexRef Texture reference
  @param fmt Format to set
  @param NumPackedComponents Number of components per array element
  
  @return CUDA_SUCCESS, CUDA_ERROR_DEINITIALIZED, CUDA_ERROR_NOT_INITIALIZED,
  CUDA_ERROR_INVALID_CONTEXT, CUDA_ERROR_INVALID_VALUE
  
  @see JCudaDriver#cuTexRefSetAddress
  @see JCudaDriver#cuTexRefSetAddress2D
  @see JCudaDriver#cuTexRefSetAddressMode
  @see JCudaDriver#cuTexRefSetArray
  @see JCudaDriver#cuTexRefSetFilterMode
  @see JCudaDriver#cuTexRefSetFlags
  @see JCudaDriver#cuTexRefGetAddress
  @see JCudaDriver#cuTexRefGetAddressMode
  @see JCudaDriver#cuTexRefGetArray
  @see JCudaDriver#cuTexRefGetFilterMode
  @see JCudaDriver#cuTexRefGetFlags
  @see JCudaDriver#cuTexRefGetFormat