7 |
|
|
8 |
|
#include <time.h> |
9 |
|
|
10 |
– |
#include "standard.h" |
10 |
|
#include "platform.h" |
11 |
+ |
#include "standard.h" |
12 |
|
#include "octree.h" |
13 |
|
#include "object.h" |
14 |
|
#include "mesh.h" |
92 |
|
default: |
93 |
|
mesherror(USER, "damaged mesh octree"); |
94 |
|
} |
95 |
< |
return (OCTREE)NULL; /* pro forma return */ |
95 |
> |
return (OCTREE)0; /* pro forma return */ |
96 |
|
} |
97 |
|
|
98 |
|
|
145 |
|
} else |
146 |
|
pp->norm = NULL; |
147 |
|
if (flags & MT_UV) { |
148 |
< |
pp->uv = (uint16 (*)[2])calloc(pp->nverts, 2*sizeof(uint16)); |
148 |
> |
pp->uv = (uint32 (*)[2])calloc(pp->nverts, 2*sizeof(uint32)); |
149 |
|
if (pp->uv == NULL) |
150 |
|
goto nomem; |
151 |
|
} else |
162 |
|
if (flags & MT_UV) |
163 |
|
for (i = 0; i < pp->nverts; i++) |
164 |
|
for (j = 0; j < 2; j++) |
165 |
< |
pp->uv[i][j] = mgetint(2); |
165 |
> |
pp->uv[i][j] = mgetint(4); |
166 |
|
/* local triangles */ |
167 |
|
pp->ntris = mgetint(2); |
168 |
|
if (pp->ntris < 0 || pp->ntris > 512) |