1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-07 12:30:27 +00:00

embree: Update to 4.3.1

This commit is contained in:
Jakub Mateusz Marcowski
2024-02-24 12:40:55 +01:00
committed by Jakub Marcowski
parent d2f9245ddc
commit c43eab55a4
219 changed files with 12630 additions and 6085 deletions

View File

@@ -45,12 +45,13 @@ namespace embree
Geometry::Geometry (Device* device, GType gtype, unsigned int numPrimitives, unsigned int numTimeSteps)
: device(device), userPtr(nullptr),
numPrimitives(numPrimitives), numTimeSteps(unsigned(numTimeSteps)), fnumTimeSegments(float(numTimeSteps-1)), time_range(0.0f,1.0f),
mask(-1),
mask(1),
gtype(gtype),
gsubtype(GTY_SUBTYPE_DEFAULT),
quality(RTC_BUILD_QUALITY_MEDIUM),
state((unsigned)State::MODIFIED),
enabled(true),
argumentFilterEnabled(false),
intersectionFilterN(nullptr), occlusionFilterN(nullptr), pointQueryFunc(nullptr)
{
device->refInc();
@@ -88,6 +89,11 @@ namespace embree
Geometry::update();
}
BBox1f Geometry::getTimeRange () const
{
return time_range;
}
void Geometry::update()
{
++modCounter_; // FIXME: required?
@@ -227,11 +233,11 @@ namespace embree
}
}
}
bool Geometry::pointQuery(PointQuery* query, PointQueryContext* context)
{
assert(context->primID < size());
RTCPointQueryFunctionArguments args;
args.query = (RTCPointQuery*)context->query_ws;
args.userPtr = context->userPtr;
@@ -239,7 +245,7 @@ namespace embree
args.geomID = context->geomID;
args.context = context->userContext;
args.similarityScale = context->similarityScale;
bool update = false;
if(context->func) update |= context->func(&args);
if(pointQueryFunc) update |= pointQueryFunc(&args);