Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 31st July 2003, 04:35   #281  |  Link
litz
HDTV Junkie
 
litz's Avatar
 
Join Date: Oct 2001
Location: Atlanta, GA
Posts: 34
Corrupt frames bypass?

? ...

How hard would it be to add a flag that would allow mpeg2dec3.dll to re-use the last good frame, or simply make a best "guess", when it runs across a corrupt frame?

Often when working with HDTV stream files, there's *1* bad frame or so in there. And mpeg2dec3.dll completely breaks down when it finds it, causing avisynth to return ALL frames henceforth as a read execption error.

This is a HUGE time waster, as the entire encode (which is often many hours long) has to be redone from scratch.

If there was a way to set it to 1) return the error, 2) make a best guess, or 3) re-use last good frame, that'd be verrrrrrrrrry useful.

thanks !

- litz
__________________
Thrills! Chills! Magic! Prizes!
litz is offline   Reply With Quote
Old 31st July 2003, 11:20   #282  |  Link
symonjfox
IUUULEEEENZ
 
symonjfox's Avatar
 
Join Date: Mar 2002
Location: Italy
Posts: 452
Yes, it's a bad thing. I capture from DVB and I've the same problem.
To tell the truth from Mpeg2dec3 1.08 many things went better: I have no more crashes on bad streams.

If it crashes, you should try Mpegdecoder.dll instead that works with bad frames quite well.

Instead, I'd like to get a FULLMPEG Decoder (Video, audio) but with an intelligent error menagement (it will very very useful for DVB capturer ... just capture & encode ... It should use Time Stamps in the MPEG stream, to correct and try to preserve the most frames as possible (not like PVAstrumento that cuts thousand of GOPS).

I know that it would be difficult, and I'm not complaining about anything. Just would be nice.
__________________
PC1:AMD Athlon II x4, 4GB DDR2, Ati Radeon 4830, 4 hard disks
symonjfox is offline   Reply With Quote
Old 31st July 2003, 11:56   #283  |  Link
Nic
Moderator
 
Join Date: Oct 2001
Location: England
Posts: 3,285
@litz: Is there anyway you could upload just a bit of a stream that causes that problem ? Like the first frames are ok, then it hits the bad one and all the rest are broken.... If you can upload a clip like that, it shouldn't be hard to fix. But without being able to re-produce it, I doubt I can fix it

@Tom: Works fine for me. Koepi recently corrected it so it was W3C compliant, so I don't know what the problem would be? Anyone else having troubles?

-Nic
Nic is offline   Reply With Quote
Old 31st July 2003, 13:27   #284  |  Link
killingspree
Newbie Forum Mod
 
killingspree's Avatar
 
Join Date: Aug 2002
Location: way too deep in (cyber)space
Posts: 2,436
"Koepi recently corrected it so it was W3C compliant, so I don't know what the problem would be? Anyone else having troubles?"

is working perfectly fine, tried it with IE 6.0 and firebird (.6)

steVe
__________________
Search the forum, read the forum rules once more and use the search function on doom9.org before posting!
oh btw my amazon.de wishlist
killingspree is offline   Reply With Quote
Old 31st July 2003, 16:29   #285  |  Link
trbarry
Registered User
 
trbarry's Avatar
 
Join Date: Oct 2001
Location: Gainesville FL USA
Posts: 2,092
Quote:
is working perfectly fine, tried it with IE 6.0 and firebird (.6)
Works fine for me with IE but not with Opera 6.05. And Opera upgrades cost money.

- Tom

edit: I can access Koepi's site just fine except maybe for the link to the latest documentation.
__________________
My video filters (still) at www.trbarry.com.

Last edited by trbarry; 31st July 2003 at 16:34.
trbarry is offline   Reply With Quote
Old 31st July 2003, 19:49   #286  |  Link
bilu
Registered User
 
bilu's Avatar
 
Join Date: Oct 2002
Location: Portugal
Posts: 1,182
@trbarry

Why upgrade Opera?

http://www.mozilla.org/products/firebird/why/



Bilu
bilu is offline   Reply With Quote
Old 1st August 2003, 02:41   #287  |  Link
litz
HDTV Junkie
 
litz's Avatar
 
Join Date: Oct 2001
Location: Atlanta, GA
Posts: 34
Sample .ts w/bad frames

Quote:
Originally posted by Nic
@litz: Is there anyway you could upload just a bit of a stream that causes that problem ? Like the first frames are ok, then it hits the bad one and all the rest are broken.... If you can upload a clip like that, it shouldn't be hard to fix. But without being able to re-produce it, I doubt I can fix it

-Nic

Sure !

http://terminus.litz.org/smallville_test.ts

It'll take a bit ... 23mb in size and only 384k upload bandwidth.

Bad spot is on frames 175-179. mpeg2dec3.dll crashes, mpegdecoder.dll slices right through no errors, blocking or other problems. Running in native yv12.

Script used (telecide/decimate commented out for testing) :

SetMemoryMax(64)

loadplugin("C:\Program Files\AviSynth 2.5\plugins\MPEGDecoder.dll")
loadplugin("C:\Program Files\AviSynth 2.5\plugins\MPEG2dec3.dll")
loadplugin("C:\Program Files\AviSynth 2.5\plugins\Decomb.dll")

#MpegSource("h:\test\test.d2v")
Mpeg2Source("h:\test\test.d2v", iPP=true, idct=6)

#Telecide(guide=1)

#Decimate(cycle=5)

LanczosResize(720,480)



- litz
__________________
Thrills! Chills! Magic! Prizes!
litz is offline   Reply With Quote
Old 1st August 2003, 10:49   #288  |  Link
Nic
Moderator
 
Join Date: Oct 2001
Location: England
Posts: 3,285
Thanks alot litz....the crash happens in the motion compensation on frame 175. Ill try and find out why asap

edit: well it's easy to stop it crashing, you just check memory bounds. It's crashing on the same place me and sh0dan patched last time. However, these little hacks we put in to stop it crashing aren't great (i.e. it causes that frame to be corrupt...but at least it can recover and the rest are ok). I need to look into this more

(ps for anyone else looking into it:
in ::form_prediction in getpic.c add:
if ( s - src[0] > LUM_AREA )
{
Fault_Flag = 5;
return;
}

to stop the crash (you can also breakpoint there to see whats going on)

-Nic

ps
well dvd2avi crashes on it as well...Hmmm, you might end up having to put with the corrupt frame. Ill keep working on it.

Last edited by Nic; 1st August 2003 at 11:46.
Nic is offline   Reply With Quote
Old 1st August 2003, 13:55   #289  |  Link
litz
HDTV Junkie
 
litz's Avatar
 
Join Date: Oct 2001
Location: Atlanta, GA
Posts: 34
mpegdecoder.dll is unaffected

What is odd is that mpegdecoder.dll just blows right on past that frame and decodes it perfectly.

- litz

Quote:
Originally posted by Nic
Thanks alot litz....the crash happens in the motion compensation on frame 175. Ill try and find out why asap

edit: well it's easy to stop it crashing, you just check memory bounds. It's crashing on the same place me and sh0dan patched last time. However, these little hacks we put in to stop it crashing aren't great (i.e. it causes that frame to be corrupt...but at least it can recover and the rest are ok). I need to look into this more

(ps for anyone else looking into it:
in ::form_prediction in getpic.c add:
if ( s - src[0] > LUM_AREA )
{
Fault_Flag = 5;
return;
}

to stop the crash (you can also breakpoint there to see whats going on)

-Nic

ps
well dvd2avi crashes on it as well...Hmmm, you might end up having to put with the corrupt frame. Ill keep working on it.
__________________
Thrills! Chills! Magic! Prizes!
litz is offline   Reply With Quote
Old 1st August 2003, 21:12   #290  |  Link
symonjfox
IUUULEEEENZ
 
symonjfox's Avatar
 
Join Date: Mar 2002
Location: Italy
Posts: 452
Hi, I've just found a nice M2V stream wich causes matters with Mpeg2dec3 and works fine with Mpegdecoder.

The strange is that is taken from DVD not DVB, so in theory there shouldn't be any problem since I had 0 errors during the ripping-demuxing process (doitfast4you). It causes an overflow in CCE 2.67 so I couldn't finish the encode.

I'd like to share it (so you could find where's the bug) but it's on the 5th GB of a 5.5 GB file. How could I perfectly trim it (without any modifications of the stream)?

PS: I'm sorry to ask you this stupid think, but I searched a lot on every avisynth plugin, but I didn't find an answer. Is it a way to use CPU parameter to deblock dering without Mpeg2Dec3 (I like this Algorithm, it gives me a very nice quality)? Is it a plugin that just does these things? Thanks
__________________
PC1:AMD Athlon II x4, 4GB DDR2, Ati Radeon 4830, 4 hard disks
symonjfox is offline   Reply With Quote
Old 2nd August 2003, 06:49   #291  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Use vobsplit.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 2nd August 2003, 07:49   #292  |  Link
DJ Alik
Registered User
 
Join Date: Mar 2002
Location: USA
Posts: 99
Quote:
Originally posted by Nic
Ok, No Need. I've fixed the problem. New build (1.10) at my site ( http://nic.dnsalias.com )

It only occured with 1.77.3 style D2V files. Sorry about that My mistake.

-Nic
file version is incorrect you have it as 1.0.1.0 not 1.0.10.0 could be confusing to people who upgraded from 1.0.8.0
__________________
~~~~~~~~~~~~~~~~~~~~~~~~
Intel i7 920
ASUS P6T Deluxe V2 Mboard
6GB DDR-3 Crucial XMS RAM
Visiontek ATI 4850
Sound Blaster Audigy
DJ Alik is offline   Reply With Quote
Old 2nd August 2003, 15:37   #293  |  Link
ZeImp
Registered User
 
Join Date: Jun 2003
Location: Paris [France]
Posts: 20
Delphi Unit for MPEG2DEC3.DLL

The exported functions names of the new MPEGDEC3 dll are:

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

In order to import this functions in Delphi use cdecl option and not stdcall.

A+
ZeImp
__________________
ZeImp - http://avsgenerator.unite-video.com/ - AVSGenerator

Last edited by ZeImp; 4th August 2003 at 02:25.
ZeImp is offline   Reply With Quote
Old 2nd August 2003, 17:01   #294  |  Link
Nic
Moderator
 
Join Date: Oct 2001
Location: England
Posts: 3,285
You already posted about this in the development forum and got the right answer!
http://forum.doom9.org/showthread.php?s=&threadid=58658

Look in GKnot to see how it does it! VideoInfo has changed because avisynth 2 updated it. If you get real stuck ask one of the main GKnot developers, but keep your posts in the development forum.

-Nic
Nic is offline   Reply With Quote
Old 2nd August 2003, 18:44   #295  |  Link
ZeImp
Registered User
 
Join Date: Jun 2003
Location: Paris [France]
Posts: 20
Yes that's right !
Sorry ...

A+
ZeImp
__________________
ZeImp - http://avsgenerator.unite-video.com/ - AVSGenerator
ZeImp is offline   Reply With Quote
Old 3rd August 2003, 08:15   #296  |  Link
litz
HDTV Junkie
 
litz's Avatar
 
Join Date: Oct 2001
Location: Atlanta, GA
Posts: 34
dvd2avi vs mpeg2dec3.dll vs mpegdecoder.dll

Quote:
Originally posted by Nic

ps
well dvd2avi crashes on it as well...Hmmm, you might end up having to put with the corrupt frame. Ill keep working on it.
Just out of curiosity, what is it about dvd2avi and mpeg2dec3.dll that causes the crash on that frame, and mpegdecoder.dll does *not* ?

For instance, I re-encoded the original .ts the sample came from using mpegdecoder and it did the entire thing flawlessly.

But while mpegdecoder is nice, mpeg2dec3.dll handles 1080i material MUCH better than mpegdecoder, which sometimes causes weird color shifting stuff, almost like the color fields don't get properly aligned. Very psychadelic, but as this isn't Pink Floyd, it's not optimal ...

:-)

- litz

(btw, like my avatar ?)
__________________
Thrills! Chills! Magic! Prizes!
litz is offline   Reply With Quote
Old 4th August 2003, 00:29   #297  |  Link
Nic
Moderator
 
Join Date: Oct 2001
Location: England
Posts: 3,285
They are two completely different decoders, libmpeg2 was designed to have a nice state oreintated approach and has good error handling. mpeg2dec3 is basically the MSSG MPEG code with nice Assembly optimisation. Hence one handles it well, the other doesn't (also mpeg2dec3 has built in repeat-field-flag code, libmpeg2 doesnt can't have everything)

Can't make out what your avatar is supposed to be but looks nice. Pf effects just with MPEGDecoder ...they could save all that money on effects and Dave could buy a few more planes

-Nic
Nic is offline   Reply With Quote
Old 6th August 2003, 14:07   #298  |  Link
deXtoRious
Registered User
 
Join Date: Feb 2003
Location: Riga, Latvia
Posts: 192
I've got a problem with AviSynth. AutoRV9, VDubMod and other programs show an "Evaluate: Unrecognised exception" error when opening a d2v file created for a vob with a filesize of over 4 gigabytes. The file system is NTFS. Is it an issue of MPEG2DEC3? Is it possible to overcome this problem?
deXtoRious is offline   Reply With Quote
Old 6th August 2003, 19:26   #299  |  Link
Asmodian
Registered User
 
Join Date: Feb 2002
Location: San Jose, California
Posts: 4,407
I can open d2v's created with DVD2AVI 1.76 from vobs >6Gb with mpeg2dec3 v1.10. I am on winXP sp1 with NTFS (of course)
Asmodian is offline   Reply With Quote
Old 6th August 2003, 19:59   #300  |  Link
deXtoRious
Registered User
 
Join Date: Feb 2003
Location: Riga, Latvia
Posts: 192
Well, I still can't open the file... I made sure my avs script was as primitive as possible:
  • #Loading plugins
    LoadPlugin("C:\Program Files\AviSynth 2.5\Plugins\Mpeg2Dec3.dll")

    #Opening file
    MPEG2SOURCE("E:\Video\DVD\Basic\Basic.d2v")

    trim(13112,29824)


It still shows the same error (tried with AutoRV9, VDubMod and WMPlayer)
deXtoRious is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 18:45.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.