276{
277
280
283
284 if(V.size() == 0 ||
F.size() == 0)
285 {
286 std::cerr << "Embree: No geometry specified!";
287 return;
288 }
289
290
292 if(isStatic)
295
296 for(int g=0;g<(int)V.size();g++)
297 {
298
300
301
303 for(
int i=0;i<(int)V[g]->
rows();i++)
304 {
308 }
310
311
313 for(
int i=0;i<(int)F[g]->
rows();i++)
314 {
318 }
320
322 }
323
325
327 std::cerr << "Embree: An error occurred while initializing the provided geometry!" << endl;
328#ifdef IGL_VERBOSE
329 else
330 std::cerr << "Embree: geometry added." << endl;
331#endif
332
334}
static void global_init()
Definition EmbreeIntersector.h:206
float z
Definition EmbreeIntersector.h:170
int v1
Definition EmbreeIntersector.h:171
float y
Definition EmbreeIntersector.h:170
int v2
Definition EmbreeIntersector.h:171
int v0
Definition EmbreeIntersector.h:171
float x
Definition EmbreeIntersector.h:170
@ F
Definition libslic3r.h:102
Kernel::Triangle_3 Triangle
Definition points_inside_component.cpp:33
size_t rows(const T &raster)
Definition MarchingSquares.hpp:55
@ RTC_GEOMETRY_STATIC
specifies static geometry that will change rarely
Definition rtcore_geometry.h:60
RTCORE_API void rtcUnmapBuffer(RTCScene scene, unsigned geomID, RTCBufferType type)
Unmaps specified buffer.
RTCORE_API void * rtcMapBuffer(RTCScene scene, unsigned geomID, RTCBufferType type)
Maps specified buffer. This function can be used to set index and vertex buffers of geometries.
RTCORE_API unsigned rtcNewTriangleMesh(RTCScene scene, RTCGeometryFlags flags, size_t numTriangles, size_t numVertices, size_t numTimeSteps=1)
Creates a new triangle mesh. The number of triangles (numTriangles), number of vertices (numVertices)...
@ RTC_INDEX_BUFFER
Definition rtcore_geometry.h:28
@ RTC_VERTEX_BUFFER
Definition rtcore_geometry.h:30
RTCORE_API void rtcSetMask(RTCScene scene, unsigned geomID, int mask)
Sets 32 bit ray mask.
RTCORE_API void rtcCommit(RTCScene scene)
@ RTC_INTERSECT1
enables the rtcIntersect1 and rtcOccluded1 functions for this scene
Definition rtcore_scene.h:50
RTCSceneFlags
Definition rtcore_scene.h:32
@ RTC_SCENE_ROBUST
use more robust traversal algorithms
Definition rtcore_scene.h:44
@ RTC_SCENE_HIGH_QUALITY
create higher quality data structures
Definition rtcore_scene.h:41
@ RTC_SCENE_STATIC
specifies static scene
Definition rtcore_scene.h:34
RTCORE_API RTCORE_DEPRECATED RTCScene rtcNewScene(RTCSceneFlags flags, RTCAlgorithmFlags aflags)