PyNE C++
dagmc_bridge.h
1 #ifndef PYNE_SKQ36P4BFNE3VI6VHVADCDT4VQ
2 #define PYNE_SKQ36P4BFNE3VI6VHVADCDT4VQ
3 
4 /* Types.hpp may be validly included from C code */
5 #include <moab/Types.hpp>
6 
7 #ifdef __cplusplus
8 using moab::ErrorCode;
9 using moab::EntityHandle;
10 
11 namespace pyne {
12 
13 extern "C" {
14 #endif
15 /* Notice to future maintainers:
16  * If this file is ever used as a C header from a C compilation unit,
17  * there will probably need to be an #elseif here that defines EntityHandle
18  * or includes an appropriate MOAB header. I don't think Types.hpp guarantees
19  * that EntityHandle will be defined in C.
20  */
21 
22 typedef double vec3[3];
23 
24 float dag_version(void);
25 
26 unsigned dag_rev_version(void);
27 
28 int dag_ent_handle_size(void);
29 
30 const int* geom_id_list(int dimension, int* number_of_items);
31 
32 EntityHandle handle_from_id(int dimension, int id);
33 int id_from_handle(EntityHandle eh);
34 
35 ErrorCode dag_load(const char* filename);
36 
37 void* dag_alloc_ray_history(void);
38 
39 void dag_dealloc_ray_history(void* history);
40 
41 ErrorCode dag_ray_fire(EntityHandle vol, vec3 ray_start, vec3 ray_dir,
42  EntityHandle* next_surf, double* next_surf_dist,
43  void* history, double distance_limit);
44 
45 ErrorCode dag_ray_follow(EntityHandle firstvol, vec3 ray_start, vec3 ray_dir,
46  double distance_limit, int* num_intersections,
47  EntityHandle** surfs, double** distances,
48  EntityHandle** volumes, void* data_buffers);
49 
50 void dag_dealloc_ray_buffer(void* data_buffers);
51 
52 ErrorCode dag_pt_in_vol(EntityHandle vol, vec3 pt, int* result, vec3 dir,
53  const void* history);
54 
55 ErrorCode dag_next_vol(EntityHandle surface, EntityHandle volume,
56  EntityHandle* next_vol);
57 
58 int vol_is_graveyard(EntityHandle vol);
59 /* int surf_is_spec_refl(EntityHandle surf); */
60 /* int surf_is_white_refl(EntityHandle surf); */
61 int vol_is_implicit_complement(EntityHandle vol);
62 
63 ErrorCode get_volume_metadata(EntityHandle vol, int* material, double* density, double* importance);
64 
65 ErrorCode get_volume_boundary(EntityHandle vol, vec3 minPt, vec3 maxPt);
66 
67 #ifdef __cplusplus
68 } // namespace pyne
69 } // extern "C"
70 #endif
71 
72 #endif /* PYNE_SKQ36P4BFNE3VI6VHVADCDT4VQ */
A container representing enrichment cascades.
Definition: _atomic_data.h:7