Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
hdf2vtk.C
Go to the documentation of this file.
1 /* *******************************************************************
2  * Rocstar Simulation Suite *
3  * Copyright@2015, Illinois Rocstar LLC. All rights reserved. *
4  * *
5  * Illinois Rocstar LLC *
6  * Champaign, IL *
7  * www.illinoisrocstar.com *
8  * sales@illinoisrocstar.com *
9  * *
10  * License: See LICENSE file in top level of distribution package or *
11  * http://opensource.org/licenses/NCSA *
12  *********************************************************************/
13 /* *******************************************************************
14  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, *
15  * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES *
16  * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND *
17  * NONINFRINGEMENT. IN NO EVENT SHALL THE CONTRIBUTORS OR *
18  * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER *
19  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, *
20  * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE *
21  * USE OR OTHER DEALINGS WITH THE SOFTWARE. *
22  *********************************************************************/
31 #include <fstream>
32 #include <iomanip>
33 #include <iostream>
34 #include <sstream>
35 #include <string>
36 #include <cstring>
37 #include <cstdlib>
38 #include "Rocin.h"
39 #include "roccom.h"
40 
41 // Linear cells
42 #define VTK_EMPTY_CELL 0
43 #define VTK_VERTEX 1
44 #define VTK_POLY_VERTEX 2
45 #define VTK_LINE 3
46 #define VTK_POLY_LINE 4
47 #define VTK_TRIANGLE 5
48 #define VTK_TRIANGLE_STRIP 6
49 #define VTK_POLYGON 7
50 #define VTK_PIXEL 8
51 #define VTK_QUAD 9
52 #define VTK_TETRA 10
53 #define VTK_VOXEL 11
54 #define VTK_HEXAHEDRON 12
55 #define VTK_WEDGE 13
56 #define VTK_PYRAMID 14
57 #define VTK_PENTAGONAL_PRISM 15
58 #define VTK_HEXAGONAL_PRISM 16
59 
60 // Quadratic, isoparametric cells
61 #define VTK_QUADRATIC_EDGE 21
62 #define VTK_QUADRATIC_TRIANGLE 22
63 #define VTK_QUADRATIC_QUAD 23
64 #define VTK_QUADRATIC_TETRA 24
65 #define VTK_QUADRATIC_HEXAHEDRON 25
66 #define VTK_QUADRATIC_WEDGE 26
67 #define VTK_QUADRATIC_PYRAMID 27
68 
69 // Special class of cells formed by convex group of points
70 #define VTK_CONVEX_POINT_SET 41
71 
72 // Higher order cells in parametric form
73 #define VTK_PARAMETRIC_CURVE 51
74 #define VTK_PARAMETRIC_SURFACE 52
75 #define VTK_PARAMETRIC_TRI_SURFACE 53
76 #define VTK_PARAMETRIC_QUAD_SURFACE 54
77 #define VTK_PARAMETRIC_TETRA_REGION 55
78 #define VTK_PARAMETRIC_HEX_REGION 56
79 
80 
81 #define SwitchOnDataType(dType, funcCall) \
82  switch (dType) { \
83  case COM_CHAR: \
84  case COM_BYTE: \
85  { typedef char TT; \
86  funcCall; } \
87  break; \
88  case COM_UNSIGNED_CHAR: \
89  { typedef unsigned char TT; \
90  funcCall; } \
91  break; \
92  case COM_SHORT: \
93  { typedef short TT; \
94  funcCall; } \
95  break; \
96  case COM_UNSIGNED_SHORT: \
97  { typedef unsigned short TT; \
98  funcCall; } \
99  break; \
100  case COM_INT: \
101  { typedef int TT; \
102  funcCall; } \
103  break; \
104  case COM_UNSIGNED: \
105  { typedef unsigned int TT; \
106  funcCall; } \
107  break; \
108  case COM_LONG: \
109  { typedef long TT; \
110  funcCall; } \
111  break; \
112  case COM_UNSIGNED_LONG: \
113  { typedef unsigned long TT; \
114  funcCall; } \
115  break; \
116  case COM_FLOAT: \
117  { typedef float TT; \
118  funcCall; } \
119  break; \
120  case COM_DOUBLE: \
121  { typedef double TT; \
122  funcCall; } \
123  break; \
124  case COM_LONG_DOUBLE: \
125  { typedef long double TT; \
126  funcCall; } \
127  break; \
128  }
129 
130 struct AttrInfo {
131  std::string m_name;
132  char m_location;
133  int m_dataType;
134  int m_numComp;
135  std::string m_units;
136 };
137 
138 struct ConnInfo {
139  std::string m_name;
140  std::string m_type;
141  int m_numElements;
142  int m_numGhost;
143 };
144 
145 template <typename TT>
146 void PrintStructured(const TT** pData, int nComp, int ndims,
147  const int* dims_nodes, int ghost, char loc,
148  std::ostream& out)
149 {
150  const int dims[3] = { dims_nodes[0] - (loc == 'e'),
151  ndims >= 2 ? dims_nodes[1] - (loc == 'e') : 0,
152  ndims >= 3 ? dims_nodes[2] - (loc == 'e') : 0 };
153 
154  const int last[3] = { dims[0] - ghost,
155  ndims >= 2 ? dims[1] - ghost : 0,
156  ndims >= 3 ? dims[2] - ghost : 0 };
157 
158  int c, i, j, k;
159  switch (ndims) {
160  case 1:
161  for (i=ghost; i<last[0]; ++i) {
162  for (c=0; c<nComp; ++c)
163  out << (pData[c] ? pData[c][i] : (TT)-987654321) << ' ';
164  out << std::endl;
165  }
166  break;
167 
168  case 2:
169  for (j=ghost; j<last[1]; ++j)
170  for (i=ghost; i<last[0]; ++i) {
171  for (c=0; c<nComp; ++c)
172  out << (pData[c] ? pData[c][i+j*dims[0]] : (TT)-987654321) << ' ';
173  out << std::endl;
174  }
175  break;
176 
177  case 3:
178  for (k=ghost; k<last[2]; ++k)
179  for (j=ghost; j<last[1]; ++j)
180  for (i=ghost; i<last[0]; ++i) {
181  for (c=0; c<nComp; ++c)
182  out << (pData[c] ? pData[c][i+j*dims[0]+k*dims[0]*dims[1]]
183  : (TT)-987654321) << ' ';
184  out << std::endl;
185  }
186  break;
187  }
188 }
189 
190 template <typename TT>
191 void PrintUnstructured(const TT** pData, int nComp, int size, std::ostream& out)
192 {
193  int c, i;
194  for (i=0; i<size; ++i) {
195  for (c=0; c<nComp; ++c)
196  out << (pData[c] ? pData[c][i] : (TT)-987654321) << ' ';
197  out << std::endl;
198  }
199 }
200 
201 void PrintConn(const int* pConn, const ConnInfo& ci, std::ostream& out)
202 {
203  int nn;
204  if (ci.m_type == "q9")
205  nn = 8;
206  else {
207  std::istringstream sin(ci.m_type.substr(1));
208  sin >> nn;
209  }
210 
211  int ne = ci.m_numElements - ci.m_numGhost;
212 
213  int elem, i;
214  for (elem=0; elem<ne; ++elem) {
215  out << nn;
216  for (i=0; i<nn; ++i)
217  out << ' ' << (pConn[elem+i*ci.m_numElements] - 1);
218  out << std::endl;
219  }
220 }
221 
222 void COM_print_window(const std::string& wName, const std::string& timeStr,
223  const std::string& file_in, bool mesh_only)
224 {
225  static std::map<int, std::string> DataTypeAsString;
226  static std::map<std::string, int> COM2VTK;
227  if (DataTypeAsString.empty()) {
228  DataTypeAsString[COM_CHAR] = "char";
229  DataTypeAsString[COM_BYTE] = "char";
230  DataTypeAsString[COM_UNSIGNED_CHAR] = "unsigned_char";
231  DataTypeAsString[COM_SHORT] = "short";
232  DataTypeAsString[COM_UNSIGNED_SHORT] = "unsigned_short";
233  DataTypeAsString[COM_INT] = "int";
234  DataTypeAsString[COM_UNSIGNED] = "unsigned_int";
235  DataTypeAsString[COM_LONG] = "long";
236  DataTypeAsString[COM_UNSIGNED_LONG] = "unsigned_long";
237  DataTypeAsString[COM_FLOAT] = "float";
238  DataTypeAsString[COM_DOUBLE] = "double";
239  DataTypeAsString[COM_LONG_DOUBLE] = "double"; // Not really, but...
240  }
241 
242  if (COM2VTK.empty()) {
243  COM2VTK["t3"] = VTK_TRIANGLE;
244  COM2VTK["t6"] = VTK_QUADRATIC_TRIANGLE;
245  COM2VTK["q4"] = VTK_QUAD;
246  COM2VTK["q8"] = VTK_QUADRATIC_QUAD;
247  COM2VTK["q9"] = VTK_QUADRATIC_QUAD;
248  COM2VTK["T4"] = VTK_TETRA;
249  COM2VTK["T10"] = VTK_QUADRATIC_TETRA;
250  COM2VTK["B8"] = VTK_HEXAHEDRON;
251  COM2VTK["H8"] = VTK_HEXAHEDRON;
252  COM2VTK["B20"] = VTK_QUADRATIC_HEXAHEDRON;
253  COM2VTK["P5"] = VTK_PYRAMID;
254  COM2VTK["W6"] = VTK_WEDGE;
255  COM2VTK["P6"] = VTK_WEDGE;
256  }
257 
258  // Obtain the list of panes
259  int nPanes;
260  int* paneIds;
261  COM_get_panes(wName.c_str(), &nPanes, &paneIds);
262 
263  // Obtain the list of attributes
264  int nAttrs; // Number of attributes
265  char* attrStr; // names of attributes separated by spaces
266  COM_get_attributes(wName.c_str(), &nAttrs, &attrStr);
267 
268  // First get the nodal coordinate info.
269  int i;
270  std::string name;
271  std::vector<AttrInfo> attrs(nAttrs+1);
272  attrs[0].m_name = "nc";
273  COM_get_attribute((wName + '.' + attrs[0].m_name).c_str(),
274  &(attrs[0].m_location), &(attrs[0].m_dataType),
275  &(attrs[0].m_numComp), &(attrs[0].m_units));
276 
277  // Then get the basic attribute info.
278  {
279  std::istringstream sin(attrStr);
280  for (i=1; i<nAttrs+1; ++i) {
281  sin >> attrs[i].m_name;
282  COM_get_attribute((wName + '.' + attrs[i].m_name).c_str(),
283  &(attrs[i].m_location), &(attrs[i].m_dataType),
284  &(attrs[i].m_numComp), &(attrs[i].m_units));
285  }
286  }
287 
288  // Eliminate window and pane attributes. Count node and element attributes.
289  std::set<char> locset;
290  std::vector<AttrInfo>::iterator p = attrs.begin();
291  ++p;
292  while (p != attrs.end()) {
293  char loc = (*p).m_location;
294  if (loc == 'w' || loc == 'p') {
295  p = attrs.erase(p);
296  continue;
297  }
298  locset.insert(loc);
299  ++p;
300  }
301 
302  // Loop through the panes to find the meshes
303  for (i=0; i<nPanes; ++i) {
304  std::ofstream out;
305  if (nPanes == 1) {
306  std::string file_out(file_in.substr(0, file_in.rfind('.')) + ".vtk");
307  out.open(file_out.c_str());
308  } else {
309  std::ostringstream sout;
310  sout << wName << '_' << timeStr << "_"
311  << std::setw(4) << std::setfill('0') << i << ".vtk";
312  out.open(sout.str().c_str());
313  }
314 
315  out << "# vtk DataFile Version 2.0" << std::endl;
316  out << "Material=" << wName << ", Block=" << i << ", Time: " << timeStr
317  << "." << std::endl;
318  out << "ASCII" << std::endl;
319 
320  // Obtain the size of nodes
321  int nNodes; // total number of nodes
322  int ghost; // Number of ghost nodes
323  name = wName + ".nc";
324  COM_get_size(name.c_str(), paneIds[i], &nNodes, &ghost);
325  nNodes -= ghost;
326 
327  // Obtain the connectivity tables
328  int nConn; // Number of connectivity tables
329  char* connNames; // Names of connectivity tables separated by space
330  COM_get_connectivities(wName.c_str(), paneIds[i], &nConn, &connNames);
331 
332  const int* dims = NULL;
333  int ndims, eTotal = 0, eSize = 0;
334  std::vector<ConnInfo> connInfo(nConn);
335  std::vector<std::pair<int, int> > cellTypes;
336  if (nConn == 1 && strncmp(connNames, ":st", 3) == 0) { // Structured mesh
337  name = wName + '.' + connNames;
338  COM_get_size(name.c_str(), paneIds[i], &ndims, &ghost);
339 
340  // Obtain the dimensions (must be a const array) of the pane
341  COM_get_array_const(name.c_str(), paneIds[i], &dims);
342 
343  out << "DATASET STRUCTURED_GRID" << std::endl;
344  out << "DIMENSIONS " << dims[0] - 2 * ghost << " " << dims[1] - 2 * ghost
345  << " " << dims[2] - 2 * ghost << std::endl;
346 
347  eTotal = (dims[0] - 2 * ghost > 1 ? dims[0] - 2 * ghost - 1 : 1)
348  * (dims[1] - 2 * ghost > 1 ? dims[1] - 2 * ghost - 1 : 1)
349  * (dims[2] - 2 * ghost > 1 ? dims[2] - 2 * ghost - 1 : 1);
350  } else { // Unstructured mesh
351  out << "DATASET UNSTRUCTURED_GRID" << std::endl;
352  // Obtain the sizes of connectivity tables
353  std::istringstream sin(connNames);
354  std::vector<ConnInfo>::iterator c;
355  for (c=connInfo.begin(); c!=connInfo.end(); ++c) {
356  sin >> (*c).m_type;
357  (*c).m_name = wName + '.' + (*c).m_type;
358  (*c).m_type.erase(0, 1);
359  std::string::size_type x = (*c).m_type.find(':', 2);
360  if (x != std::string::npos)
361  (*c).m_type.erase(x);
362 
363  COM_get_size((*c).m_name.c_str(), paneIds[i], &((*c).m_numElements),
364  &((*c).m_numGhost));
365  eTotal += (*c).m_numElements - (*c).m_numGhost;
366 
367  int nn;
368  if ((*c).m_type == "q9")
369  nn = 8;
370  else {
371  std::istringstream sin((*c).m_type.substr(1));
372  sin >> nn;
373  }
374  eSize += ((*c).m_numElements - (*c).m_numGhost) * (nn + 1);
375 
376  cellTypes.push_back(std::pair<int, int>(COM2VTK[(*c).m_type],
377  (*c).m_numElements - (*c).m_numGhost));
378  }
379  }
380 
381  out << "POINTS " << nNodes << ' ' << DataTypeAsString[attrs[0].m_dataType]
382  << std::endl;
383  const void* pArray[9] = { NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL,
384  NULL };
385  p = attrs.begin();
386  int comp;
387  for (comp=1; comp<=(*p).m_numComp; ++comp) {
388  std::ostringstream sout;
389  sout << wName << '.' << comp << '-' << (*p).m_name;
390  COM_get_array_const(sout.str().c_str(), paneIds[i], &(pArray[comp-1]));
391  }
392 
393  if (dims != NULL) { // Structured
394  SwitchOnDataType((*p).m_dataType,
395  PrintStructured((const TT**)pArray, (*p).m_numComp,
396  ndims, dims, ghost, (*p).m_location,
397  out));
398  } else {
399  SwitchOnDataType((*p).m_dataType,
400  PrintUnstructured((const TT**)pArray, (*p).m_numComp,
401  nNodes, out));
402  }
403 
404  if (nConn != 1 || strncmp(connNames, ":st", 3) != 0) { // Unstructured mesh
405  out << "CELLS " << eTotal << ' ' << eSize << std::endl;
406 
407  std::vector<ConnInfo>::iterator c;
408  for (c=connInfo.begin(); c!=connInfo.end(); ++c) {
409  const int* pConn = NULL;
410  COM_get_array_const((*c).m_name.c_str(), paneIds[i], &pConn);
411  PrintConn(pConn, *c, out);
412  }
413 
414  out << "CELL_TYPES " << eTotal << std::endl;
415 
416  int i;
417  std::vector<std::pair<int, int> >::iterator t = cellTypes.begin();
418  while (t != cellTypes.end()) {
419  for (i=0; i<(*t).second; ++i)
420  out << (*t).first << std::endl;
421  ++t;
422  }
423  }
424 
425  // free the buffer of connNames
426  COM_free_buffer(&connNames);
427 
428  if (!mesh_only && locset.count('n') > 0) {
429  out << "POINT_DATA " << nNodes << std::endl;
430  for (p=attrs.begin(); p!=attrs.end(); ++p) {
431  if ((*p).m_location != 'n')
432  continue;
433 
434  if ((*p).m_numComp == 1) {
435  COM_get_array_const((wName + '.' + (*p).m_name).c_str(), paneIds[i],
436  &(pArray[0]));
437  out << "SCALARS ";
438  } else {
439  int comp;
440  for (comp=1; comp<=(*p).m_numComp; ++comp) {
441  std::ostringstream sout;
442  sout << wName << '.' << comp << '-' << (*p).m_name;
443  COM_get_array_const(sout.str().c_str(), paneIds[i],
444  &(pArray[comp-1]));
445  }
446  if ((*p).m_numComp == 3)
447  out << "VECTORS ";
448  else
449  out << "TENSORS ";
450  }
451 
452  out << (*p).m_name << ' ' << DataTypeAsString[(*p).m_dataType]
453  << std::endl;
454 
455  if ((*p).m_numComp == 1)
456  out << "LOOKUP_TABLE default" << std::endl;
457 
458  if (dims != NULL) { // Structured
459  SwitchOnDataType((*p).m_dataType,
460  PrintStructured((const TT**)pArray, (*p).m_numComp,
461  ndims, dims, ghost, (*p).m_location,
462  out));
463  } else {
464  SwitchOnDataType((*p).m_dataType,
465  PrintUnstructured((const TT**)pArray, (*p).m_numComp,
466  nNodes, out));
467  }
468  }
469  }
470 
471  if (!mesh_only && locset.count('e') > 0) {
472  out << std::endl << "CELL_DATA " << eTotal << std::endl;
473  for (p=attrs.begin(); p!=attrs.end(); ++p) {
474  if ((*p).m_location != 'e')
475  continue;
476 
477  if ((*p).m_numComp == 1) {
478  COM_get_array_const((wName + '.' + (*p).m_name).c_str(), paneIds[i],
479  &(pArray[0]));
480  out << "SCALARS ";
481  } else {
482  int comp;
483  for (comp=1; comp<=(*p).m_numComp; ++comp) {
484  std::ostringstream sout;
485  sout << wName << '.' << comp << '-' << (*p).m_name;
486  COM_get_array_const(sout.str().c_str(), paneIds[i],
487  &(pArray[comp-1]));
488  }
489  if ((*p).m_numComp == 3)
490  out << "VECTORS ";
491  else
492  out << "TENSORS ";
493  }
494 
495  out << (*p).m_name << ' ' << DataTypeAsString[(*p).m_dataType]
496  << std::endl;
497 
498  if ((*p).m_numComp == 1)
499  out << "LOOKUP_TABLE default" << std::endl;
500 
501  if (dims != NULL) { // Structured
502  SwitchOnDataType((*p).m_dataType,
503  PrintStructured((const TT**)pArray, (*p).m_numComp,
504  ndims, dims, ghost, (*p).m_location,
505  out));
506  } else {
507  SwitchOnDataType((*p).m_dataType,
508  PrintUnstructured((const TT**)pArray, (*p).m_numComp,
509  eTotal, out));
510  }
511  }
512  }
513  }
514 
515  // Free buffers for pane ids and attribute names
516  COM_free_buffer(&paneIds);
517  COM_free_buffer(&attrStr);
518 }
519 
521 
522 int main(int argc, char* argv[])
523 {
524  COM_init(&argc, &argv);
525 
526  bool mesh_only = false, read_control = false;
527  int i;
528  for (i=1; i<argc-1; ++i) {
529  if (std::strcmp(argv[1], "-c") == 0)
530  read_control = true;
531  else if (std::strcmp(argv[1], "-meshonly") == 0)
532  mesh_only = true;
533  else {
534  std::cerr << "Usage: hdf2vtk [-meshonly] <hdf file>" << std::endl;
535  std::cerr << " hdf2vtk [-meshonly] -c <control file>" << std::endl;
536  return 1;
537  }
538  }
539 
541 
542  int IN_obtain = COM_get_function_handle("IN.obtain_attribute");
543 
544  COM_set_verbose(0);
546 
547  std::string file_in(argv[argc-1]);
548  std::string win_in(file_in);
549  std::string::size_type st = win_in.find_last_of('/');
550  if (st != std::string::npos)
551  win_in.erase(0, st+1);
552  st = win_in.find_first_not_of("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ");
553  if (st != std::string::npos)
554  win_in.erase(st);
555 
556  int len = 15;
557  char timeStr[16] = "";
558 
559  if (read_control) {
560  std::cerr << "Reading by control file " << file_in
561  << " into window " << win_in << std::endl;
562 
563  int IN_read = COM_get_function_handle("IN.read_by_control_file");
564  COM_call_function(IN_read, file_in.c_str(), win_in.c_str(), NULL,
565  timeStr, &len);
566  } else {
567  std::cerr << "Reading HDF file(s) " << file_in
568  << " into window " << win_in << std::endl;
569 
570  int IN_read = COM_get_function_handle("IN.read_window");
571  COM_call_function(IN_read, file_in.c_str(), win_in.c_str(), NULL, NULL,
572  timeStr, &len);
573  }
574 
575  int IN_all = COM_get_attribute_handle((win_in + ".all").c_str());
576  COM_call_function(IN_obtain, &IN_all, &IN_all);
577 
578  COM_print_window(win_in, timeStr, file_in, mesh_only);
579 
580 #ifdef DUMMY_MPI
582 #endif // DUMMY_MPI
583 
584  COM_finalize();
585  return 0;
586 }
587 
588 
589 
590 
591 
592 
#define VTK_QUADRATIC_TETRA
Definition: hdf2vtk.C:64
void PrintConn(const int *pConn, const ConnInfo &ci, std::ostream &out)
Definition: cgns2smf.C:232
#define VTK_QUAD
Definition: hdf2vtk.C:51
j indices k indices k
Definition: Indexing.h:6
void COM_get_attribute(const std::string wa_str, char *loc, int *type, int *ncomp, std::string *unit)
Definition: roccom_c++.h:269
#define VTK_QUADRATIC_TRIANGLE
Definition: hdf2vtk.C:62
#define VTK_PYRAMID
Definition: hdf2vtk.C:56
int m_numGhost
Definition: cgns2smf.C:140
void PrintUnstructured(const TT **pData, int nComp, int size, std::ostream &out)
Definition: cgns2smf.C:221
int m_dataType
Definition: cgns2smf.C:131
This file contains the prototypes for Roccom API.
void COM_print_window(const char *wName, std::ostream &ostr)
Print a terse human-readable description of this window to this ostream.
Definition: printin.C:64
void PrintStructured(const TT **pData, int nComp, int ndims, const int *dims_nodes, int ghost, char loc, std::ostream &out)
Definition: cgns2smf.C:176
C/C++ Data types.
Definition: roccom_basic.h:129
std::string m_name
Definition: cgns2smf.C:137
void COM_set_verbose(int i)
Definition: roccom_c++.h:543
#define VTK_TRIANGLE
Definition: hdf2vtk.C:47
int COM_get_attribute_handle(const char *waname)
Definition: roccom_c++.h:412
void COM_get_connectivities(const char *wname, int pane_id, int *nc, std::string &names)
Definition: roccom_c++.h:363
std::string m_units
Definition: cgns2smf.C:133
#define COM_UNLOAD_MODULE_STATIC_DYNAMIC(moduleName, windowString)
Definition: roccom_basic.h:113
void COM_get_attributes(const char *wname, int *na, std::string &names)
Definition: roccom_c++.h:360
void COM_finalize()
Definition: roccom_c++.h:59
std::string m_type
Definition: cgns2smf.C:138
NT & sin
Definition: Rocin.h:64
#define VTK_TETRA
Definition: hdf2vtk.C:52
blockLoc i
Definition: read.cpp:79
void int int REAL * x
Definition: read.cpp:74
std::string m_name
Definition: cgns2smf.C:129
void COM_get_size(const char *wa_str, int pane_id, int *size, int *ng=0)
Get the sizes of an attribute.
Definition: roccom_c++.h:274
#define VTK_WEDGE
Definition: hdf2vtk.C:55
void COM_set_profiling(int i)
Definition: roccom_c++.h:550
void COM_call_function(const int wf, int argc,...)
Definition: roccom_c.C:48
Rocin creates a series of Roccom windows by reading in a list of files.
#define SwitchOnDataType(dType, funcCall)
Definition: hdf2vtk.C:81
int main(int argc, char *argv[])
Definition: blastest.C:94
int m_numComp
Definition: cgns2smf.C:132
j indices j
Definition: Indexing.h:6
char m_location
Definition: cgns2smf.C:130
void COM_init(int *argc, char ***argv)
Definition: roccom_c++.h:57
int m_numElements
Definition: cgns2smf.C:139
void COM_get_panes(const char *wname, std::vector< int > &pane_ids, int rank=-2)
Definition: roccom_c++.h:350
void COM_free_buffer(int **buf)
Definition: roccom_c++.h:397
#define VTK_HEXAHEDRON
Definition: hdf2vtk.C:54
#define COM_LOAD_MODULE_STATIC_DYNAMIC(moduleName, windowString)
Definition: roccom_basic.h:111
int COM_get_function_handle(const char *wfname)
Definition: roccom_c++.h:428
#define VTK_QUADRATIC_HEXAHEDRON
Definition: hdf2vtk.C:65
#define VTK_QUADRATIC_QUAD
Definition: hdf2vtk.C:63
#define COM_EXTERN_MODULE(moduleName)
Definition: roccom_basic.h:116
std::vector< int > paneIds
Array of paneIds.
Definition: hdf2pltV2.C:60