Log in

View Full Version : GOP: Closed, Open w/QuEnc


Ebobtron
10th January 2005, 05:35
Have three examples of closed GOP structures which confuse me.

First is from my capture hardware a Pinnacle movie box and the second is the Pinnacle MPEG encoder from Studio 8. The third is QuEnc.

Pinnacle Hardware Encoder:

15 IBBPBBPBBPBBPBB Closed

Pinnacle Software Encoder:

16 IPBBPBBPBBPBBPBB Closed

QuEnc Encoder:

16 IPBBPBBPBBPBBPBB Closed

15 IBBPBBPBBPBBPBB Open

The material that I capture or encode is normally at 6000kbps 720x480. Home movies and slide shows for sharing with the family. On occasion I have captured a movie for the grandchild and burned it to DVD.

The demuxed and trimmed output from the capture hardware is good, very good. The edited videos and slide-shows from Pinnacle‘s software encoder are also very good. Once demuxed and sent though the authoring process (not the Studio authoring process)

So far my luck with QuEnc is less than very good , but I prevail.

Once I understood AviSynth’s little habit of outputting everything as BFF and that you shouldn’t freely crop and resize interlaced sources I ran into some trouble with screen artifacts on scene change and noisy fades to and from black on my standalone DVD player.

So far the discs burned using QuEnc were encode using open GOP set to 15 and 2 like my hardware output only not closed.

The main question :
Is closing the GOP going to kill the artifacts or is my standalone DVD player from Panasonic just hard to please?

Question 2:
Does GOP structure have anything to do with opened or closed?


Every player I have tried on my computer plays the QuEnc encodes beautifully.

I have compared the QuEnc output to the original within AniSynth using compare and subtract and I am impressed.

BTW:

Does the muxed output have PTS and DTS trouble ?


“ *PTS underflow (Mux Error)...!!
*DTS underflow (Mux Error)...!!
*PTS//DTS Out of Sync (Mux Error)...!! “

From: MPEG-2 Validator v1.4.0.131

Thanks,

Ebob

hank315
10th January 2005, 22:32
The main question :
Is closing the GOP going to kill the artifacts or is my standalone DVD player from Panasonic just hard to please?For Quenc this might help.

Question 2:
Does GOP structure have anything to do with opened or closed?Yes and no, it depends on how you define a closed GOP and if you also count the playback order as part of the GOP structure.

A GOP is closed when the closed_gop flag is set in the GOP-header.
This affects the way how the first B frame(s) after the I frame is treated.

If we take the first sequence as an example (Pinnacle Hardware Encoder)
IBBPBBPBBPBBPBB Closed
The normal playback order for this is:

I B B P B B P B B P B B P B B
2 0 1 5 3 4 8 6 7 11 9 10 14 12 13

The 2 B frames which will be displayed first (0, 1) are normally predicted from the last P frame of the previous GOP and the I frame.
But because the GOP is closed there can be no relation with the previous GOP so the prediction should only be made from the I frame (backward prediction).
Creating such a closed GOP is very rare, a normal way to do it is the way Quenc does it: IPBBPBBPBBPBBPBB (CCE does something similar)

playback order:
I P B B P B B P B B P B B P B B
0 3 1 2 6 4 5 9 7 8 12 10 11 15 13 14

Now the first 2 B frames can be predicted between the I frame (forward prediction) and the P frame (backward prediction) because the decoder has already these IP frames decoded before decoding the 2 B frames.

The playback order of the frames is also written in the bitstream (AKA as temporal reference in the picture header) but some (hardware) decoders don't rely on this and have their own interpretation on how the order should be depending of the picturetype etc.
If Quenc inserts a closed GOP on a scene change it does not set the closed_gop flag for that GOP.
Closing all GOPS might help you on this because Quenc will then set the closed_gop flag for each GOP and maybe your player will do a better job.