Log in

View Full Version : MPEG2DEC3.Dll and GordianKnot.


ZeImp
1st August 2003, 13:04
Hello,

I want know if GordianKnot directly use the MPEG2DEC3 dll (or only the old MPEG2DEC dll) and if the latest release is able to open .d2v files produced by DVD2AVI version 1.77 or +. I didn't find any call to this dll in the GordianKnot source code !

A+
ZeImp

japouleripeur
1st August 2003, 14:45
Mpegdec(3) is used by avisynth (look in .avs).
Mpegdec is compatible with avisynth 2.0x
Mpegdec3 is compatible with avisynth 2.5x

ZeImp
2nd August 2003, 00:55
I don't want use this dll in a AviSynth script but directly in a Delphi Unit (as the ols MPEG2DEC dll) in order to give video informations on a d2v file !

the problem is that the old MPEG2DEC dll can't open new d2v files (created by DVD2AVI version 1.77 or highter) !

The exported functions names of the old MPEG2DEC dll are:

'_openMPEG2Source@4'
'_closeVideo@0'
'_getRGBFrame@4'
'_getFrame@4'

The exported functions names of the new MPEGDEC3 dll are:

'openMPEG2Source'
'closeVideo'
'getRGBFrame'
'getFrame'

Just changing this names doesn't work !

The VideoInfo type has changed :(
(the *openMPEG2Source* functions return a pointer to a VideoInfo object !)

This Delphi type works fine with the old MPEG2DEC Dll:

TVideoInfo = record
Width : Integer ; // =0 means no video.
Height : Integer ;
Fps_Numerator : Integer ;
Fps_Denominator : Integer ;
Num_Frames : Integer ;
Pixel_Type : Word ;
Audio_Samples_Per_Second : Integer ; // =0 means no audio.
Num_Audio_Samples : Integer ;
Stereo : Boolean ;
Sixteen_Bit : Boolean ;
Field_Based : Boolean ;
end;

Reading source code of the MPEG2DEC3 Dll I try to use this new type (but it doesn't work !)

TVideoInfo = record
Width : Integer ; // =0 means no video.
Height : Integer ;
Fps_Numerator : Cardinal ;
Fps_Denominator : Cardinal ;
Num_Frames : Integer ;
Pixel_Type : Integer ;
Audio_Samples_Per_Second : Integer ; // =0 means no audio.
Sample_Type : Integer ;
Num_Audio_Samples : Int64 ;
nChannels : Integer ;
end;

If someone can help me about that ... he's welcome :sly:

A+
ZeImp

bond
2nd August 2003, 15:10
sorry cant help you as i am no developer

but post your question here (http://forum.doom9.org/showthread.php?s=&threadid=53164) as this is the mpeg2dec3 development thread!

len0x
12th August 2003, 10:10
When I was converting GK to work with mpeg2dec3.dll all I have to do is change the names of functions to normal ones, i.e. without underscore and @... and also change call type from "stdcall" to "cdecl". that's it.

p.s. getRGBFrame function returns fields in a different order than in old mpeg2dec.dll

p.p.s. all this code is in the current CVS of GK