FMediaIOCoreTextureSampleBase

Implements the IMediaTextureSample/IMediaPoolable interface.

Windows
MacOS
Linux

Inheritance Hierarchy

IMediaTextureSample

IMediaPoolable

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

Remarks

Implements the IMediaTextureSample/IMediaPoolable interface.

Variables

Name Description

Protected variable

bool

 

bIsSRGBInput

Wheter the sample is in sRGB space and requires an explicit conversion to linear

Protected variable

TArray< uint8 >

 

Buffer

Pointer to raw pixels

Protected variable

FTimespan

 

Duration

Duration for which the sample is valid.

Protected variable

uint32

 

Height

Protected variable

EMediaTextureSa...

 

SampleFormat

Sample format.

Protected variable

uint32

 

Stride

Image dimensions

Protected variable

FTimespan

 

Time

Sample time.

Protected variable

TOptional< FTim...

 

Timecode

Sample timecode.

Protected variable

uint32

 

Width

Constructors

Functions

Name Description

Protected function Virtual

void

 

FreeSample()

Public function

bool

 

Initialize

(
    const void* InVideoBuffer,
    uint32 InBufferSize,
    uint32 InStride,
    uint32 InWidth,
    uint32 InHeight,
    EMediaTextureSampleFormat InSampleF...,
    FTimespan InTime,
    const FFrameRate& InFrameRate,
    const TOptional< FTimecode >& InTi...,
    bool bInIsSRGBInput
)

Initialize the sample.

Public function

bool

 

Initialize

(
    TArray< uint8 > InVideoBuffer,
    uint32 InStride,
    uint32 InWidth,
    uint32 InHeight,
    EMediaTextureSampleFormat InSampleF...,
    FTimespan InTime,
    const FFrameRate& InFrameRate,
    const TOptional< FTimecode >& InTi...,
    bool bInIsSRGBInput
)

Initialize the sample.

Public function

bool

 

InitializeWithEvenOddLine

(
    bool bUseEvenLine,
    const void* InVideoBuffer,
    uint32 InBufferSize,
    uint32 InStride,
    uint32 InWidth,
    uint32 InHeight,
    EMediaTextureSampleFormat InSampleF...,
    FTimespan InTime,
    const FFrameRate& InFrameRate,
    const TOptional< FTimecode >& InTi...,
    bool bInIsSRGBInput
)

Initialize the sample with half it's original height and take only the odd or even line.

Public function Virtual

void *

 

RequestBuffer

(
    uint32 InBufferSize
)

Request an uninitialized sample buffer.

Public function

bool

 

SetBuffer

(
    TArray< uint8 > InVideoBuffer
)

Set the sample buffer.

Public function

bool

 

SetBuffer

(
    const void* InVideoBuffer,
    uint32 InBufferSize
)

Initialize the sample.

Public function

bool

 

SetBufferWithEvenOddLine

(
    bool bUseEvenLine,
    const void* InVideoBuffer,
    uint32 InBufferSize,
    uint32 InStride,
    uint32 InHeight
)

Set the sample buffer with half it's original height and take only the odd or even line.

Public function

bool

 

SetProperties

(
    uint32 InStride,
    uint32 InWidth,
    uint32 InHeight,
    EMediaTextureSampleFormat InSampleF...,
    FTimespan InTime,
    const FFrameRate& InFrameRate,
    const TOptional< FTimecode >& InTi...,
    bool bInIsSRGBInput
)

Set the sample properties.

Overridden from IMediaTextureSample

Name Description

Public function Virtual

const void &...

 

GetBuffer()

Get the sample's frame buffer.

Public function Virtual Const

FIntPoint

 

GetDim()

Get the width and height of the sample.

Public function Virtual Const

FTimespan

 

GetDuration()

Get the amount of time for which the sample is valid.

Public function Virtual Const

EMediaTextur...

 

GetFormat()

Get the texture sample format.

Public function Virtual Const

FIntPoint

 

GetOutputDim()

Get the sample's desired output width and height.

Public function Virtual Const

uint32

 

GetStride()

Get the horizontal stride (aka. pitch) of the sample's frame buffer.

Public function Virtual Const

FTimespan

 

GetTime()

Get the sample time (in the player's local clock).

Public function Virtual Const

TOptional< F...

 

GetTimecode()

Get the sample timecode if available.

Public function Virtual Const

bool

 

IsCacheable()

Whether the sample can be held in a cache.

Public function Virtual Const

bool

 

IsOutputSrgb()

Whether the output of the sample is in sRGB color space.

Overridden from IMediaPoolable

Name Description

Public function Virtual

void

 

ShutdownPoolable()

Called when the object added to the pool.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss