Flyleaf icon indicating copy to clipboard operation
Flyleaf copied to clipboard

Is there a way to rotate the video stream?

Open axelalex13 opened this issue 3 years ago • 1 comments

Some videos (especially those recorded with a phone) have a wrong orientation and I want to be able to change that or to ignore the rotation tag from video metadata. Is there any way to achieve that?

axelalex13 avatar Jul 12 '22 12:07 axelalex13

Unfortunately, this is not supported yet. I will try to include it on the upcoming versions.

SuRGeoNix avatar Jul 12 '22 13:07 SuRGeoNix

Hi @SuRGeoNix any update on this request to be able to rotate the stream?

t3therdev avatar Dec 11 '23 01:12 t3therdev

@t3therdev That was long ago, both stream rotation from codec parameters and user's custom Player.Rotation have been implemented. Do you have any issues with that?

SuRGeoNix avatar Dec 11 '23 09:12 SuRGeoNix

Hi @SuRGeoNix , was there an example somewhere we could review? Haven't come across it yet.

See some references here,

          <MenuItem Header="{Binding Player.Rotation}" HeaderStringFormat="Rotation ({0}°)">
                <MenuItem Header="0°"       CommandParameter="0"    Command="{Binding Player.Commands.RotationSet}"/>
                <MenuItem Header="90°"      CommandParameter="90"   Command="{Binding Player.Commands.RotationSet}"/>
                <MenuItem Header="180°"     CommandParameter="180"  Command="{Binding Player.Commands.RotationSet}"/>
                <MenuItem Header="270°"     CommandParameter="270"  Command="{Binding Player.Commands.RotationSet}"/>

Is there also a flip horizontal / vertical option?

t3therdev avatar Dec 11 '23 12:12 t3therdev

@t3therdev Just use Player.Rotation = [angles]

SuRGeoNix avatar Dec 11 '23 14:12 SuRGeoNix

@SuRGeoNix it seems rotation is ok but what about flip/mirror? the same commands that would be from ffmpeg transpose for example? Or vflip / hflip?

t3therdev avatar Jan 17 '24 19:01 t3therdev

@t3therdev Let me know if that's what you wanted

SuRGeoNix avatar Jan 19 '24 11:01 SuRGeoNix

@SuRGeoNix yes that works! Thanks! Can you please include it in a release/nuget for us?

t3therdev avatar Jan 19 '24 19:01 t3therdev

@t3therdev It's published

SuRGeoNix avatar Jan 19 '24 20:01 SuRGeoNix