First, I create a ID3D11buffer m_pDisplayFromOptiXCopy sucessually.
then, I create a redundant optix::Buffer use this d3d buffer as follows:
optixbuffer = rtContext->createBufferFromD3D11Resource(RT_BUFFER_OUTPUT, m_pDisplayFromOptiXCopy);//RT_FORMAT_FLOAT4, WIDTH, HEIGHT);
optixbuffer ->setFormat(RT_FORMAT_FLOAT4);
optixbuffer ->setSize(m_Width,m_Height);
but, this optixbuffer is not used anywhere.
Last, when the code “rtContext->launch()” is executed, the above code will cause an uncertain exception, and when I comment out above code, the exception disappear.
I wonder to know how the redundant buffer from d3d11 affect the optix kernel?