Home › Forums › GAMES在线课程(现代计算机图形学入门)讨论区 › 作业二如何保存图片 This topic has 1 reply, 1 voice, and was last updated 3 years ago by Cyan. Viewing 1 reply thread Author Posts 2021年10月18日 at 下午4:42 #9555 Score: 0 CyanParticipant 如题,我没在给的文章里看到方法,作业里的所有问题我都可以解决,然而不会保存图片。或者谁告诉我这个终端调试的东西叫什么我去搜也好。 2021年10月19日 at 下午9:07 #9563 Score: 0 CyanParticipant 好了我这里说下根据main.cpp中可看到,int main(int argc, const char** argv) if (argc == 2) { command_line = true; filename = std::string(argv[1]); } if (command_line) { …… cv::imwrite(filename, image); return 0; } 这两段是保存图片也就是说当argc == 2时,即可保存图片,最后终端输入./Rasterizer xxx.png即可满足argc == 2即可保存图片 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