helmerapp / micro

top notch GIFs, right from your desktop
https://www.helmer.app/micro
Other
25 stars 5 forks source link

fix: added custom aspect ratio for windows #91

Closed RohanPunjani closed 1 month ago

clearlysid commented 2 months ago

This should be fixed at a henx level directly, not here.

RohanPunjani commented 2 months ago

This should be fixed at a henx level directly, not here.

In henx: when defining a new encoder:

  let encoder = Some(
            WVideoEncoder::new(
                VideoEncoderType::Mp4,
                VideoEncoderQuality::Uhd2160p,
                options.width as u32,
                options.height as u32,
                options.path,
            )
            .expect("Failed to create video encoder"),
        );

It takes videoEncoderQuality Below is the actual output frame dimension while running few test on the parameters of videoEncoderQuality on frame dimensions of 1280x680

Auto - Error -> Failed to create video encoder: WindowsError(Error { code: HRESULT(0xC00D36E6), message: "The requested attribute was not found." })
HD1080p - 1920 x 1080
HD720p - 1280 x 720
Wvga - 800 x 480
Ntsc - 720 x 480
Pal - 720 x 576
Vga - 640 x 480
Qvga - 320 x 240
Uhd2160p - 3840 x 2160
Uhd4320p - Error -> Failed to create video encoder: WindowsError(Error { code: HRESULT(0xC00D6D60), message: "A valid type has not been set for this stream or a stream that it depends on." })
clearlysid commented 2 months ago

Let's ask NiiightmareXD on Discord for guidance here.

clearlysid commented 1 month ago

Closing in favour of #72 and henx update.