G
Guest
Guest
Archived from groups: rec.video.desktop (More info?)
I'd like to edit video (MPEG1) with accuracy of ONE frame, not
15-frame-unit.
Some folks believe this is either impossible or requires decoding and
re-encoding the whole video file/set of files. Incorrect!
Here's the general idea, how:
Example: Remove commercials from a video file recorded from TV (and do
it in a professional manner):
1. mark the last frame before the commercials
2. mark the first frame after the commercials
3. decode the 15-frame-sets (2 pieces) that marks 1 and 2 point into.
4. Check if the wanted portions of these 2 pieces of 15-frame-sets
total maximum of 15 frames or over 15 frames.
5a. if they total exactly 15 frames, then just take those 15 frames.
5b. if they total less than 15 frames, then either duplicate the last
frame before the removed portion, or the first frame after the removed
portion, or insert black frames. Duplicate enough to get a total of 15
frames.
5c. if they total more than 15 frames, then do as 15b, but duplicate
until there are 30 frames
6. now re-encode those 15 or 30 frames to 1 or 2 15-frame-set(s).
This is a lot faster than re-encoding the whole file. It also avoids
the quality loss involved in re-encoding the whole file (except, of
course, the about 1 second surrounding each removed area).
7. edit the audio accordingly, the only rule is that you must remove
at least the same amount of audio as you remove video. If you remove
more, just insert silence audio to make the audio length equal to
video length.
8. Save the new file (or file set, if you must save more than 4 GiB
and you are using FAT or FAT32, or want the resulting file be
compatible with those file systems, with NTFS or Linux you may be able
to write a file bigger than 4 GiB)
9. Done !
NOW:
Is there any either free or inexpensive software to do this?
If not, any ideas, where to find all the necessary information to make
one.
I have done video programming but that was using VFW (Video for
Windows).
New software should use DirectX instead, it is capable of more
functions than do VFW.
With VFW I was faced with one problem: There are AVIStreamWrite and
AVIStreamRead, but how to write the file header? I found no solution
except to copy a "template" file that was recorded using some existing
video software, and then edited to remove all but the first
frame/15-frame-set.
I'd like to edit video (MPEG1) with accuracy of ONE frame, not
15-frame-unit.
Some folks believe this is either impossible or requires decoding and
re-encoding the whole video file/set of files. Incorrect!
Here's the general idea, how:
Example: Remove commercials from a video file recorded from TV (and do
it in a professional manner):
1. mark the last frame before the commercials
2. mark the first frame after the commercials
3. decode the 15-frame-sets (2 pieces) that marks 1 and 2 point into.
4. Check if the wanted portions of these 2 pieces of 15-frame-sets
total maximum of 15 frames or over 15 frames.
5a. if they total exactly 15 frames, then just take those 15 frames.
5b. if they total less than 15 frames, then either duplicate the last
frame before the removed portion, or the first frame after the removed
portion, or insert black frames. Duplicate enough to get a total of 15
frames.
5c. if they total more than 15 frames, then do as 15b, but duplicate
until there are 30 frames
6. now re-encode those 15 or 30 frames to 1 or 2 15-frame-set(s).
This is a lot faster than re-encoding the whole file. It also avoids
the quality loss involved in re-encoding the whole file (except, of
course, the about 1 second surrounding each removed area).
7. edit the audio accordingly, the only rule is that you must remove
at least the same amount of audio as you remove video. If you remove
more, just insert silence audio to make the audio length equal to
video length.
8. Save the new file (or file set, if you must save more than 4 GiB
and you are using FAT or FAT32, or want the resulting file be
compatible with those file systems, with NTFS or Linux you may be able
to write a file bigger than 4 GiB)
9. Done !
NOW:
Is there any either free or inexpensive software to do this?
If not, any ideas, where to find all the necessary information to make
one.
I have done video programming but that was using VFW (Video for
Windows).
New software should use DirectX instead, it is capable of more
functions than do VFW.
With VFW I was faced with one problem: There are AVIStreamWrite and
AVIStreamRead, but how to write the file header? I found no solution
except to copy a "template" file that was recorded using some existing
video software, and then edited to remove all but the first
frame/15-frame-set.