[PV3D] Custom Flat Shader


Flat Shader

This is Papervision3D 2.1 demo. I try to run faster flat shading.

Main logic is these steps.

[1] make Array of BitmapData as chache

[2] check z-axis of all faces

[3] calculate radian between z-axis of face and z-axis of target direction

[4] replace bitmap from cache data depend on radian.

Compare Flat Shading

Case of Build-in FlatShader

091118-flatshader

Case of Custom Flat Shading

091118-my_flatshader

detail description is posted at Japanese blog.