Skip to content

Posts from the ‘c++’ Category

21
Mar

Edge-Preserving Decompositions for Multi-Scale Tone and Detail Manipulation

…or more simply, sharpen on steroids.
It was three weeks ago when my brother Alberto told me about a quite new paper entitled Edge-Preserving Decompositions for Multi-Scale Tone and Detail Manipulation [Lischinski et al. 2008]: in fact we had a talk or two about general photographic techniques some days before and, since i’m interested in the computational side of the subject, i asked him to let me know more about it whenever he got the chance, and so he did.
He was reading a Davide Barranca’s article explaining the basics of image sharpening and exposing various different methods in order to achieve it, so that one can manage to construct his own sharpening strategy, depending on his needs: the aforementioned paper is being referred by the article due to the fact that the new technique demonstrates how it is possible to make use of a better edge-preserving operator called WLS (or weighted least squares) that leads to better results with lot less artifacts and permitting detail manipulation at arbitrary scales: by looking at some sample images produced with it (and published on the Lischinski project page here) i instantly grasped what my brother’s excitement was about and decided i needed to know more about it: i was so eager to dive into it to the point i didn’t even noticed there was an example movie right there to see more of it!

Anyhow, considering computational photography was a brand-new field to me, i’m rather satisfied with the results: the sharpen is polished and the gain in both detail and depth level are impressive, while trying to intentionally cause artifacts is somewhat difficult, in the sense one have to boost detail frequencies to rather extreme values in order to cause artifacts and chromatic aberrations: in fact, considering the way actual tools currently work, i wonder why WLS-based strategies have still to take the lead in well-known commercial applications.

Unfortunately, as you may already know, i don’t have much free time to dedicate to most of the things i’m interested in, so this post is sort of an introduction while the rest will follows: it could take a while for me to write more about it, but i’ll try to share the time between coding and blogging, in the meantime i’m posting some results with it, but please, don’t laugh at the GUI too badly, its still all of an experimental thing and it’s just.. well.. usable ;-P
Note that the videos here don’t give justice to the real results due to the compression going on with both the Xvid codec and YouTube, so look at the HD version if you can.

The following video try to demonstrate some more detail exaggeration:

4
Sep

Compiz-like wobbling windows in AS3

This code was intended to be released back in October last year, but i never managed to do it since it needed some refactoring, some changes and had to be quite decent to present: then in November i got the chance to work with some very talented guys over at Jooce, in Paris, so i never got back to write something about it.
Btw, if you never tried Jooce then give it a try, it really deserves it!
Read moreRead more

31
Oct

Fixed point math in pure CPP

NOTE
This post has been previously published on 2007/Oct/31: due to my move to another server i’m now in the process to manually recover the comments for this article.
Fixed!

Some time ago i was asked to publish my implementation of fixed-point math, mainly regarding embedded architectures where IEEE floating point computations have really bad performances. What i want to give you here is a pure-c++, template-based implementation of a fixed-point datatype: this thing is more of a test in order to see how much an object-oriented implementation can perform, being in contrast to a more traditional implementation. As expected, operator overloading and temporary object creation overhead are the main issues with a full-oo implementation as this one, anyway, its a damn nice way to exercise yourself in writing c++ policy-based templated code ;)

Read moreRead more