Category Archives: C++

Oh noes, there could be a null pointer!

It’s been some time since I wrote anything about C++ programming, so here’s something. Sorry for users of HourGlass and other softwares of mine if this isn’t of much interest. 😉 (I will probably start a separate blog specifically about … Continue reading

Posted in C++, Programming | Leave a comment

C++11 : The three dots, that is variadic templates, part …

Variadic templates in C++11 allow writing functions that take in multiple parameters that can be of varying types.(*) What could this be useful for? We sometimes have to be able to generate hash values out of objects, that is a … Continue reading

Posted in C++, Programming | 3 Comments

C++11, fun(ctional) times with lambdas

edit : Updated Event class code to use std::pair instead of a private struct This is a long blog post and quite technical in nature. Besides lambdas, many other C++11-only things will appear in the code examples. C++11 gained a … Continue reading

Posted in C++, Programming | Leave a comment

C++ : Movable but not copyable

C++11 allows an interesting new kind of classes to be created : ones that can be moved around but can’t be copied. This will be useful if one wants to have a “handle” object that manages a resource that is … Continue reading

Posted in C++ | Leave a comment

Surprising bits and time scales

If you measure time in units of samples at a 44100hz sample rate with a 32 bit value : 4294967296/44100= 97391,5 seconds= 1623,2 minutes= 27,1 hours That might get a bit tight when dealing with surveillance recordings or extreme pieces … Continue reading

Posted in C++, Programming | 2 Comments

HourGlass undo history flaw and a planned solution

Currently it works like this :                               So, each undo history step stores each envelope regardless of the envelope containing the same data or not…Hopefully I … Continue reading

Posted in C++, Programming, Uncategorized | Leave a comment

Forget pointers and embrace copying values

I recently watched an amazing talk by Sean Parent on C++ at : It’s rather technical (apart from the Photoshop demo around the 54 minute mark) and unfortunately with very bad audio quality. The rather ironic thing is that some … Continue reading

Posted in C++, Programming | 1 Comment