MediaX v1.0.0rc7 [7e6cb74]
Video streaming for military vehicles
Loading...
Searching...
No Matches
mediax::video::ColourSpaceCuda Class Reference

Helper functions for different colour space options, optimised for CUDA (NVidia) More...

#include <colourspace_cuda.h>

Inheritance diagram for mediax::video::ColourSpaceCuda:
Inheritance graph
Collaboration diagram for mediax::video::ColourSpaceCuda:
Collaboration graph

Public Member Functions

 ColourSpaceCuda () final
 Construct a new Colour Space object.
 
int RgbToYuv (uint32_t height, uint32_t width, uint8_t *rgb, uint8_t *yuv) const final
 Convert YUV to RGBA.
 
int RgbToMono8 (uint32_t height, uint32_t width, uint8_t *rgb, uint8_t *mono8) const final
 Convert RGB to Monochrome 8 bits ber pixel.
 
int RgbToMono16 (uint32_t height, uint32_t width, uint8_t *rgb, uint8_t *mono16) const final
 Convert RGB to Monochrome 16 bits ber pixel.
 
int RgbaToYuv (uint32_t width, uint32_t height, uint8_t *rgba, uint8_t *yuv) const final
 Convert RGBA to YUV.
 
int RgbaToRgb (uint32_t width, uint32_t height, uint8_t *rgba, uint8_t *rgb) const final
 Convert RGBA to RGB.
 
int YuvToBgra (uint32_t height, uint32_t width, uint8_t *yuv, uint8_t *rgba) const final
 Convert YUV to RGBA.
 
int YuvToRgb (uint32_t height, uint32_t width, uint8_t *yuv, uint8_t *rgb) const final
 Convert YUV to RGB.
 
- Public Member Functions inherited from mediax::video::ColourSpace
 ColourSpace ()=default
 Construct a new Colour Space object.
 
virtual ~ColourSpace ()=default
 Destroy the Colour Space object.
 
virtual int RgbaToBgra (uint32_t width, uint32_t height, uint8_t *rgba, uint8_t *bgra) const =0
 Convert RGBA to RGB.
 
virtual int RgbToBgra (uint32_t width, uint32_t height, uint8_t *rgba, uint8_t *rgb) const =0
 Convert RGB to RGBA.
 
virtual int Mono8ToBgra (uint32_t width, uint32_t height, uint8_t *mono8, uint8_t *bgra) const =0
 Convert Mono8 to RGBA on the CPU.
 
virtual int Mono16ToBgra (uint32_t width, uint32_t height, uint8_t *mono16, uint8_t *bgra) const =0
 Convert Mono16 to RGBA on the CPU.
 
virtual int RgbToRgba (uint32_t width, uint32_t height, uint8_t *rgb, uint8_t *rgba) const =0
 Convert RGB to RGBA on the CPU.
 
virtual int Yuv422ToRgba (uint32_t height, uint32_t width, uint8_t *yuv422, uint8_t *rgba) const =0
 Convert YUV to RGBA on the CPU.
 
virtual int Yuv420ToRgba (uint32_t height, uint32_t width, uint8_t *yuv420, uint8_t *rgba) const =0
 
virtual int Mono8ToRgba (uint32_t width, uint32_t height, uint8_t *mono8, uint8_t *rgba) const =0
 Convert Mono8 to RGBA on the CPU.
 
virtual int Mono8ToRgb (uint32_t width, uint32_t height, uint8_t *mono8, uint8_t *rgb) const =0
 Convert Mono8 to RGB on the CPU.
 
virtual int Mono16ToRgba (uint32_t width, uint32_t height, uint8_t *mono16, uint8_t *rgba) const =0
 Convert Mono16 to RGBA on the CPU.
 
virtual int Mono16ToRgb (uint32_t width, uint32_t height, uint8_t *mono16, uint8_t *rgb) const =0
 Convert Mono16 to RGBA on the CPU.
 
virtual int Yuv420pToRgb (uint32_t height, uint32_t width, uint8_t *yuv, uint8_t *rgb) const =0
 Convert YUV:420P to RGB.
 
virtual int ScaleToSizeRgb (uint32_t source_height, uint32_t source_width, uint8_t *source_rgb_buffer, uint32_t target_height, uint32_t target_width, uint8_t *target_rgb_buffer) const =0
 Scale the image to the target size for RGB.
 
virtual int ScaleToSizeRgba (uint32_t source_height, uint32_t source_width, uint8_t *source_rgb_buffer, uint32_t target_height, uint32_t target_width, uint8_t *target_rgb_buffer) const =0
 Scale the image to the target size for RGBA.
 

Detailed Description

Helper functions for different colour space options, optimised for CUDA (NVidia)

Member Function Documentation

◆ RgbaToRgb()

int mediax::video::ColourSpaceCuda::RgbaToRgb ( uint32_t  width,
uint32_t  height,
uint8_t *  rgba,
uint8_t *  rgb 
) const
finalvirtual

Convert RGBA to RGB.

Parameters
width
height
rgba
rgb

Implements mediax::video::ColourSpace.

◆ RgbaToYuv()

int mediax::video::ColourSpaceCuda::RgbaToYuv ( uint32_t  width,
uint32_t  height,
uint8_t *  rgba,
uint8_t *  yuv 
) const
finalvirtual

Convert RGBA to YUV.

Parameters
widthThe width of the image
heightThe height of the image
rgbaThe RGB image buffer
yuvThe YUV:422 image buffer

Implements mediax::video::ColourSpace.

◆ RgbToMono16()

int mediax::video::ColourSpaceCuda::RgbToMono16 ( uint32_t  height,
uint32_t  width,
uint8_t *  rgb,
uint8_t *  mono16 
) const
finalvirtual

Convert RGB to Monochrome 16 bits ber pixel.

Parameters
heightThe height of the image
widthThe width of the image
rgbThe RGB image buffer
mono16The monochrome 16 image buffer

Implements mediax::video::ColourSpace.

◆ RgbToMono8()

int mediax::video::ColourSpaceCuda::RgbToMono8 ( uint32_t  height,
uint32_t  width,
uint8_t *  rgb,
uint8_t *  mono8 
) const
finalvirtual

Convert RGB to Monochrome 8 bits ber pixel.

Parameters
heightThe height of the image
widthThe width of the image
rgbThe RGB image buffer
mono8The monochrome 8 image buffer

Implements mediax::video::ColourSpace.

◆ RgbToYuv()

int mediax::video::ColourSpaceCuda::RgbToYuv ( uint32_t  height,
uint32_t  width,
uint8_t *  rgb,
uint8_t *  yuv 
) const
finalvirtual

Convert YUV to RGBA.

Parameters
heightThe height of the image
widthThe width of the image
rgbThe RGB image buffer
yuvThe YUV:422 image buffer

Implements mediax::video::ColourSpace.

◆ YuvToBgra()

int mediax::video::ColourSpaceCuda::YuvToBgra ( uint32_t  height,
uint32_t  width,
uint8_t *  yuv,
uint8_t *  rgba 
) const
finalvirtual

Convert YUV to RGBA.

Parameters
heightThe height of the image
widthThe width of the image
yuvThe YUV:422 image buffer
rgbaThe RGBA image buffer

Implements mediax::video::ColourSpace.

◆ YuvToRgb()

int mediax::video::ColourSpaceCuda::YuvToRgb ( uint32_t  height,
uint32_t  width,
uint8_t *  yuv,
uint8_t *  rgb 
) const
finalvirtual

Convert YUV to RGB.

Parameters
heightThe height of the image
widthThe width of the image
yuvThe YUV:422 image buffer
rgbThe RGB image buffer

Implements mediax::video::ColourSpace.


The documentation for this class was generated from the following file: