| Author |
Message |
Guest
|
Posted:
Mon Dec 06, 2004 6:22 pm Post subject:
cropping video and quality? |
|
|
Hi,
I know that when you open up a JPEG image and edit/crop it, then save it,
you lose quality. Is it the same case with Divx - are programs smart enough
so that when I open up the video and save it, it doesn't re-compress the
frames, if I just crop it, it leaves the compression untouched and therefore
don't lose any more quality?
Thanks!
|
|
| Back to top |
|
 |
RivaScoot
Guest
|
Posted:
Mon Dec 06, 2004 6:22 pm Post subject:
Re: cropping video and quality? |
|
|
On Mon, 6 Dec 2004 09:36:32 -0800, <nospam@nospam.net> wrote:
| Quote: | Hi,
I know that when you open up a JPEG image and edit/crop it, then save it,
you lose quality. Is it the same case with Divx - are programs smart enough
so that when I open up the video and save it, it doesn't re-compress the
frames, if I just crop it, it leaves the compression untouched and therefore
don't lose any more quality?
Thanks!
|
If you're wanting to crop the black bars on a DVD you're encoding,
quality will not be lost.
RivaScoot |
|
| Back to top |
|
 |
Christian Link
Guest
|
Posted:
Mon Dec 06, 2004 7:32 pm Post subject:
Re: cropping video and quality? |
|
|
On Mon, 6 Dec 2004 09:36:32 -0800, <nospam@nospam.net> wrote:
| Quote: | I know that when you open up a JPEG image and edit/crop it, then save it,
you lose quality. Is it the same case with Divx - are programs smart enough
|
Seeing as both are lossy compression algorithms (standard JPEG is, anyway),
you'll naturally lose quality whenever you resave (as opposed to just
copying/streaming, which would not allow you to change the actual contents,
though).
| Quote: | so that when I open up the video and save it, it doesn't re-compress the
frames, if I just crop it, it leaves the compression untouched and therefore
don't lose any more quality?
|
You can't, as smallest unit for an MPEG video is an 8 x 8 DCT block. So,
unless you crop on exact 8 x 8 borders, you naturally affect blocks with
content that's supposed to be kept (at least partially). Also, the cropped
result (again: unless it had been cropped with the DCT block grid in mind)
would use another coordinate offset, i.e. you'd shift the whole grid, hence
screwing up the block references. Conclusion: You have to repack in these
cases, and as stated above, that will always be lossy.
"Lossless cropping" on DCT boundaries may theoretically be possible if your
video only uses I frames, however, as it would leave the remaining blocks of
each frame untouched. Still, a reorganization of the blocks themselves would
certainly remain necessary, and so a program would have to be designed
specifically for that purpose (*if* it's possible at all, of which I'm not
too sure), and as far as I know, no such program exists (yet?).
Chris |
|
| Back to top |
|
 |
Guest
|
Posted:
Tue Dec 07, 2004 6:10 am Post subject:
Re: cropping video and quality? |
|
|
So if I simply cut the first few minutes or last few minutes of a video (or
even slice some out in the middle), would that count as resaving? I'm not
trying to modify the actual frames, just trying to excise certain frames
from the stream.
"Christian Link" <C.LinkSPAMBLOCK@GMX.net> wrote in message
news:lva9r09c6nvb8g5rev4r5g4hrg75ge568e@4ax.com...
| Quote: | On Mon, 6 Dec 2004 09:36:32 -0800, <nospam@nospam.net> wrote:
I know that when you open up a JPEG image and edit/crop it, then save it,
you lose quality. Is it the same case with Divx - are programs smart
enough
Seeing as both are lossy compression algorithms (standard JPEG is,
anyway),
you'll naturally lose quality whenever you resave (as opposed to just
copying/streaming, which would not allow you to change the actual
contents,
though).
so that when I open up the video and save it, it doesn't re-compress the
frames, if I just crop it, it leaves the compression untouched and
therefore
don't lose any more quality?
You can't, as smallest unit for an MPEG video is an 8 x 8 DCT block. So,
unless you crop on exact 8 x 8 borders, you naturally affect blocks with
content that's supposed to be kept (at least partially). Also, the
cropped
result (again: unless it had been cropped with the DCT block grid in mind)
would use another coordinate offset, i.e. you'd shift the whole grid,
hence
screwing up the block references. Conclusion: You have to repack in these
cases, and as stated above, that will always be lossy.
"Lossless cropping" on DCT boundaries may theoretically be possible if
your
video only uses I frames, however, as it would leave the remaining blocks
of
each frame untouched. Still, a reorganization of the blocks themselves
would
certainly remain necessary, and so a program would have to be designed
specifically for that purpose (*if* it's possible at all, of which I'm not
too sure), and as far as I know, no such program exists (yet?).
Chris |
|
|
| Back to top |
|
 |
Christian Link
Guest
|
Posted:
Tue Dec 07, 2004 6:11 am Post subject:
Re: cropping video and quality? |
|
|
On Mon, 6 Dec 2004 19:17:01 -0800, <nospam@nospam.net> wrote:
| Quote: | So if I simply cut the first few minutes or last few minutes of a video (or
even slice some out in the middle), would that count as resaving? I'm not
|
This depends on whether you're using a program that always recompresses,
just streams, or leaves it up to you whether you want to use recompression
or simple streaming :-) . VirtualDub gives you the choice (pulldown menu
"Video").
| Quote: | trying to modify the actual frames, just trying to excise certain frames
from the stream.
|
But you said cropping. Excuse me if I'm wrong, as English isn't my native
language, but it always seemed to me that you guys use cropping rather for
the spatial stuff (e. g., cropping away black borders), while what you
describe above would rather be trimming (or rather cutting, if you refer to
frames in the middle). In that case, you may get away with your "trims"
without recompression (use VirtualDub's "Direct stream copy" mode from the
Audio/Video menues), if either of these applies:
a) Your video only consists of I (intra-/key-)frames, which don't rely on
any other frame in your video, so you can do without the to-be-cropped
frames, or
b) you cut your video on keyframe borders, i. e. every remaining segment has
to start (but not necessarily to end) on a keyframe.
Oh, and of course, the application you use *still* has to support plain
streaming. If it forces a recode, the whole discussion is moot, anyway ;-) .
Chris |
|
| Back to top |
|
 |
Guest
|
Posted:
Fri Dec 10, 2004 6:05 am Post subject:
Re: cropping video and quality? |
|
|
Thanks! I think I was wrong in my terminology, and English _is_ my native
language :).
I'll check out virtualdub!
"Christian Link" <C.LinkSPAMBLOCK@GMX.net> wrote in message
news:tgdar0pv9pkkp23pvhos64645o1gcdfh3b@4ax.com...
| Quote: | On Mon, 6 Dec 2004 19:17:01 -0800, <nospam@nospam.net> wrote:
So if I simply cut the first few minutes or last few minutes of a video
(or
even slice some out in the middle), would that count as resaving? I'm not
This depends on whether you're using a program that always recompresses,
just streams, or leaves it up to you whether you want to use recompression
or simple streaming :-) . VirtualDub gives you the choice (pulldown menu
"Video").
trying to modify the actual frames, just trying to excise certain frames
from the stream.
But you said cropping. Excuse me if I'm wrong, as English isn't my native
language, but it always seemed to me that you guys use cropping rather for
the spatial stuff (e. g., cropping away black borders), while what you
describe above would rather be trimming (or rather cutting, if you refer
to
frames in the middle). In that case, you may get away with your "trims"
without recompression (use VirtualDub's "Direct stream copy" mode from the
Audio/Video menues), if either of these applies:
a) Your video only consists of I (intra-/key-)frames, which don't rely on
any other frame in your video, so you can do without the to-be-cropped
frames, or
b) you cut your video on keyframe borders, i. e. every remaining segment
has
to start (but not necessarily to end) on a keyframe.
Oh, and of course, the application you use *still* has to support plain
streaming. If it forces a recode, the whole discussion is moot, anyway ;-)
.
Chris |
|
|
| Back to top |
|
 |
|
|
|
|