PDA

View Full Version : Help me!



abdul_khathar
February 16, 2009, 08:29:40
Dear Sir,

i need to know which function will run execute first and last when u start and stop live.. ?

i mean upto my knowledge SetParent() function calls first (and also ones) when we start live.

is it true? if yeas. please let know which function calls when we close the camera live.? im using user defined array (COLORREF) in DrawBuffer( smart_ptr<MemBuffer> pBuffer) for my own image processing.. i have created that array (COLORREF) in SetParent().

if i try to delete that array before stopLive(), its showing error. so please let me knw how to solve this problem.

thanks in advance.

Abdul

Stefan Geissler
February 16, 2009, 09:32:30
Dear Abdul,

I must surrender, I do not know, what you are speaking about. startLive() and stopLive do not call any "SetParent()" function. I guess you are speaking about a program, that uses a CListener::frameReady. The CListener class seems to have an attribute "parrent", which a window handle was passed too. This usually is done in an InitDialog method or similar of your main program. And this is done only once, independend of startLive or stopLive.

Also I think, it better to create the array once in the constructor of CListener.