Receiving Image through serial port in QT
Hi everyone,
I created an image processing GUI in Qt with openCV, where I opened an image from specific path and processed it. Now I am planning to implement like getting an image from serial port and send that image for further processing. I don't have any idea in doing this,. Any help will be appreciated!
void finalv1::openimage()
{
QString filename=QFileDialog::getOpenFileName(this,tr("Loa d Image"),".",tr("Image Files(*.png *.jpg *.jpeg *.bmp)"));
imageop = cvLoadImage(filename.toAscii().data());
cvNamedWindow("image",1);
cvShowImage("image",imageop);
}
void finalv1::on_pushButton_open_clicked()
{
openimage();
}
I provided my code for opening an image and the image is an 'IplImage*'.
Thanx!
Re: Receiving Image through serial port in QT
Do you already have a serial port access lib, if not select one first. This post lists some useful links
http://www.qtcentre.org/threads/5294...l-port-library
Then using one the library get the file from serial port, save it on disk, and open it as usual.
Re: Receiving Image through serial port in QT
Hi Santosh,
Is it mandatory to have Qextserialport or some other library to do serial communication in Qt? can't we write in C++ directly without having those libraries?
thanx
Re: Receiving Image through serial port in QT
You can always write using native OS APIs.