Jump to content
Compvision.ru
dl23

Линия всегда белым фоном

Recommended Posts

Доброго времени суток! При попытке нанести на изображение линию скажем красного цвета и толщиной в 5px, данная линия всегда с белым фоном

// Линия
cv::line(
  cvCreateImage, // Изображение цветное
  cv::Point2i(200, 120), // Первая точка
  cv::Point2i(240, 160), // Вторая точка
  cv::Scalar(0, 0, 255), // Цвет линии
  5 // Толщина линии
);

Проблема решена

Mat loadImg44;
cv::cvtColor(cvCreateImage, loadImg44, CV_RGBA2RGB);

 

Edited by dl23
Решение проблемы

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Recently Browsing   0 members

    No registered users viewing this page.

×