We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
depth保存的是浮点数,直接表示深度,用cv::imshow()函数会自动拉伸显示灰度信息,但cv::imwrite()函数只是保存值的结果,并不能拉伸显示,要做0~255的拉伸: main()函数里面修改 // 将深度图像归一化到 0-255 的范围 cv::Mat depth_normalized; depth.convertTo(depth_normalized, CV_8U, 255.0 *0.4); // 乘0.4和作者显示一样 cv::imwrite("depth.png", depth_normalized); // 保存深度图结果
The text was updated successfully, but these errors were encountered:
No branches or pull requests
depth保存的是浮点数,直接表示深度,用cv::imshow()函数会自动拉伸显示灰度信息,但cv::imwrite()函数只是保存值的结果,并不能拉伸显示,要做0~255的拉伸:
main()函数里面修改
// 将深度图像归一化到 0-255 的范围
cv::Mat depth_normalized;
depth.convertTo(depth_normalized, CV_8U, 255.0 *0.4); // 乘0.4和作者显示一样
cv::imwrite("depth.png", depth_normalized); // 保存深度图结果
The text was updated successfully, but these errors were encountered: