Simulated Animation Effects Week#2

Last week my implementation lacked creating the current slide environment in the box2d world, meaning for the demo in the last blog post I had to hard code the environment.

So this week I wanted to get rid of this big flaw and start creating the environment from the slide on the fly. To achieve this goal, I needed current shapes in the slide. Therefore, to get shapes in the current slide I’ve implemented a new getter for ShapeManager and LayerManager classes. You can check out the patch at:

Shapes from the master slide, and shapes that are part of the background needed to be classified and ignored, so I’ve added a flag called mbIsForeground in the Shape classes and corresponding setters and getters for this flag.

mbIsForeground flag is set to false, if it should be, while shapes are being imported for the slide show. Patch for it can be found at:

To finish up I’ve added a new function to Box2DWorld class that will create static bodies in the box2d world from given Shapes. It is part of the still not merged box2d tools patch:

And while tinkering with these, I was hacking on PathAnimation class to test and figure out how they are behaving. You can check out that if you want to on my experimental private branch:

Following video demonstrates the current situation at the end of week 2 of development on the said private experimental branch: (please excuse my “demonstrative” mouse movements)

Please accept YouTube cookies to play this video. By accepting you will be accessing content from YouTube, a service provided by an external third party.

YouTube privacy policy

If you accept this notice, your choice will be saved and the page will refresh.