avcpp  2.0
Wrapper for the FFmpeg that simplify usage from C++ projects.
Public Types | Public Member Functions | List of all members
av::PixelFormat Class Reference

The PixelFormat class is a simple wrapper for AVPixelFormat that allow to acces it it properties. More...

#include <pixelformat.h>

Inheritance diagram for av::PixelFormat:
Inheritance graph
[legend]
Collaboration diagram for av::PixelFormat:
Collaboration graph
[legend]

Public Types

using Parent = PixSampleFmtWrapper< PixelFormat, AVPixelFormat >
 

Public Member Functions

 PixelFormat ()=default
 
 PixelFormat (const char *name) noexcept
 
 PixelFormat (const std::string &name) noexcept
 
const char * name (OptionalErrorCode ec=throws()) const
 
const AVPixFmtDescriptor * descriptor (OptionalErrorCode ec=throws()) const
 
int bitsPerPixel (OptionalErrorCode ec=throws()) const
 
size_t planesCount (OptionalErrorCode ec=throws()) const
 
PixelFormat swapEndianness () const noexcept
 
size_t convertionLoss (PixelFormat dstFmt, bool srcHasAlpha=false) const noexcept
 
- Public Member Functions inherited from PixSampleFmtWrapper< PixelFormat, AVPixelFormat >
constexpr PixSampleFmtWrapper ()=default
 
constexpr PixSampleFmtWrapper (AVPixelFormat fmt) noexcept
 
 operator AVPixelFormat () const noexcept
 
AVPixelFormat get () const noexcept
 
 operator AVPixelFormat & () noexcept
 
PixelFormat & operator= (AVPixelFormat fmt) noexcept
 
void set (AVPixelFormat fmt) noexcept
 

Additional Inherited Members

- Protected Attributes inherited from PixSampleFmtWrapper< PixelFormat, AVPixelFormat >
AVPixelFormat m_fmt
 

Detailed Description

The PixelFormat class is a simple wrapper for AVPixelFormat that allow to acces it it properties.

It has size same to the AVPixelFormat, but wrap pixel description function too.

Member Typedef Documentation

◆ Parent

Constructor & Destructor Documentation

◆ PixelFormat() [1/3]

av::PixelFormat::PixelFormat ( )
default

◆ PixelFormat() [2/3]

av::PixelFormat::PixelFormat ( const char *  name)
explicitnoexcept

◆ PixelFormat() [3/3]

av::PixelFormat::PixelFormat ( const std::string &  name)
explicitnoexcept

Member Function Documentation

◆ bitsPerPixel()

int av::PixelFormat::bitsPerPixel ( OptionalErrorCode  ec = throws()) const

◆ convertionLoss()

size_t av::PixelFormat::convertionLoss ( PixelFormat  dstFmt,
bool  srcHasAlpha = false 
) const
noexcept

◆ descriptor()

const AVPixFmtDescriptor * av::PixelFormat::descriptor ( OptionalErrorCode  ec = throws()) const

◆ name()

const char * av::PixelFormat::name ( OptionalErrorCode  ec = throws()) const

◆ planesCount()

size_t av::PixelFormat::planesCount ( OptionalErrorCode  ec = throws()) const

◆ swapEndianness()

PixelFormat av::PixelFormat::swapEndianness ( ) const
noexcept

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