unreal.MediaCaptureOptions

class unreal.MediaCaptureOptions(auto_restart_on_source_size_change: bool = False, overrun_action: MediaCaptureOverrunAction = Ellipsis, crop: MediaCaptureCroppingType = Ellipsis, color_conversion_settings: OpenColorIOColorConversionSettings = Ellipsis, custom_capture_point: IntPoint = Ellipsis, resize_method: MediaCaptureResizeMethod = Ellipsis, skip_frame_when_running_expensive_tasks: bool = False, convert_to_desired_pixel_format: bool = False, force_alpha_to_one_on_conversion: bool = False, apply_linear_to_srgb_conversion: bool = False, autostop_on_capture: bool = False, number_of_frames_to_capture: int = 0, capture_phase: MediaCapturePhase = Ellipsis)

Bases: StructBase

Base class of additional data that can be stored for each requested capture.

C++ Source:

  • Plugin: MediaIOFramework

  • Module: MediaIOCore

  • File: MediaCapture.h

Editor Properties: (see get_editor_property/set_editor_property)

  • apply_linear_to_srgb_conversion (bool): [Read-Write] Whether to apply a linear to sRGB conversion to the texture before outputting.

  • auto_restart_on_source_size_change (bool): [Read-Write] If source texture’s size change, auto restart capture to follow source resolution if implementation supports it.

  • autostop_on_capture (bool): [Read-Write] Automatically stop capturing after a predetermined number of images.

  • capture_phase (MediaCapturePhase): [Read-Write]

  • color_conversion_settings (OpenColorIOColorConversionSettings): [Read-Write] Color conversion settings used by the OCIO conversion pass.

  • convert_to_desired_pixel_format (bool): [Read-Write] Allows to enable/disable pixel format conversion for the cases where render target is not of the desired pixel format.

  • crop (MediaCaptureCroppingType): [Read-Write] Crop the captured SceneViewport or TextureRenderTarget2D to the desired size.

  • custom_capture_point (IntPoint): [Read-Write] Crop the captured SceneViewport or TextureRenderTarget2D to the desired size. note: Only valid when Crop is set to Custom.

  • force_alpha_to_one_on_conversion (bool): [Read-Write] In some cases when we want to stream irregular render targets containing limited number of channels (for example RG16f), we would like to force Alpha to 1.

  • number_of_frames_to_capture (int32): [Read-Write] The number of images to capture

  • overrun_action (MediaCaptureOverrunAction): [Read-Write] Action to do when game thread overruns render thread and all frames are in flights being captured / readback.

  • resize_method (MediaCaptureResizeMethod): [Read-Write] When the capture start, control if and how the source buffer should be resized to the desired size. note: Only valid when a size is specified by the MediaOutput.

  • resize_source_buffer (bool): [Read-Write] deprecated: bResizeSourceBuffer, please use ResizeMethod instead.

  • skip_frame_when_running_expensive_tasks (bool): [Read-Write] When the application enters responsive mode, skip the frame capture. The application can enter responsive mode on mouse down, viewport resize, … That is to ensure responsiveness in low FPS situations.

property apply_linear_to_srgb_conversion: bool

[Read-Write] Whether to apply a linear to sRGB conversion to the texture before outputting.

Type:

(bool)

property auto_restart_on_source_size_change: bool

[Read-Write] If source texture’s size change, auto restart capture to follow source resolution if implementation supports it.

Type:

(bool)

property autostop_on_capture: bool

[Read-Write] Automatically stop capturing after a predetermined number of images.

Type:

(bool)

property capture_phase: MediaCapturePhase

[Read-Write]

Type:

(MediaCapturePhase)

property color_conversion_settings: OpenColorIOColorConversionSettings

[Read-Write] Color conversion settings used by the OCIO conversion pass.

Type:

(OpenColorIOColorConversionSettings)

property convert_to_desired_pixel_format: bool

[Read-Write] Allows to enable/disable pixel format conversion for the cases where render target is not of the desired pixel format.

Type:

(bool)

property crop: MediaCaptureCroppingType

[Read-Write] Crop the captured SceneViewport or TextureRenderTarget2D to the desired size.

Type:

(MediaCaptureCroppingType)

property custom_capture_point: IntPoint

[Read-Write] Crop the captured SceneViewport or TextureRenderTarget2D to the desired size. note: Only valid when Crop is set to Custom.

Type:

(IntPoint)

property force_alpha_to_one_on_conversion: bool

[Read-Write] In some cases when we want to stream irregular render targets containing limited number of channels (for example RG16f), we would like to force Alpha to 1.

Type:

(bool)

property number_of_frames_to_capture: int

[Read-Write] The number of images to capture

Type:

(int32)

property overrun_action: MediaCaptureOverrunAction

[Read-Write] Action to do when game thread overruns render thread and all frames are in flights being captured / readback.

Type:

(MediaCaptureOverrunAction)

property resize_method: MediaCaptureResizeMethod

[Read-Write] When the capture start, control if and how the source buffer should be resized to the desired size. note: Only valid when a size is specified by the MediaOutput.

Type:

(MediaCaptureResizeMethod)

property resize_source_buffer: bool

[Read-Write] deprecated: bResizeSourceBuffer, please use ResizeMethod instead.

Type:

(bool)

property skip_frame_when_running_expensive_tasks: bool

[Read-Write] When the application enters responsive mode, skip the frame capture. The application can enter responsive mode on mouse down, viewport resize, … That is to ensure responsiveness in low FPS situations.

Type:

(bool)