Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
|
![]() |
|
Thread Tools | Search this Thread | Display Modes |
![]() |
#1 | Link |
Registered User
Join Date: Aug 2005
Posts: 46
|
how can i rotate an image file to 270 degrees or 90 degrees in clockwise?
how can i rotate an image file to 270 degrees or 90 degrees in clockwise?
none of these below worked. ffmpeg -y -rotate=90 -i "%1" "m:\aaa.bmp" ffmpeg -y -rotate=90 -i "%~1" "m:\aaa.bmp" ffmpeg -y -display_rotation 90 -i b.bmp "m:\aaa.bmp" ffmpeg -y -display_rotation 90 -codec copy -i b.bmp "m:\aaa.bmp" are these in below the same? -c copy -codec copy -c codec copy ************************* PS now i kind of got it after a long floundering -codec copy must not be included ffmpeg -y -display_rotation 270 -i "%1" output2.bmp if there is a way to improve or refine the command line, please do add Last edited by UFOxyz; 18th December 2024 at 05:26. Reason: i kind of made it work, but hope to refine the command line |
![]() |
![]() |
![]() |
#2 | Link |
ffx264/ffhevc author
Join Date: May 2007
Location: /dev/video0
Posts: 1,923
|
You cannot use -c copy since it does unmodified stream copy. If you rotate, that's a modification. As the name implies, it copies content 1:1, hence the name copy. If you modify something, it's no longer "copy" and it won't work.
To rotate 90° clockwise, use -vf transpose=1 |
![]() |
![]() |
![]() |
#5 | Link |
Registered User
Join Date: May 2006
Posts: 4,054
|
Something like this?
Code:
ffplay -i "your_source" -vf "rotate='15*PI/180:ow=hypot(iw,ih):oh=ow',scale=w=-2:h=576,setsar=1/1" Code:
ffmpeg -i "your_source" -vf "rotate='0.2*PI*t:ow=hypot(iw,ih):oh=ow:fillcolor=yellow',scale=w=-2:h=720,setsar=sar=1/1" -c:a copy -c:v libx264 -crf 20 "rotated.mp4" Last edited by Sharc; 19th December 2024 at 20:48. |
![]() |
![]() |
![]() |
#6 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 11,167
|
Maybe see this (Open Source, I think), Lossless rotate for jpg, apparently.
FreeVimager https://www.contaware.com/software/freevimager.html
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
![]() |
![]() |
![]() |
Tags |
rotate image |
Thread Tools | Search this Thread |
Display Modes | |
|
|