• Advertisement

Archived

This topic is now archived and is closed to further replies.

MSVC++ err msg : "scalar deleting destructor returned"

This topic is 5237 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

What does this mean - "scalar deleting destructor returned" ????? Ive tried looking it up on microsofts site.. no luck Ive put it in the google search box... nothing I cant for the life of me finger this one out. Basically, it occurs after I try to delete a pointer. Heres a copy of the destructor code that gets called :

cVideo::~cVideo()
{	
    pVW->put_Visible(OAFALSE);
    pVW->put_Owner(NULL);

    // Disable event notification before releasing the graph.
    pEvent->SetNotifyWindow(NULL, 0, 0);
    pEvent->Release();
    pEvent = NULL;

    // Stop the graph.
    pMediaControl->Stop();

	pVW->Release(); pVW = NULL;
	
	pMediaControl->Release(); pMediaControl = NULL;
	
	pGraph->Release(); pGraph = NULL;
	
	CoUninitialize();
}

 
Prolly something simple I didnt know.... AGAIN!! -Jason

Share this post


Link to post
Share on other sites
Advertisement
Could be... not sure, could use some edumacating on the subject.

Im not deleting an array.

Heres some relevant code :

In main.cpp, cVideo is declared globally. Its basically a simple class that makes using DirectShow easier.

#include "cVideo.h"
cVideo *video = NULL;
//for event messages from a direct show window
#define WM_GRAPHNOTIFY WM_APP + 1
#define CLASSNAME "EventNotify"


After your standard non-MFC way of creating a window, video is initialized, used, then deleted (upon which I get that error)

video = new cVideo;
video->PlayVideo(1);
delete video;


Still dazed and confused.
-Jason

Share this post


Link to post
Share on other sites

  • Advertisement