Navigation
API > API/Plugins > API/Plugins/PixelCapture
The base class for all Capturers in the system. Incoming frames will be user types implementing IPixelCaptureInputFrame. Outgoing frames should be user types implementing IPixelCaptureOutputFrame. Each capturer system should expect one known input user type. Implement CreateOutputBuffer to create your custom IPixelCaptureOutputFrame implementation to hold the result of the capture process. Implement BeginProcess to start the capture work which ideally should be an async task of some sort. The capture work should fill the given IPixelCaptureOutputFrame and then call EndProcess to indicate the work is done. While the capture should be async it should only expect to work on one frame at a time.
| Name | FPixelCaptureCapturer |
| Type | class |
| Header File | /Engine/Plugins/Media/PixelCapture/Source/PixelCapture/Public/PixelCaptureCapturer.h |
| Include Path | #include "PixelCaptureCapturer.h" |
Syntax
class FPixelCaptureCapturer
Derived Classes
FPixelCaptureCapturer derived class hierarchy
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FPixelCaptureCapturer
(
FPixelCaptureCapturerConfig Config |
PixelCaptureCapturer.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FPixelCaptureCapturer() |
PixelCaptureCapturer.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| OnComplete | FOnComplete | PixelCaptureCapturer.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bBusy | bool | PixelCaptureCapturer.h | ||
| bHasOutput | bool | PixelCaptureCapturer.h | ||
| bInitialized | bool | PixelCaptureCapturer.h | ||
| Buffer | TUniquePtr< UE::PixelCapture::FOutputFrameBuffer > | PixelCaptureCapturer.h | ||
| ExpectedInputHeight | int32 | PixelCaptureCapturer.h | ||
| ExpectedInputWidth | int32 | PixelCaptureCapturer.h | ||
| FrameId | FThreadSafeCounter64 | PixelCaptureCapturer.h | ||
| OutputBuffers | TArray< TSharedPtr< IPixelCaptureOutputFrame > > | PixelCaptureCapturer.h | ||
| OutputBuffersMutex | FCriticalSection | PixelCaptureCapturer.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void Capture
(
const IPixelCaptureInputFrame& InputFrame |
Called when an input frame needs capturing. | PixelCaptureCapturer.h | |
DECLARE_TS_MULTICAST_DELEGATE
(
FOnComplete |
Listen on this to be notified when the capture process completes for each input. | PixelCaptureCapturer.h | |
bool HasOutput() |
Returns true if this process has a frame in the output buffer ready to be read. | PixelCaptureCapturer.h | |
bool IsBusy() |
Returns true when this process is actively working on capturing frame data. | PixelCaptureCapturer.h | |
bool IsInitialized () |
Returns true if Initialize() has been called. | PixelCaptureCapturer.h | |
TSharedPtr< IPixelCaptureOutputFrame > ReadOutput() |
Gets the output frame from the output buffer. | PixelCaptureCapturer.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void BeginProcess
(
const IPixelCaptureInputFrame& InputFrame, |
PixelCaptureCapturer.h | ||
void BeginProcess
(
const IPixelCaptureInputFrame& InputFrame, |
Implement this with your specific process to capture the incoming frame. | PixelCaptureCapturer.h | |
IPixelCaptureOutputFrame * CreateOutputBuffer
(
int32 InputWidth, |
Implement this to create a buffer for the output. | PixelCaptureCapturer.h | |
void EndProcess () |
Call this to mark the end of processing. Will commit the current write buffer into the read buffer. | PixelCaptureCapturer.h | |
void EndProcess
(
TSharedPtr< IPixelCaptureOutputFrame > OutputBuffer |
PixelCaptureCapturer.h | ||
| Gets the human readable name for this capture process. | PixelCaptureCapturer.h | ||
virtual void Initialize
(
int32 InputWidth, |
Initializes the process to be ready for work. Called once at startup. | PixelCaptureCapturer.h | |
void MarkCPUWorkEnd() |
Metadata info (optional). Marks the end of some CPU work. | PixelCaptureCapturer.h | |
void MarkCPUWorkStart() |
Metadata info (optional). Marks the start of some CPU work. Multiple work sections are valid. | PixelCaptureCapturer.h | |
void MarkGPUWorkEnd() |
Metadata info (optional). Marks the end of some GPU work. | PixelCaptureCapturer.h | |
void MarkGPUWorkStart() |
Metadata info (optional). Marks the start of some GPU work. Multiple work sections are valid. | PixelCaptureCapturer.h | |
void SetIsBusy
(
bool bInBusy |
Sets whether this process is actively working on capturing frame data. | PixelCaptureCapturer.h |