pub struct ObsVideoInfoBuilder { /* private fields */ }Expand description
A structure intended to help make
creating new ObsVideoInfo structs
easier for resetting the OBS video
context.
Implementations§
Source§impl ObsVideoInfoBuilder
impl ObsVideoInfoBuilder
Sourcepub fn new() -> Self
pub fn new() -> Self
Creates a new ObsVideoInfoBuilder
for creating new ObsVideoInfo to
pass to the video context reset
function.
This function comes with sensible default values and chooses the backend for the current platform: DX11 on Windows, Metal on Apple Silicon macOS, and OpenGL on Intel macOS and other Unix systems.
Sourcepub fn build(self) -> ObsVideoInfo
pub fn build(self) -> ObsVideoInfo
Consumes the ObsVideoInfoBuilder
to create an ObsVideoInfo.
pub fn set_sdr_info(self, sdr_info: ObsSdrVideoInfo) -> Self
Sourcepub fn adapter(self, value: u32) -> Self
pub fn adapter(self, value: u32) -> Self
Sets the GPU adapter device that the video output is coming from.
Sourcepub fn graphics_module(self, value: ObsGraphicsModule) -> Self
pub fn graphics_module(self, value: ObsGraphicsModule) -> Self
Sets the graphics backend that libobs uses to record.
Sourcepub fn fps_num(self, value: u32) -> Self
pub fn fps_num(self, value: u32) -> Self
Sets the framerate of the
output video. Note that this
value may not reflect the
final framerate if fps_den
is not equal to 1.
Sourcepub fn fps_den(self, value: u32) -> Self
pub fn fps_den(self, value: u32) -> Self
Divides the FPS numerator to allow for fractional FPS counts on output.
Sourcepub fn base_width(self, value: u32) -> Self
pub fn base_width(self, value: u32) -> Self
Sets the width of the screen being recorded.
Sourcepub fn base_height(self, value: u32) -> Self
pub fn base_height(self, value: u32) -> Self
Sets the height of the screen being recorded.
Sourcepub fn output_width(self, value: u32) -> Self
pub fn output_width(self, value: u32) -> Self
Sets the width of the video output.
Sourcepub fn output_height(self, value: u32) -> Self
pub fn output_height(self, value: u32) -> Self
Sets the height of the video output.
Sourcepub fn output_format(self, value: ObsVideoFormat) -> Self
pub fn output_format(self, value: ObsVideoFormat) -> Self
Sets the format in which the video will be output.
Sourcepub fn gpu_conversion(self, value: bool) -> Self
pub fn gpu_conversion(self, value: bool) -> Self
Sets whether the GPU will handle conversion in the video.
Sourcepub fn colorspace(self, value: ObsColorspace) -> Self
pub fn colorspace(self, value: ObsColorspace) -> Self
Sets the video colorspace.
Sourcepub fn range(self, value: ObsVideoRange) -> Self
pub fn range(self, value: ObsVideoRange) -> Self
Sets the video range.
Sourcepub fn scale_type(self, value: ObsScaleType) -> Self
pub fn scale_type(self, value: ObsScaleType) -> Self
Sets the video scaling type.
Trait Implementations§
Source§impl Clone for ObsVideoInfoBuilder
impl Clone for ObsVideoInfoBuilder
Source§fn clone(&self) -> ObsVideoInfoBuilder
fn clone(&self) -> ObsVideoInfoBuilder
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more