Releases: jongough/ocpn_draw_pi
Release 1.2
Includes:
Guard Zones
ODAPI - fast C interface to API
Persistent layers
Minor fixes
Pre release of OD 1.2
Merge pull request #268 from jongough/updates_1.1 Fix warning message re redefinition of MIN & MAX
Pre release
This is the first pre release. All the major new functionality for the next version is available and has been beta tested.
Minor fixes
Fix GZ points moving due to 'rotate with boat' and moving the control… … ODPoints
Fix display of Text Point text in non-opengl
1.1.19 Fix not displaying Text Point text in non-opengl
New ODAPI for faster access to boundary information
This update introduces the ODAPI which allows other plugins and OCPN to gain direct access to the JSON API functios without the overhead of JSON processing. You will need to include ODAPI.h in your code and then use a JSON message to get the addresses of all the API's.
Example to get the api's:
wxJSONValue jMsg;
wxJSONWriter writer;
wxString MsgString;
jMsg[wxT("Source")] = wxT("WATCHDOG_PI");
jMsg[wxT("Type")] = wxT("Request");
jMsg[wxT("Msg")] = wxS("GetAPIAddresses");
jMsg[wxT("MsgId")] = wxS("GetAPIAddresses");
writer.Write( jMsg, MsgString );
SendPluginMessage( wxS("OCPN_DRAW_PI"), MsgString );
if(g_ReceivedODAPIMessage != wxEmptyString && g_ReceivedODAPIJSONMsg[wxT("MsgId")].AsString() == wxS("GetAPIAddresses")) {
wxString sptr = g_ReceivedODAPIJSONMsg[_T("OD_FindPointInAnyBoundary")].AsString();
if(sptr != _T("null")) {
sscanf(sptr.To8BitData().data(), "%p", &pOD_FindPointInAnyBoundary);
l_bUseODAPI_FPIAB = true;
}
sptr = g_ReceivedODAPIJSONMsg[_T("OD_FindClosestBoundaryLineCrossing")].AsString();
if(sptr != _T("null")) {
sscanf(sptr.To8BitData().data(), "%p", &pODFindClosestBoundaryLineCrossing);
l_bUseODAPI_FCBLC = true;
}
}
Example calling api's:
FindClosestBoundaryLineCrossing_t *pFCPIAB = new FindClosestBoundaryLineCrossing_t;
pFCPIAB->dStartLat = lastfix.Lat;
pFCPIAB->dStartLon = lastfix.Lon;
pFCPIAB->dEndLat = lat;
pFCPIAB->dEndLon = lon;
(*pODFindClosestBoundaryLineCrossing)(pFCPIAB)
Included with this is a binary of a matching WatchDog plugin that uses this new method for distance and time from boundaries.
Beta version
Remove unneeded JSON messages on Path activate/deactivate Create new ODJSON class to handle messages Pass state back when responding to FindPointInGuardZone message
Fix windows issue with GZ properties dialog
Merge pull request #252 from jongough/fixes Fixes
stabilised 1.0 release
Merge pull request #252 from jongough/fixes Fixes
Minor fixes
This patch level fixes an EBL issue where the EBL was incorrectly displayed if 'maintain with heading' was selected and 'rotate with boat' was deselected. It also fixes a non-opengl issue which stopped the current bearing and length being shown when the end point of the EBL was moved.