I am writing some software that analyses some underwater footage of the Great Barrier Reef, we are towing a camera at roughly 2 mph and capturing on DVC-Pro. I am converting the footage to MPEG. When we are analysing the footage and something of interst goes past the user will pause the image and take a snapshot of that frame, be it a fish, crab, prawn, reef, shark etc. The problem is that we store (in a database) a reference to that frame in either milliseconds or a frame number but when we attempt to return to that exact frame it is close but never exact. Now I understand a little about the compression and that it will return to the I frame frame which generally occurs about every 12ish frames. My question is; is there any way using mpegs I can return to that exact frame, is there an I frame only MPEG, is this a special CODEC. Any help would be appreciated. I do not want to use AVI files that I know we can return to the exact frame.
You could make a non-standard mpeg-2, with a GOP of 1. That may work with your database. BTW, I frames (in NTSC) occur every 18 frames, as there is usually 1 I frame per GOP.
Cheers Jim, Can you feed me a little more info. How would I go about doing this. We are, I believe using Pinnacle software to convert from the DVC-Pro to mpeg. I am not 100% sure what GOP is either.
GOP is a Group Of Pictures. Standard NTSC is 18 frames per GOP, each containing 1 I frame, 5 P frames, and 2 B frames. I know that doesn't add up to 18, but somewhere I'm sure there's an explanation for that...anyhow... When an mpeg is encoded, the I frames are where the "edit points" are (you know this already). What I'm suggesting is to put a closed GOP of 1, instead of 18, thus forcing an I frame every GOP, or a GOP every I frame... This is totally non-standard, and I'm not sure it would play on anything but a computer, but it should give you your editing/database accuracy. You would have to encode a test video this way, and see if it works. Alternatively, you could force an I frame for every frame, in a standard 18frame GOP. I have NO idea if Pinnacle can do this. Hunt through it's encoding section options/preferences, and see. I know Tmmpgenc 2.5 Plus can do it, but again, I have NO idea if it would actually play on a standalone player. These are just suggestions for you to try, and may be so far out of DVD spec, that it will never work.
I"m petty Sure that you can Make DVD Compliant I Frame Only Files..I believe the NTSC Standard Just Calls for a Gop Length of 18 frames or Less so with a GOP length of 1 frame it being an I frame it should be DVD compliant... I actually just Checked in Tmpgenc and used one of the Standard NTSC DVD Templates and I was able to set the GOP to 1 Frame it being an I Frame and with the DVD Templates it will not let you change anything to a setting that is Not DVD Compliant.... The Problem with I Frame only Video Files is that the File size will be Much Higher because I Frames are Less compressed than B or P Frames but the Quality should also be Very good.... So I suggest you maybe try the 1 I Frame GOP and see how it works for you...Cheers