| 2414 | | result = fread (ptr, 8, 1, plyfile->fp); |
| 2415 | | if(!result < 1) |
| 2416 | | { |
| 2417 | | throw ply::MeshException( "Error in reading PLY file." |
| 2418 | | "fread not succeeded." ); |
| 2419 | | } |
| 2420 | | if( plyfile->file_type == PLY_BINARY_BE ) |
| 2421 | | { |
| 2422 | | swap8BE(ptr); |
| 2423 | | } |
| 2424 | | else |
| 2425 | | { |
| 2426 | | swap8LE(ptr); |
| 2427 | | } |
| 2428 | | *double_val = *((double *) ptr); |
| 2429 | | *int_val = (int) *double_val; |
| 2430 | | *uint_val = (unsigned int) *double_val; |
| 2431 | | break; |
| | 2416 | result = fread (ptr, 8, 1, plyfile->fp); |
| | 2417 | if(result < 1) |
| | 2418 | { |
| | 2419 | throw ply::MeshException( "Error in reading PLY file." |
| | 2420 | "fread not succeeded." ); |
| | 2421 | } |
| | 2422 | if( plyfile->file_type == PLY_BINARY_BE ) |
| | 2423 | { |
| | 2424 | swap8BE(ptr); |
| | 2425 | } |
| | 2426 | else |
| | 2427 | { |
| | 2428 | swap8LE(ptr); |
| | 2429 | } |
| | 2430 | *double_val = *((double *) ptr); |
| | 2431 | *int_val = (int) *double_val; |
| | 2432 | *uint_val = (unsigned int) *double_val; |
| | 2433 | break; |