Hello,
We want to draw an outline / silhouette around selected objects in my scene (see the attachment for example). I've already implemented this effect using pure OpenGL on the iOS version of our app, and now I need to implement it on the Android version that is using jPCT.
How I do this on iOS, is draw the object 4 times:
1) Draw the object with 0 alpha, while disabling the update to the depth mask, and replacing the stencil buffer with ones where the object is painted.
2) Draw a scaled up version of the object with a constant color except where the stencil buffer is 1 (that is, where the actual regular object would be).
3) The same as above but with a scaled down version.
4) Draw the regular object normally.
The effect is quite simple and looks good enough for our use on iOS, but I have no idea how I could implement it using jPCT on Android. I have noticed that I could use IRenderHook to modify the stencil buffer, depth mask etc, so that part is easy. The issue is that I need to control the drawing order, so that I could draw using the above sequence, and I've seen now way to achieve that.
Any help would be greatly appreciated.
[attachment deleted by admin]