[Plib-users] ssgStripify generates bad normals?
Brought to you by:
sjbaker
From: Jeff L. <lo...@ke...> - 2001-09-18 03:21:57
|
I'm using plib 1.4.2. I'm loading an ASE file that contains the following vertices: *MESH_VERTEX_LIST { *MESH_VERTEX 0 11.0784 42.2896 3.2353 *MESH_VERTEX 1 21.0784 42.2896 3.2353 *MESH_VERTEX 2 11.0784 42.2896 13.2353 *MESH_VERTEX 3 21.0784 42.2896 13.2353 *MESH_VERTEX 4 11.0784 32.2896 3.2353 *MESH_VERTEX 5 21.0784 32.2896 3.2353 *MESH_VERTEX 6 11.0784 32.2896 13.2353 *MESH_VERTEX 7 21.0784 32.2896 13.2353 } The vertices make up a cube (which is the only thing in the ASE file). I can send the entire 3KB ASE file if anyone is interested. Anyway, after loading this into my program and calling ssgStripify on it I find that the normals for the vertices come out to be: V0) { 11.078, 42.290, 13.235 } N0) { -0.816, 0.408, 0.408 } V1) { 11.078, 32.290, 13.235 } N1) { -0.408, -0.408, 0.816 } V2) { 21.078, 42.290, 13.235 } N2) { 0.333, 0.667, 0.667 } V3) { 21.078, 32.290, 13.235 } N3) { 0.667, -0.667, 0.333 } V4) { 21.078, 42.290, 3.235 } N4) { 0.816, 0.408, -0.408 } V5) { 21.078, 32.290, 3.235 } N5) { 0.408, -0.408, -0.816 } V6) { 11.078, 42.290, 3.235 } N6) { -0.333, 0.667, -0.667 } V7) { 11.078, 32.290, 3.235 } N7) { -0.667, -0.667, -0.333 } By my calculations all the normals should be of the form: +/- 0.667, +/- 0.667, +/- 0.667 Can anyone explain what I'm calculating wrong or why the normals that PLIB calculates are more correct than the normals I've calculated? Perhaps the ASE file isn't generating the cube that I think it is? Thanks, Jeff Long |