| 55 | } |
| 56 | |
| 57 | int NetCDFTypeToVTKType(nc_type type) |
| 58 | { |
| 59 | switch (type) |
| 60 | { |
| 61 | case NC_BYTE: |
| 62 | return VTK_SIGNED_CHAR; |
| 63 | case NC_UBYTE: |
| 64 | return VTK_UNSIGNED_CHAR; |
| 65 | case NC_CHAR: |
| 66 | return VTK_CHAR; |
| 67 | case NC_SHORT: |
| 68 | return VTK_SHORT; |
| 69 | case NC_USHORT: |
| 70 | return VTK_UNSIGNED_SHORT; |
| 71 | case NC_INT: |
| 72 | return VTK_INT; |
| 73 | case NC_UINT: |
| 74 | return VTK_UNSIGNED_INT; |
| 75 | case NC_INT64: |
| 76 | return VTK_LONG_LONG; |
| 77 | case NC_UINT64: |
| 78 | return VTK_UNSIGNED_LONG_LONG; |
| 79 | case NC_FLOAT: |
| 80 | return VTK_FLOAT; |
| 81 | case NC_DOUBLE: |
| 82 | return VTK_DOUBLE; |
| 83 | case NC_STRING: |
| 84 | return VTK_STRING; |
| 85 | default: |
| 86 | vtkGenericWarningMacro(<< "Unknown netCDF variable type " << type); |
| 87 | return -1; |
| 88 | } |
| 89 | } |
| 90 | |
| 91 | int VTKSizeof(int vtktype) |
| 92 | { |
no outgoing calls
no test coverage detected