class

FFmpeg::SWScale

Inherits Reference / Object

Constructors

new(input_width : Int, input_height : Int, input_format : PixelFormat, output_width : Int | Nil = nil, output_height : Int | Nil = nil, output_format : PixelFormat = PixelFormat::Rgb24, scaling_method : ScalingAlgorithm = ScalingAlgorithm::Bicublin)
Source
new(input : Frame, output : Frame, scaling_method : ScalingAlgorithm = ScalingAlgorithm::Bicublin)
Source
new(codec : Codec, output_width : Int | Nil = nil, output_height : Int | Nil = nil, output_format : PixelFormat = PixelFormat::Rgb24, scaling_method : ScalingAlgorithm = ScalingAlgorithm::Bicublin)
Source

Class methods

scale(input : Frame, width : Int32, height : Int32, output_format : PixelFormat = PixelFormat::Rgb24, scaling_method : ScalingAlgorithm = ScalingAlgorithm::Bicublin) : Frame
Source

Instance methods

finalize
Source
input_format
Source
input_height
Source
input_width
Source
output_format
Source
output_frame

create a compatible output frame for storing the scaled result

Source
output_height
Source
output_width
Source
scale(input : Frame, output : Frame = output_frame)

scales and optionally changes format of a frame

Source
scaling_method
Source
unsafe_scale(input : Frame, output : Frame = output_frame)

like scale but without the checks if you need the speed

Source