I can use the TocvCameraSource and TocvView in win32 windows application. They work well
I put TocvCameraSource and TocvView in ocx( activexform in avtivexlib ), then activate the ocx in container . But the TocvCameraSource's OnImage can not be trigged when the physical camera's led is powe on(by enable the TocvCameraSource).
I can get the picture form camera in ocx only by using api of opencv
I use the class TocvCameraSource(in unit ocv.comp.Source)
:
ocvCameraSource2 := cvCreateCameraCapture(0); //activate the camera
then use a timer to pull the picture
:
procedure Tax4cv8.Timer1Timer(Sender: TObject);
var
m_img: pIplImage;
how to make the TocvCameraSource works well in ocx???
the attach files contain project in xe8 ( use opencv version 2.4.13)
app6: normal windows app
ax9: ocx with component can not get pictue;
Project4axlib9: gui client for ax9
ax8: ocx with api works well
Project4axlib8:gui client for ax8
I can use the TocvCameraSource and TocvView in win32 windows application. They work well
I put TocvCameraSource and TocvView in ocx( activexform in avtivexlib ), then activate the ocx in container . But the TocvCameraSource's OnImage can not be trigged when the physical camera's led is powe on(by enable the TocvCameraSource).
I can get the picture form camera in ocx only by using api of opencv
I use the class TocvCameraSource(in unit ocv.comp.Source)
:
ocvCameraSource2 := cvCreateCameraCapture(0); //activate the camera
then use a timer to pull the picture
:
procedure Tax4cv8.Timer1Timer(Sender: TObject); var m_img: pIplImage;
img2: Graphics.TBitmap;
m_img_o: IocvImage;
mybitmap: Graphics.TBitmap;
begin //
m_img := cvQueryFrame(ocvCameraSource2);
end;
how to make the TocvCameraSource works well in ocx???
the attach files contain project in xe8 ( use opencv version 2.4.13) app6: normal windows app ax9: ocx with component can not get pictue; Project4axlib9: gui client for ax9 ax8: ocx with api works well Project4axlib8:gui client for ax8
ws4opencv_delphi.zip