Ejemplo n.º 1
0
 public static extern nvjpegStatus nvjpegDecodeJpeg(
     nvjpegHandle handle,
     nvjpegJpegDecoder decoder,
     nvjpegJpegState decoder_state,
     nvjpegJpegStream jpeg_bitstream,
     ref nvjpegImage destination,
     nvjpegDecodeParams decode_params,
     CUstream stream);
Ejemplo n.º 2
0
 /// <summary>
 /// </summary>
 internal DecodeParams(NvJpeg nvJpeg)
 {
     _nvJpeg = nvJpeg;
     _params = new nvjpegDecodeParams();
     res     = NvJpegNativeMethods.nvjpegDecodeParamsCreate(nvJpeg.Handle, ref _params);
     Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "nvjpegDecodeParamsCreate", res));
     if (res != nvjpegStatus.Success)
     {
         throw new NvJpegException(res);
     }
 }
Ejemplo n.º 3
0
        public bool DecodeBatchedSupportedEx(nvjpegDecodeParams decodeParams)
        {
            int batchSupported = 0;

            res = NvJpegNativeMethods.nvjpegDecodeBatchedSupportedEx(_nvJpeg.Handle, _stream, decodeParams, ref batchSupported);
            Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "nvjpegDecodeBatchedSupportedEx", res));
            if (res != nvjpegStatus.Success)
            {
                throw new NvJpegException(res);
            }
            return(batchSupported > 0);
        }
Ejemplo n.º 4
0
 public static extern nvjpegStatus nvjpegDecodeJpegHost(
     nvjpegHandle handle,
     nvjpegJpegDecoder decoder,
     nvjpegJpegState decoder_state,
     nvjpegDecodeParams decode_params,
     nvjpegJpegStream jpeg_stream);
Ejemplo n.º 5
0
 public static extern nvjpegStatus nvjpegDecodeBatchedSupportedEx(nvjpegHandle handle,
                                                                  nvjpegJpegStream jpeg_stream,
                                                                  nvjpegDecodeParams decode_params,
                                                                  ref int is_supported);
Ejemplo n.º 6
0
 public static extern nvjpegStatus nvjpegDecoderJpegSupported(nvjpegJpegDecoder decoder_handle,
                                                              nvjpegJpegStream jpeg_stream,
                                                              nvjpegDecodeParams decode_params,
                                                              ref int is_supported);
Ejemplo n.º 7
0
 public static extern nvjpegStatus nvjpegDecodeParamsSetScaleFactor(
     nvjpegDecodeParams decode_params,
     nvjpegScaleFactor scale_factor);
Ejemplo n.º 8
0
 public static extern nvjpegStatus nvjpegDecodeParamsSetAllowCMYK(
     nvjpegDecodeParams decode_params,
     int allow_cmyk);
Ejemplo n.º 9
0
 public static extern nvjpegStatus nvjpegDecodeParamsSetROI(
     nvjpegDecodeParams decode_params,
     int offset_x, int offset_y, int roi_width, int roi_height);
Ejemplo n.º 10
0
 public static extern nvjpegStatus nvjpegDecodeParamsSetOutputFormat(
     nvjpegDecodeParams decode_params,
     nvjpegOutputFormat output_format);
Ejemplo n.º 11
0
 public static extern nvjpegStatus nvjpegDecodeParamsDestroy(nvjpegDecodeParams decode_params);
Ejemplo n.º 12
0
 public static extern nvjpegStatus nvjpegDecodeParamsCreate(
     nvjpegHandle handle,
     ref nvjpegDecodeParams decode_params);