NVIDIA DeepStream SDK API Reference

9.2 Release
9.2/sources/libs/nvcudaimage/cudaImage.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: Copyright (c) 2016-2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3  * SPDX-License-Identifier: Apache-2.0
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17 #include <ostream>
18 #include <cuda.h>
19 #include <cuda_runtime.h>
20 
21 #ifdef __cplusplus
22 extern "C"
23 {
24 #endif
25 
26 void nv12_to_rgba(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, cudaStream_t stream);
27 
28 void nv12_to_bgr_planar_batch (uint8_t *pNv12, int nNv12Pitch, float *pRgb, int nRgbPitch, int nWidth, int nHeight, int nBatchSize, bool bSwap, cudaStream_t stream, float scale_factor, float *mean_data);
29 
30 void resize_rgba_float_planar_batch(float *dpSrc, int nSrcPitch, int nSrcWidth, int nSrcHeight,
31  float *dpDst, int nDstPitch, int nDstWidth, int nDstHeight, int nBatchSize, cudaStream_t stream);
32 
33 void nv12_to_bgra(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch,
34  int nWidth, int nHeight, cudaStream_t stream);
35 
36 void nv12_to_bgra_batch(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, int nBatchSize, cudaStream_t stream, bool bSwap=0);
37 
38 void nv12_to_rgba_batch(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, int nBatchSize, cudaStream_t stream, bool bSwap=0);
39 
40 void resize_nv12_batch(const uint8_t *dpSrc, int nSrcPitch, int nSrcWidth, int nSrcHeight, uint8_t *dpDst, int nDstPitch, int nDstWidth, int nDstHeight, int nBatchSize, cudaStream_t stream);
41 
42 #ifdef __cplusplus
43 }
44 #endif
nv12_to_bgra_batch
void nv12_to_bgra_batch(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, int nBatchSize, cudaStream_t stream, bool bSwap=0)
scale_factor
int scale_factor
Definition: sources/libs/nvll_batch_jpeg_encode/oss/jpeglib.h:938
resize_rgba_float_planar_batch
void resize_rgba_float_planar_batch(float *dpSrc, int nSrcPitch, int nSrcWidth, int nSrcHeight, float *dpDst, int nDstPitch, int nDstWidth, int nDstHeight, int nBatchSize, cudaStream_t stream)
resize_nv12_batch
void resize_nv12_batch(const uint8_t *dpSrc, int nSrcPitch, int nSrcWidth, int nSrcHeight, uint8_t *dpDst, int nDstPitch, int nDstWidth, int nDstHeight, int nBatchSize, cudaStream_t stream)
cudaStream_t
struct CUstream_st * cudaStream_t
Forward declaration of cudaStream_t.
Definition: includes/nvbufsurftransform.h:40
nv12_to_rgba
void nv12_to_rgba(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, cudaStream_t stream)
nv12_to_bgr_planar_batch
void nv12_to_bgr_planar_batch(uint8_t *pNv12, int nNv12Pitch, float *pRgb, int nRgbPitch, int nWidth, int nHeight, int nBatchSize, bool bSwap, cudaStream_t stream, float scale_factor, float *mean_data)
nv12_to_rgba_batch
void nv12_to_rgba_batch(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, int nBatchSize, cudaStream_t stream, bool bSwap=0)
nv12_to_bgra
void nv12_to_bgra(const uint8_t *dpNv12, int nNv12Pitch, uint8_t *dpRgb, int nBgraPitch, int nWidth, int nHeight, cudaStream_t stream)