diff --git a/wrap/io_trimesh/export_vmi.h b/wrap/io_trimesh/export_vmi.h index aa6641a7..02e63651 100644 --- a/wrap/io_trimesh/export_vmi.h +++ b/wrap/io_trimesh/export_vmi.h @@ -271,15 +271,15 @@ namespace io { /* end header */ if(vertSize!=0){ - size_t offsetV = (size_t) &m.vert[0]; + void * offsetV = (void*) &m.vert[0]; /* write the address of the first vertex */ - fwrite(&offsetV,sizeof(size_t),1,F()); + fwrite(&offsetV,sizeof(void *),1,F()); } if(faceSize!=0){ - size_t offsetF= ( size_t) &m.face[0]; + void * offsetF= (void*)&m.face[0]; /* write the address of the first face */ - fwrite(&offsetF,sizeof( size_t),1,F()); + fwrite(&offsetF,sizeof( void *),1,F()); } /* save the object mesh */ fwrite(&m.shot,sizeof(Shot),1,F()); diff --git a/wrap/io_trimesh/import_vmi.h b/wrap/io_trimesh/import_vmi.h index a1618def..efdd4366 100644 --- a/wrap/io_trimesh/import_vmi.h +++ b/wrap/io_trimesh/import_vmi.h @@ -652,15 +652,15 @@ namespace io { if(fnameV != nameV) return VMI_INCOMPATIBLE_VERTEX_TYPE; if(fnameF != nameF) return VMI_INCOMPATIBLE_FACE_TYPE; - int offsetV=0,offsetF=0; + void * offsetV = 0,*offsetF = 0; if(vertSize!=0) /* read the address of the first vertex */ - fread(&offsetV,sizeof( int),1,F()); + fread(&offsetV,sizeof( void *),1,F()); if(faceSize!=0) /* read the address of the first face */ - fread(&offsetF,sizeof( int),1,F()); + fread(&offsetF,sizeof( void *),1,F()); /* read the object mesh */ fread(&m.shot,sizeof(Shot),1,F());