Christmas book using ViewportLayer
This year I made for my closest friends and favorites co-workers an ecard using Papervision. It shows an old book with folded origamis that unfolds when changing pages. To avoid overlapping triangles, I have developped it using ViewportLayer.
Indeed, book is just a pile of planes (pages). First try using BasicRenderEngine and Z_SORT was an awful monster of overlapping tris.Using QuadrantRenderEngine, the tris problem was fixed but performances was very low.
As I already used BasicRenderEngine and INDEX_SORT I tried in this direction. In most cases, using INDEX_SORT could solve overlapping tris, but usually you really need to rethink how this strategy should works.Just switching Z_SORT to INDEX_SORT will not save you.
So I grabbed a book, analysing how it should works if pages was layers, turning pages, what append, again ... After a while, my code was write.Origamis models fold/unfold using Bones and Trigonometry.
I would add more pages and models, but christmas day was coming.Here is the result
0 comments about this entry