Navigation
API > API/Plugins > API/Plugins/MediaIOCore
Inheritance Hierarchy
- IMediaTextureSample
- IMediaPoolable
- IMediaTextureSampleColorConverter
- FMediaIOCoreTextureSampleBase
References
| Module | MediaIOCore |
| Header | /Engine/Plugins/Media/MediaIOFramework/Source/MediaIOCore/Public/MediaIOCoreTextureSampleBase.h |
| Include | #include "MediaIOCoreTextureSampleBase.h" |
Syntax
class FMediaIOCoreTextureSampleBase :
public IMediaTextureSample,
public IMediaPoolable,
public IMediaTextureSampleColorConverter
Remarks
Implements the IMediaTextureSample/IMediaPoolable interface.
Variables
| Type | Name | Description | |
|---|---|---|---|
| TArray< uint8, TAlignedHeapAllocator< 4096 > > | Buffer | Pointer to raw pixels | |
| UE::Color::EColorSpace | ColorSpace | Color space enum of the incoming texture. | |
| UE::Color::FColorSpace | ColorSpaceStruct | Color space structure of the incoming texture. Used for retrieving chromaticities. | |
| FTimespan | Duration | Duration for which the sample is valid. | |
| UE::Color::EEncoding | Encoding | Color encoding of the incoming texture. | |
| void * | ExternalBuffer | ||
| uint32 | Height | ||
| EMediaTextureSampleFormat | SampleFormat | Sample format. | |
| uint32 | Stride | Image dimensions | |
| FTimespan | Time | Sample time. | |
| TOptional< FTimecode > | Timecode | Sample timecode. | |
| uint32 | Width |
Constructors
| Type | Name | Description | |
|---|---|---|---|
| PRAGMA_DISABLE_DEPRECATION_WARNINGS | Note: We need to explicitly disable warnings on these constructors/operators for clang to be happy with deprecated variables. | ||
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | CopyConfiguration
(
const TSharedPtr< FMediaIOCoreTextureSampleBase >& SourceSample |
Copies all neccessary data from a source sample to render JIT | |
| void | FreeSample () |
||
| double | Returns time evaluated on the game thread for JITR | ||
| void * | |||
| TSharedPtr< FMediaIOCorePlayerBase > | GetPlayer () |
Returns the player that created this sample | |
| bool | Initialize
(
const void* InVideoBuffer, |
Initialize the sample. | |
| bool | Initialize
(
TArray< uint8 >&& InVideoBuffer, |
Initialize the sample. | |
| bool | Initialize
(
const TArray< uint8 >& InVideoBuffer, |
Initialize the sample. | |
| bool | InitializeJITR
(
const FMediaIOCoreSampleJITRConfigurationArgs& Args |
Configure this sample for JITR | |
| bool | InitializeWithEvenOddLine
(
bool bUseEvenLine, |
Initialize the sample with half it's original height and take only the odd or even line. | |
| bool | Returns whether it's ready for GPUDirect texture transfer | ||
| void * | RequestBuffer
(
uint32 InBufferSize |
Request an uninitialized sample buffer. | |
| void | Marks this sample as one that is ready and awaiting for fast GPUDirect texture transfer | ||
| bool | Set the sample buffer. | ||
| bool | Set the sample buffer. | ||
| void | SetBuffer
(
void* InBuffer |
||
| bool | SetBuffer
(
const void* InVideoBuffer, |
Initialize the sample. | |
| bool | SetBufferWithEvenOddLine
(
bool bUseEvenLine, |
Set the sample buffer with half it's original height and take only the odd or even line. | |
| void | SetColorConversionSettings
(
TSharedPtr< struct FOpenColorIOColorConversionSettings > InColorConversionSettings |
Set the OCIO settings used for color conversion. | |
| void | SetDestructionCallback
(
TFunction< void(TRefCountPtr< FRHITexture >)> InDestructionCallback |
||
| bool | SetProperties
(
uint32 InStride, |
Set the sample properties. | |
| void | SetTexture
(
TRefCountPtr< FRHITexture > InRHITexture |
Overridden from IMediaTextureSample
| Type | Name | Description | |
|---|---|---|---|
| const void * | GetBuffer () |
Get the sample's frame buffer. | |
| FIntPoint | GetDim () |
Get the width and height of the sample. | |
| FVector2f | |||
| FVector2f | |||
| FVector2f | |||
| FTimespan | GetDuration () |
Get the amount of time for which the sample is valid. | |
| UE::Color::EEncoding | Get EOTF / "Gamma" / encoding type of data | ||
| EMediaTextureSampleFormat | GetFormat () |
Get the texture sample format. | |
| FMatrix44f | Get Colorspace conversion matrix to convert to CIE1931 XYZ space | ||
| float | |||
| FIntPoint | GetOutputDim () |
Get the sample's desired output width and height. | |
| uint32 | GetStride () |
Get the horizontal stride (aka. pitch) of the sample's frame buffer. | |
| FMediaTimeStamp | GetTime () |
Get the sample time (in the player's local clock). | |
| TOptional< FTimecode > | GetTimecode () |
Get the sample timecode if available. | |
| FVector2f | Get white point of color space of the data contain in the sample | ||
| const FMatrix & | Get YUV to RGB conversion matrix | ||
| bool | IsCacheable () |
Whether the sample can be held in a cache. | |
| bool | IsOutputSrgb () |
Whether the output of the sample is in sRGB color space. |
Overridden from IMediaPoolable
| Type | Name | Description | |
|---|---|---|---|
| void | Called when the object added to the pool. |
Overridden from IMediaTextureSampleColorConverter
| Type | Name | Description | |
|---|---|---|---|
| bool | ApplyColorConversion
(
FTexture2DRHIRef& InSrcTexture, |
Apply a color conversion on the input and store the result in the destination texture. |
Operators
| Type | Name | Description | |
|---|---|---|---|
| FMediaIOCoreTextureSampleBase & | |||
| FMediaIOCoreTextureSampleBase & | operator=
(
const FMediaIOCoreTextureSampleBase& |
Deprecated Variables
| Type | Name | Description | |
|---|---|---|---|
| bool | bIsSRGBInput | Please use Encoding instead. |