PDA

View Full Version : issue about converting DV-Video to Mpeg2 video


ravin
3rd June 2005, 10:47
DV video consists of compressed macro block, mpeg2 aslo is comprised with Macro block, but mpeg2 have more flexiable and scalable synax uppon the macro block, Do anybody know how to convert DV macro block into Mpeg2 video(m2v) without any transcoding?

If my proposal is implemented, I think that converting DV to DVD will be faster than before.

Could you give me some tips?

SomeJoe
5th June 2005, 17:40
Theoretically, since both encoding methods are DCT-based, what you say has some possibility.

However, there are many complexities. DV is intra-frame compressed, based on the older MJPEG codecs, where each frame is independent (an I frame). MPEG-2 is inter-frame compressed, where frames have compression dependencies on adjacent frames in their GOP (IBP frames). To convert, each non-I frame in the resulting MPEG-2 GOP would have to be compared to the I frame and motion vectors calculated.

Since computation of the motion vectors is the major computation-intensive portion of MPEG-2 encoding (the DCT compression is relatively quick), I'm not sure you could save much compression/conversion time.

Another problem is that the DCT compression in DV may not have compatible quantization matrices or huffman encoding to be directly usable in MPEG-2. If you have to undo any of the DV DCT process to make it compatible with MPEG-2, you will not end up saving any time for compression.

A final problem affects NTSC DV. The chroma downsampling of NTSC DV is 4:1:1 as opposed to MPEG-2's 4:2:0. This would certainly involve major rearranging of the data, resulting in no saved time. (PAL DV would be unaffected in this regard since PAL DV is already 4:2:0).

ravin
6th June 2005, 03:33
Thanks for your tips!

Theoretically, since both encoding methods are DCT-based, what you say has some possibility.

However, there are many complexities. DV is intra-frame compressed, based on the older MJPEG codecs, where each frame is independent (an I frame). MPEG-2 is inter-frame compressed, where frames have compression dependencies on adjacent frames in their GOP (IBP frames). To convert, each non-I frame in the resulting MPEG-2 GOP would have to be compared to the I frame and motion vectors calculated.

--------------------------------------------------
1.MPEG2 provides both intra-frame compression and inter-frame compression method, I think DV frame compression method is compatible with MPEG2.

Since computation of the motion vectors is the major computation-intensive portion of MPEG-2 encoding (the DCT compression is relatively quick), I'm not sure you could save much compression/conversion time.

--------------------------------------------------
3.Can I ignore all B,P frames, and only provide a sequence, and many gops containing only I frame? thus the motion compensation data can be ignored.

Another problem is that the DCT compression in DV may not have compatible quantization matrices or huffman encoding to be directly usable in MPEG-2. If you have to undo any of the DV DCT process to make it compatible with MPEG-2, you will not end up saving any time for compression.

---------------------------------------------------
4. Can we load DV intra-quantization matix to the matrix field of MPEG2 sequence header or slice? or can I re-quantizate DV macro block to Mpeg macro block according to Mpeg quantization matrices?

A final problem affects NTSC DV. The chroma downsampling of NTSC DV is 4:1:1 as opposed to MPEG-2's 4:2:0. This would certainly involve major rearranging of the data, resulting in no saved time. (PAL DV would be unaffected in this regard since PAL DV is already 4:2:0).

--------------------------------------------------
5. How much payload and effect will be taken by re-arranging 4:1:1 to 4:2:0?


Thanks again.

bb
6th June 2005, 18:47
1.MPEG2 provides both intra-frame compression and inter-frame compression method, I think DV frame compression method is compatible with MPEG2.
No, it's not compatible. E.g. DV can use different macro block sizes.
3.Can I ignore all B,P frames, and only provide a sequence, and many gops containing only I frame? thus the motion compensation data can be ignored.
Yes, there's I-frame only MPEG-2. But this way you won't decrease the file size much. Inter-frame compression is what MPEG-2 is all about - else you could use MJPEG, too.
5. How much payload and effect will be taken by re-arranging 4:1:1 to 4:2:0?
You'd have to do a complete reencoding.

Note that the largest amount of computing time is eaten by the motion search algorithm (> 90%). There's no quick way to convert DV to "regular" (let's say DVD compliant) MPEG-2.

bb

ravin
8th June 2005, 07:21
Much thanks for SomeJoe and bb's tips.