PDA

View Full Version : startLive throws an exception



Kay
March 25, 2004, 21:24:25
Stefan,

I have build a test app and can't figure out why the 'startLive' call is throwing an exception. I have gone through your samples to try to figure it out but this has not helped.

Here is an ordered sequence of my calls to your api:

getAvailableVideoCaptureDevices
openDev
isVideoNormAvailableWithCurDev
getAvailableVideoFormats
setVideoFormat
setHWND
setSinkType
getAcqSizeMaxX
getAcqSizeMaxY
newMemBufferCollection
setActivememBufferCollection

At this point, I construct my CListener object with FrameReady override

addListener

startLive(FALSE)

At this point, startLive throws an exception. Here is the message displayed:

"Exception DEBUG: in e:\daten\development\icimagingcontrol14\core\tisud shl\grabber.cpp at line 982.

CFilterGraph::startGraph() : failed to start the graph
COM Error Message: Insufficient system resources exist to complete the requested service.

In file: e:\daten\development\icimagingcontrol14\core\dshow lib\filtergraph.cpp at line: 595

Continue? (say "no" to rethrow catched exception or "yes" to continue without doing anything)"


I just started getting familiar with your API a few days ago. I figure it is probably some function called that I have forgotten to make. If you need more information on the parameters for some of the calls, please let me know.

I'm using MS VS 7.1 and your "_vc71" dlls.

Thanks,

Peter Davila

Stefan Geissler
March 26, 2004, 08:15:58
Peter,

Please send your project as zipped file to support at imagingcontrol dot com, so i can have a look on it.

Kay
March 26, 2004, 14:54:03
Stefan,

Thanks for the reply.

Let me ask you.

1 - From the list of API calls that I sent you, I figured may be I'm missing some required call prior to starting the capture. Is everything there?

2 - I'm using your API for capturing to buffers in PC system memory. I then use Direct3D for presenting the frames to the VGA card and my own code to save each frame of video to disk. Will your DirectShow based API work alongside my Direct3D device creation. Any possible conflicts there?

Thanks,

Peter.

Stefan Geissler
March 29, 2004, 09:16:20
Peter,

To question 1:
I do not see anything missing, but without the parameters to the functions, it is hard to see what you have done. How big is your Membuffer Collection?
As i mentioned above, a small sample project that reproduces this problem sent as zip to support at imagingcontrol dot com would be a great help for me. This would be handled very confidential.
A small hint: You do not need the size of the video format if you use


m_pMemBuffColl = m_Grabber.newMemBufferCollection( 5 );

to create the MemBuffer Collection. The lines


getAcqSizeMaxX
getAcqSizeMaxY

are not needed to create the MemBuffer collection.

To question 2:
No, there is no problem with Direct 3D. I wrote sample, that displays a live images on a rotating 3D objects. I found no conflicts. Make sure, the textures and Membuffer use the same pixel formats or write a simple conversion.

Kay
March 31, 2004, 22:31:24
Thanks for the help Stefan.

Application is up and running. It seems the code was left in some weird state after pausing it with a breakpoint. A restart of the PC fixed it.