I have a few videos that have been shot with a portable camera on their side and need to be rotated 90 degrees. I am able to do this with virtual Dub; however it seems to re-encode the video even if I go to compression menu and select the same codec that the video was shot in. The source video was shot in XVID MPEG 4 and it around 6.84mb in size. When virtual dub has rotated this video and saved it in the same codec it is now only 1.25MB in size, so Virtual Dub is obviously compressing the video further. All I want to do it rotate the video, and save in exactly the same form without changing the file size or re-endoding in any way. Are there any programs that will allow me to do this? – either free programs or commercial?
I am able to rotate the video in VLC and play it, but there is no option to save this rotated video? Is there a build of VLC I can install or any other program that will allow me to rotate without re-encoding or loosing quality? When I play my rotated video in VLC the quality looks great. It is just I can't save it?? This should be a simple thing to do without even having to open a fully fledged video editor. A neat idea would be to have a program that adds a rotate function to the windows context menu on right click – like you can do with pictures.
Thanks Dave
+ Reply to Thread
Results 1 to 16 of 16
-
-
I'm pretty sure you must reconvert. But increase the target quantizer or bitrate to get similar quality as the source. In virtualdub under video->compression->xvid and click configuration. Drag the target quantizer to max quality or click on target quantizer and you can set the bitrate manually(click on calc to calculate it).
-
Thanks for your reply
I have selected best quality; however the output video is still smaller at 5.41MB opposed to 6.84MB source. I can't understand why I have to re-encode as all I want to do is change the rotation with everything else staying the same - Codec bitrate etc. I don’t want smaller file or larger file, just everything the same apart from rotation.
If VLC can rotate without re-encoding why can't it just save this output? Surely it can't be that hard?? -
As soon as you change the video....it need re-encoded. Plain and simple.
-
Originally Posted by marada
To save it would require recompressing the changed image, ie re-encoding. -
Originally Posted by marada
This can then transformed in various ways.
To save that uncompressed image you have to reencode.
There are some bitmap formats (like jpeg) where you can do a lossless rotation, but I'm pretty sure than no video formats allow that. More to the point, no applications support this. -
In theory DCT compressed video can be rotated without fully decompressing the frames. In practice, nobody has written a program to do this because it's quite complex.
The simplest solution is to remux your video into a container that supports rotation in its header metadata to instruct players to rotate the video at playback. I believe MP4 supports this but I don't know of any muxers that give the option. -
So in summary is Virtual Dub the best tool for this, and how do I get Virtual Dub to output the exact same file size / quality of the rotated video compared to the source?
-
Also please check out the following tool that enables you to rotate video from within windows just by right click:
http://www.nirp.co.uk/rotatevideos/download-rotate-videos
The problem is I run windows 7 and this tool was not working for me. Also it is in a very early development. -
Originally Posted by marada
-
You can't get both the same file size and same quality. It's one or the other. Or something in between.
A simple way to get fairly good quality, without increasing the file size too much, and relatively quickly, is to encode with Xvid in Single Pass, Target Quantizer Mode with a quantizer of 3. -
Does everyone agree? -
Lagarith is lossless, so there would be no quality loss. Xvid is lossy. Each re-encoding with Xvid incurs a quality drop to some degree. If you are happy with larger file sizes, use Xvid, do a quality based encode with a quantiser of 2, and most likely you wont see a visual difference. However the file size could be substantially larger.
Read my blog here.
-
use Xvid, do a quality based encode with a quantiser of 2, and most likely you wont see a visual difference
On another note I know lagarith is lossless, however the video is Xvid so you must still convert from Xvid to Lagarith which will incur a slight quality drop (as with anytime you re-encode anything). I don't kow how this would compare to just keeping it as Xvid? -
No, there will be no quality drop with Lagarith.
The process of reencoding video consists of decompressing the source then compressing again. Using a lossless compression in the recompression means that the video that comes out of that compression is exactly the same video as went in. Exactly the same video that came out of the first decompression. You could decompress and recompress a thousand times with Lagarith and the video that came out of that 1000th decompression would be exactly the same as the video that went into the first. But using a lossless codec will usually give you a file that many times larger than an Xvid source.
It's highly unusual that your Xvid recompression at target quantizer 1 came out smaller than your Xvid source. There is something unusual about your source. Maybe it's all I frame? A quantizer of 1 will usually result in a much larger file. So big in fact that you might as well use a lossless codec (hardware compatibility aside). A quantizer of 2 will also usually generate a significantly larger file as the encoder is working hard to preserve the artifacts created by the first compression.
Also, turn off B frames if you want a little more quality. Even in a Target Quantizer encode, B frames are encoded at a lower quality.
Similar Threads
-
How to ROTATE a video (quicktime or anything)
By nerys in forum EditingReplies: 2Last Post: 21st May 2011, 06:45 -
Rotate video without transcoding?
By tehguy in forum EditingReplies: 5Last Post: 5th Sep 2010, 12:29 -
Rotate Video - No re-encode?
By therock003 in forum EditingReplies: 2Last Post: 26th Jul 2010, 04:26 -
rotate video 90 degrees?
By cduval04 in forum EditingReplies: 6Last Post: 8th May 2008, 12:53