Project

General

Profile

« Previous | Next » 

Revision a2878a67

Added by Leszek Koltunski over 3 years ago

Remove the 'inflate' vertex attributs from the Mesh and file format, and replace that with a per-component 'inflate centers' (which are as of yet untested)

View differences:

src/main/java/org/distorted/library/mesh/MeshTriangles.java
42 42
     attribs1[VERT1_ATTRIBS*vertex + NOR_ATTRIB+1] = 0.0f;
43 43
     attribs1[VERT1_ATTRIBS*vertex + NOR_ATTRIB+2] = 1.0f;
44 44

  
45
     attribs1[VERT1_ATTRIBS*vertex + INF_ATTRIB  ] = (x-0.5f);
46
     attribs1[VERT1_ATTRIBS*vertex + INF_ATTRIB+1] = (y-0.33f);
47
     attribs1[VERT1_ATTRIBS*vertex + INF_ATTRIB+2] = 0.01f   ;  // Inflated surface needs to be slightly in front
48

  
49 45
     attribs2[VERT2_ATTRIBS*vertex + TEX_ATTRIB  ] = x;
50 46
     attribs2[VERT2_ATTRIBS*vertex + TEX_ATTRIB+1] = y;
51 47

  

Also available in: Unified diff