Hello,
Thank you for your reply, I think this problem occurs before the amendments in mesh loader, I think I am missing some thing in here.
The main problem is with acceleration structure because whem I am using “NoAccel” everything is working fine just it is slow, but when I am using any other acceleration structure I cannot see my other object
details are below:
like I have one disk geometry :
Geometry disk2 = m_context->createGeometry();
// std::string sphere_ptx(ptxpath("tutorial", "sphere.cu"));
disk2->setPrimitiveCount(1u);
disk2->setBoundingBoxProgram(m_context->createProgramFromPTXFile(sphere_ptx, "bounds"));
disk2->setIntersectionProgram(m_context->createProgramFromPTXFile(sphere_ptx, "intersect2"));
disk2["sphere"]->setFloat(0.0, 5, 6.0);
disk2["normal"]->setFloat(0, 0, 1);
disk2["radius"]->setFloat(4.0);
a geometry group:
GeometryGroup geometrygroup = m_context->createGeometryGroup();
geometrygroup = m_context->createGeometryGroup();
geometrygroup->setChildCount( static_cast<unsigned int>(gis.size()) );
and one geometry model from.obj file:
InsertModel(prog_path, geometrygroup, box_matl, mesh_intersect, m0, true);
InsertModel("C:/ProgramData/NVIDIA Corporation/OptiX SDK 3.8.0/SDK/tutorial/knot.obj", geometrygroup, box_matl, mesh_intersect, m0, false);
pushing geometry in gis and setting child node
std::vector<GeometryInstance> gis;
gis.push_back(m_context->createGeometryInstance(disk2, &object_matl, &object_matl + 1));
geometrygroup->setChild(0, gis[0]);
setting acceleration:
geometrygroup->setAcceleration(m_context->createAcceleration("NoAccel", "NoAccel"));
when I am using this aceleration everything is fine, problem occurs when I change the acceleration
making top object:
m_context["top_object"]->set( geometrygroup );
m_context["top_shadower"]->set( geometrygroup );