Sorry, not enough information. Are you saying that the crash happens in the call to Sketchpad::Text? Did you check if the Sketchpad instance looks ok before the call?
Yes it did, even if I try
Code:
bool myMFD::Update (oapi::Sketchpad *skp)
{
skp->Pixel(10,10,RGB(100.0,0.0,0.0));
return true;
}
I got a CTD.
If I remove the line with skp-> ..., there will be no CTD.
The initialisation of the MFD mode is working, because I see my buttons and the button help texts etc.
So I suggest that something is wrong with the Sketchpad...
How shell I check if the Sketchpad is ok? I tried:
Code:
bool myMFD::Update (oapi::Sketchpad *skp)
{
if (&skp == 0) sprintf(oapiDebugString(),"IS NULL");
else sprintf(oapiDebugString(),"IS NOT NULL");
return true;
}
and ...
bool myMFD::Update (oapi::Sketchpad *skp)
{
if (skp == nullptr) sprintf(oapiDebugString(),"IS NULL");
else sprintf(oapiDebugString(),"IS NOT NULL");
return true;
}
and ...
bool myMFD::Update (oapi::Sketchpad *skp)
{
if (skp == NULL) sprintf(oapiDebugString(),"IS NULL");
else sprintf(oapiDebugString(),"IS NOT NULL");
return true;
}
and then it's seems not to be null?
If i use the compiled dll in Orbiter 2010, the usage of the Sketchpad will work.
I will try the following steps soon:
- Create a little demo project and compile with sdks of 2010 to eliminate other stuff from my VS Project
- Use the sdks of the new beta and compile again
after I will come back.
---------- Post added 16-09-15 at 00:37 ---------- Previous post was 15-09-15 at 23:29 ----------
So I checked it out:
After binding the
"orbiter.lib"
and the
"Orbitersdk.lib"
from the beta, it's working now. :thumbup:
I will test soon to bind the old libs to the new template MFD mode and see what will happent...