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 11th November 2003, 05:50   #1  |  Link
fabrice
Registered User
 
Join Date: Feb 2003
Posts: 13
Memory leaks in Fluxsmooth: no destructor...

Hi,

I was trying to use Flusmooth in a scriptclip 'environnement', and I saw that there is a big memory leak in this filter.

I get the sources from sansgrip homepage, and I saw that the YV12 version don't have destructor...

Could someone modify the sources, to add this destructor (in the YV12.h file), with only this lines (like in the YUY version):

FluxSmooth_YV12::~FluxSmooth_YV12()
{
if(scaletab_MMX)
delete [] scaletab_MMX;
}

I think this is the only reason for the memory leak.

Thanks in advance,
Fabrice
fabrice is offline   Reply With Quote
Old 11th November 2003, 10:26   #2  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
I will look at it tonight!
Wilbert is offline   Reply With Quote
Old 11th November 2003, 20:21   #3  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
It gives the following error when compiling (I didn't add anything yet):

Code:
--------------------Configuration: Fluxsmooth - Win32 Release--------------------
Compiling...
FluxSmooth.cpp
F:\CompilingPlugins\Fluxsmooth\YUY2.h(471) : fatal error C1601: unsupported inline assembly opcode
Error executing cl.exe.

Fluxsmooth.dll - 1 error(s), 0 warning(s)
Lines 468-471:

Code:
// Store

packuswb mm1, mm7
movntq [edi + ecx], mm1
I hope someone has an idea what is going wrong here, since this is black magic to me

Complete source can be found here: http://www.jungleweb.net/~sansgrip/avisynth/

Last edited by Wilbert; 11th November 2003 at 20:23.
Wilbert is offline   Reply With Quote
Old 11th November 2003, 21:18   #4  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
movntq is an Integer SSE instruction, and it should compile nicely. Which compiler/processor pack (version) are you using?
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 11th November 2003, 21:32   #5  |  Link
Wilbert
Moderator
 
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
Oops I forgot to install the processor pack

But now I have a different problem. I got the VC++ 6.0 standard edition, and the processor pack needs the Enterprise or Professional edition What kind of nonsense is that

Sh0dan can you have a look at it?
Wilbert is offline   Reply With Quote
Old 11th November 2003, 22:28   #6  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Had a bit of fun too!

Anyway:

- Removed leak in AviSynth 2.5 YV12 mode (code by fabrice)
- Aligned tables and variables.
- Use AviSynth BitBlt for copying chroma.
- Don't use streaming store. (movntq)
All in all an approximate 15% speedup compared to previous version. All changes are marked with "sh0:".

Fluxsmooth 1.01
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 12th November 2003, 00:15   #7  |  Link
DDogg
Retired, but still around
 
DDogg's Avatar
 
Join Date: Oct 2001
Location: Lone Star
Posts: 3,058
damn this is good news, thanks to all of you!
DDogg is offline   Reply With Quote
Old 12th November 2003, 03:43   #8  |  Link
PowerMacG4
Oh boy
 
PowerMacG4's Avatar
 
Join Date: Nov 2002
Posts: 126
Quote:
Originally posted by Wilbert
Oops I forgot to install the processor pack

But now I have a different problem. I got the VC++ 6.0 standard edition, and the processor pack needs the Enterprise or Professional edition What kind of nonsense is that

Sh0dan can you have a look at it?
You can manually install it by right clicking on the INF and letting it 'install', and then dragging all the files into the right directories. I think that may only apply to the beta version, though. Worked for me..
PowerMacG4 is offline   Reply With Quote
Old 12th November 2003, 05:44   #9  |  Link
fabrice
Registered User
 
Join Date: Feb 2003
Posts: 13
Thanks to all, and especially sh0dan for compiling and optimizing it!

It's test time gain!

CU
Fabrice
fabrice is offline   Reply With Quote
Old 12th November 2003, 20:09   #10  |  Link
Druizk
Registered User
 
Join Date: Mar 2003
Location: México
Posts: 15
Thanks for all, particulary @shodan & @Wilbert.

Ago very months I have problem, these bit leak memory, VirtualDubMod no rebooting after of terminate list jobs.

the problem was eliminate with fluxsmooth 1.01.
__________________
:) VDudMod, AviSynth & DivX: Better :)
Druizk is offline   Reply With Quote
Old 13th November 2003, 16:30   #11  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,718
Quote:
Originally posted by sh0dan
Had a bit of fun too!

Anyway:

- Removed leak in AviSynth 2.5 YV12 mode (code by fabrice)
- Aligned tables and variables.
- Use AviSynth BitBlt for copying chroma.
- Don't use streaming store. (movntq)
All in all an approximate 15% speedup compared to previous version. All changes are marked with "sh0:".

Fluxsmooth 1.01
sh0dan,

as you seem to be fixing things a lot these days, would you mind taking a look at CNR2? It behaves really weird, CCE blows up immediately with CNR2 in the script. TMPGEnc crashes occasionally when closing the program, stating that cnr2.dll had something to do with it.

I believe that Don fiddled with the filter last time, there's a thread about that buried somewhere in the forum.

Thanks for the FluxFix
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 13th November 2003, 18:48   #12  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
cnr2.5.

Bugs should be fixed now.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 13th November 2003, 18:58   #13  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,718
What can I say - lightning fast action!

At least one analog capture freak owes you big time.

__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 13th November 2003, 19:14   #14  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,718
Hm, after a bit testing I noticed that it doesn't actually do anything. I tried with this script:

video=AVISource("c:\temp\captures\capture.avi",false)
video=video.FieldDeinterlace()
a=video.CNR2("ooo",255,255,255,255,255,255,255,false)
b=video
Subtract(a,b).Levels(127,1,129,0,255)

The version at the filter collection shows a lot of smoothing whereas the fixed one doesn't do anything
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 13th November 2003, 20:37   #15  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Yeah - YUY2 mode seems a bit unimpressed by the settings.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 13th November 2003, 21:20   #16  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,718
Quote:
Originally posted by sh0dan
Yeah - YUY2 mode seems a bit unimpressed by the settings.
It seems that both YV12 and YUY2 don't do anything to the clip - I ran a quick compressibility test and the filesize is the same with and without CNR2. Damn
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 14th November 2003, 00:47   #17  |  Link
vhelp
Registered User
 
vhelp's Avatar
 
Join Date: Feb 2003
Posts: 299
@ Boulder,

what source are you using VHS; Cable; Satellite ??

Or does it not matter. I thought that cnr2 was mainly for VHS source.

I'll give your source snip a try on my VHS captures I have laying around.
I'm curious to see if I get same results

-vhelp
__________________
ESC K7S5A / XP 1800+ / Windows 98
ADVC-100[dvio] / WTVGO[avio] / DC10+[avio] / Canon ZR-10 / Delphi 6 Personal / JVC S-VHS HR-S3910U / Durabrand SSS w/ DVD Player STS75E / Sony TRV-22
FithElement/Dogma/BladeRunner/Contact
vhelp is offline   Reply With Quote
Old 14th November 2003, 07:30   #18  |  Link
Boulder
Pig on the wing
 
Boulder's Avatar
 
Join Date: Mar 2002
Location: Finland
Posts: 5,718
I tried it on a analog TV cap, cable source. The difference between the bugfixed and the earlier version should be obvious as the settings are at maximum
__________________
And if the band you're in starts playing different tunes
I'll see you on the dark side of the Moon...
Boulder is offline   Reply With Quote
Old 16th November 2003, 05:41   #19  |  Link
Prettz
easily bamboozled user
 
Prettz's Avatar
 
Join Date: Sep 2002
Location: Atlanta
Posts: 373
wow thanks for the FluxSmooth fix Shodan, that's my favorite denoiser too
Prettz is offline   Reply With Quote
Old 16th November 2003, 10:50   #20  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
I seem to recall something about the source not corresponding to the binary - so that's probably the issue. YV12 mode works on my setup though.
__________________
Regards, sh0dan // VoxPod
sh0dan 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 19:15.


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