Import Geant4 10.7.0 source tree

This commit is contained in:
Gabriele Cosmo
2020-12-04 12:30:43 +01:00
parent 67ba86d073
commit dab42d2018
3770 changed files with 226369 additions and 286486 deletions
@@ -47,7 +47,7 @@ protected: //gstos
//unsigned int npt = xyzs.values().size()/3;
//::printf("debug : atb_vertices : %lu : create_gsto : %u\n",this,npt);
std::vector<float> gsto_data;
std::vector<float> gsto_data;
if(rgbas.size()) {
if(nms.size()) {
@@ -67,8 +67,8 @@ protected: //gstos
size_t pos_edges = gsto_data.size();
append(gsto_data,xyzs.values());
append(gsto_data,xyzs.values());
float* pxyz = vec_data<float>(xyzs.values());
float* pedges = vec_data<float>(gsto_data)+pos_edges;
float* pxyz = vec_data<float>(xyzs.values());
float* pedges = vec_data<float>(gsto_data)+pos_edges;
size_t npt = xyzs.values().size()/3;
size_t ntri = npt/3;
for(size_t itri=0;itri<ntri;itri++) {
@@ -106,7 +106,7 @@ protected: //gstos
} else {
append(gsto_data,xyzs.values());
append(gsto_data,rgbas.values());
}
}
} else {
if(nms.size()) {
append(gsto_data,xyzs.values());
@@ -167,7 +167,7 @@ public:
}}
if(draw_edges.value()) {
pos_edges = pos_rgbas+npt*4*sizeof(float);
}
}
if(gl::is_line(mode.value())) {
//Same logic as Inventor SoLightModel.model = BASE_COLOR.
a_action.set_lighting(false);
@@ -193,7 +193,7 @@ public:
if(do_back.value()) a_action.draw_gsto_vcn(mode.value(),npt,pos_back_xyzs,pos_rgbas,pos_back_nms);
a_action.draw_gsto_vcn(mode.value(),npt,pos_xyzs,pos_rgbas,pos_nms);
}
} else {
size_t npt = xyzs.values().size()/3;
bufpos pos_xyzs = 0;
@@ -206,7 +206,7 @@ public:
} else {
a_action.draw_gsto_vc(mode.value(),npt,pos_xyzs,pos_rgbas);
}
}
}
#ifdef __APPLE__
if(restore_blend) a_action.set_blend(true);
#endif
@@ -238,7 +238,7 @@ public:
}
a_action.end_gsto();
return;
} else { //!_id
// use immediate rendering.
}
@@ -258,7 +258,7 @@ public:
if(gl::is_line(mode.value())) {
//Same logic as Inventor SoLightModel.model = BASE_COLOR.
a_action.set_lighting(false);
if(do_back.value())
if(do_back.value())
a_action.draw_vertex_color_normal_array(mode.value(),m_back_xyzs,rgbas.values(),m_back_nms);
a_action.draw_vertex_color_normal_array(mode.value(),xyzs.values(),rgbas.values(),nms.values());
a_action.set_lighting(state.m_GL_LIGHTING);
@@ -278,7 +278,7 @@ public:
if(do_back.value()) a_action.draw_vertex_color_normal_array(mode.value(),m_back_xyzs,rgbas.values(),m_back_nms);
a_action.draw_vertex_color_normal_array(mode.value(),xyzs.values(),rgbas.values(),nms.values());
}
} else {
if(gl::is_line(mode.value())) {
//Same logic as Inventor SoLightModel.model = BASE_COLOR.
@@ -288,11 +288,11 @@ public:
} else {
a_action.draw_vertex_color_array(mode.value(),xyzs.values(),rgbas.values());
}
}
}
#ifdef __APPLE__
if(restore_blend) a_action.set_blend(true);
#endif
#endif
} else { //rgbas.empty()
if(nms.size()) {
if(gl::is_line(mode.value())) {
@@ -313,7 +313,7 @@ public:
a_action.draw_vertex_array(mode.value(),xyzs.values());
}
}
}
}
@@ -328,7 +328,7 @@ public:
,m_nms_pos(0)
#ifdef __APPLE__
,m_all_a_one(true)
#endif
#endif
{
#ifdef TOOLS_MEM
mem::increment(s_class().c_str());
@@ -353,7 +353,7 @@ public:
,m_nms_pos(a_from.m_nms_pos)
#ifdef __APPLE__
,m_all_a_one(true)
#endif
#endif
{
#ifdef TOOLS_MEM
mem::increment(s_class().c_str());
@@ -532,7 +532,7 @@ public:
}
return true;
}
void clear() {
rgbas.clear();
nms.clear();
@@ -570,7 +570,7 @@ protected:
*(it2+1) = *it - *itn * epsil; it++;itn++; //y
*(it2+0) = *it - *itn * epsil; it++;itn++; //z
}}
m_back_nms[0] = _nms[0] * -1.0f;
m_back_nms[1] = _nms[1] * -1.0f;
m_back_nms[2] = _nms[2] * -1.0f;
@@ -583,7 +583,7 @@ protected:
*(it2+1) = *it * -1.0f; it++;
*(it2+0) = *it * -1.0f; it++;
}}
} else {
{std::vector<float>::const_iterator it = _xyzs.begin();
@@ -595,7 +595,7 @@ protected:
*(it2+1) = *it - *itn * epsil; it++;itn++; //y
*(it2+0) = *it - *itn * epsil; it++;itn++; //z
}}
{std::vector<float>::const_iterator it = _nms.begin();
std::vector<float>::const_iterator _end = _nms.end();
std::vector<float>::reverse_iterator it2 = m_back_nms.rbegin();
@@ -604,7 +604,7 @@ protected:
*(it2+1) = *it * -1.0f; it++;
*(it2+0) = *it * -1.0f; it++;
}}
}
}
@@ -618,8 +618,8 @@ protected:
m_edges.resize(2*_xyzs.size(),0);
float* pxyz = vec_data<float>(xyzs.values());
float* pedges = vec_data<float>(m_edges);
float* pxyz = vec_data<float>(xyzs.values());
float* pedges = vec_data<float>(m_edges);
size_t npt = xyzs.values().size()/3;
size_t ntri = npt/3;
@@ -690,7 +690,7 @@ protected:
size_t m_nms_pos;
#ifdef __APPLE__
bool m_all_a_one;
#endif
#endif
};
}}