Changeset 1384 for trunk/packages/vizservers
- Timestamp:
- Apr 6, 2009, 10:19:50 AM (15 years ago)
- Location:
- trunk/packages/vizservers/nanovis
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/vizservers/nanovis/Switch.h
r1365 r1384 35 35 #endif /* HAVE_STDDEF_H */ 36 36 37 #ifndef Offset38 37 #ifdef offsetof 39 #define Offset(type, field) ((int) offsetof(type, field))38 #define SwitchOffset(type, field) ((int) offsetof(type, field)) 40 39 #else 41 #define Offset(type, field) ((int) ((char *) &((type *) 0)->field))40 #define SwitchOffset(type, field) ((int) ((char *) &((type *) 0)->field)) 42 41 #endif 43 #endif /* Offset */44 42 45 43 namespace Rappture { -
trunk/packages/vizservers/nanovis/dxReader.cpp
r1382 r1384 92 92 } 93 93 if (sscanf(line, "object %*d class gridpositions counts %d %d %d", 94 &nx, &ny, &nz) == 4) {94 &nx, &ny, &nz) == 3) { 95 95 printf("w:%d h:%d d:%d\n", nx, ny, nz); 96 96 // found grid size … … 107 107 } 108 108 } else if (sscanf(line, "object %*d class array type %*s shape 3" 109 " rank 1 items %d data follows", &npts) == 3) {109 " rank 1 items %d data follows", &npts) == 1) { 110 110 printf("point %d\n", npts); 111 111 if (npts != nx*ny*nz) { … … 116 116 break; 117 117 } else if (sscanf(line, "object %*d class array type %*s rank 0" 118 " times %d data follows", &npts) == 3) {118 " times %d data follows", &npts) == 1) { 119 119 if (npts != nx*ny*nz) { 120 120 result.addError("inconsistent data: expected %d points"
Note: See TracChangeset
for help on using the changeset viewer.