Home › Forums › GAMES在线课程(现代计算机图形学入门)讨论区 › 作业7框架空指针问题 This topic has 1 reply, 1 voice, and was last updated 3 years, 3 months ago by KSkun. Viewing 1 reply thread Author Posts 2021年8月24日 at 上午12:51 #9181 Score: 0 KSkunParticipant 作业7框架中Triangle.hpp实现的MeshTriangle,其成员变量中的几个shared_ptr均未被恰当初始化,若调用Scene::trace,进而会调用MeshTriangle::intersect(const Ray& ray, float& tnear, uint32_t& index)这个函数,导致空指针解引用,发生段错误 Attachments:You must be logged in to view attached files. 2021年8月24日 at 上午12:54 #9183 Score: 0 KSkunParticipant 改用Scene::intersect似乎可以解决问题,弃用的函数最好标注一下吧 Author Posts Viewing 1 reply thread You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In