Skip to content

Develop #99

Merged
merged 42 commits into from Mar 14, 2014

3 participants

@Flamefire

Change some namings and handle more errors
Optimize video decoding (ffmpeg) and tone analysis (all)

@stsundermann

We can have a return value here instead of a out parameter, which we should prefer generally whenever possible.

Right. Still a WIP so further changes are still coming

@stsundermann

Why remove all the IDisposable interfaces? In C# the finalizer needs two GC cycles to collect the object and free the resources compared to one using the dispose pattern.

This is not completely true IMO. I've just read http://msdn.microsoft.com/en-us/library/ff647790.aspx again...
We keep the WiiMote for the entire runtime, so finalizer is only called on exit. Dispose provides use only, if you actually call Dispose somewhere.
But out of interest: I did not find any good resources how to use the dispose pattern. MSDN says:
protected virtual void Dispose(bool disposing){
if(disposing){
// Dispose time code
. . .
}
// Finalize time code
. . .
}
But WTH is the difference? Dispose should replace the finalizer, right? So it should free ALL resources, shouldn't it?

You can use the disposing pattern to add a log entry whenever the finalizer is called instead of the dispose method. Banshee does that.

@flokuep
Vocaluxe member

Please leave this in code; Sometimes we need it for some testing.

Have a look 3 lines down (not in the diff) it was there twice and this one was redundant

Vocaluxe member

Okay, didn't say anything.

@stsundermann stsundermann merged commit de6045c into Vocaluxe:develop Mar 14, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.