pinterf / AviSynthPlus

AviSynth with improvements
http://avs-plus.net
208 stars 24 forks source link

Using VirtualDub plugins causes exceptions #12

Closed magiblot closed 5 years ago

magiblot commented 6 years ago

Just calling LoadVirtualdubPlugin(..) doesn't cause any problems. But trying to apply the filter to a clip causes exceptions. The exceptions are "ignored" by AvsPmod or MPC-HC (AvsPmod might show notifications on its error window without crashing, and MPC reports the exception when closing). I'm using the last version of Avs+ (r2508) and AVSMeter (264), which reports:

AviSynth+ 0.1 (r2508, MT, i386) (0.1.0.0) System exception - Access Violation

The same error is reported by VirtualDub FilterMod, so it can't run the script. I've tried filters like colorize and gradation. Everything works fine in AviSynth 2.6. I can provide more information about how I'm using the filters in my script if you need it, but I expect you to reproduce the error easily, so I'll leave it here.

Thanks!

pinterf commented 6 years ago

Could you please help me with a link to these filters and a typical short script that I can copy paste and reproduce the crash?

magiblot commented 6 years ago

Let's see it this works fine: CrashSimulation.zip

magiblot commented 6 years ago

Can this problem be fixed? Do you need more information? Thanks.

pinterf commented 6 years ago

Thanks for the sample but there is no solution yet. When a specific vdub filter is instantiated more than once, it gives C000005 access violation, on exit. I suppose VDubFilter.dll is probably trying to free up an already freed resource; And I realized that I have already spent some days on a similar problem. Filter chain parent (or whatever it is) is freed up for the first filter instance, but if the filter is invoked twice, it gives access violation on the second one. Work in progress.

magiblot commented 6 years ago

Alright. If it can be of any help, LoadVirtualDubFilter seems to work fine in AviSynth 2.6 and its variants. Thank you very much.

pinterf commented 6 years ago

Fixed in https://github.com/pinterf/AviSynthPlus/commit/78361dc2e53168514c760c337ecfdb87b973fff4

magiblot commented 6 years ago

Absolutely awesome. Lots of thanks.