Closed rgleason closed 2 years ago
What additional Plugin API would be needed to have Ocpn_draw handle Route Manager and Waypoints?
Extended WP information to the API in OpenCPN Beta Version 5.5.1015 Release Define and implement extended Waypoint API
Declaration of Plugin_waypoint_Ex, GetFFSstatus, GetRouteMembershipCount, Plugin_Route_Ex
// Extended Waypoint manipulation API
extern DECL_EXP bool GetSingleWaypointEx(wxString GUID, PlugIn_Waypoint_Ex *pwaypoint);
extern DECL_EXP bool AddSingleWaypointEx(PlugIn_Waypoint_Ex *pwaypoint); <---UPDATED
extern DECL_EXP bool UpdateSingleWaypointEx(PlugIn_Waypoint_Ex *pwaypoint);
extern DECL_EXP bool AddPlugInRouteEx(PlugIn_Route_Ex *proute); <---UPDATED
extern DECL_EXP bool UpdatePlugInRouteRx(PlugIn_Route_Ex *proute);
extern DECL_EXP std::unique_ptr<PlugIn_Waypoint_Ex> GetWaypointEx_Plugin(const wxString &);
extern DECL_EXP std::unique_ptr<PlugIn_Route_Ex> GetRouteEx_Plugin(const wxString &);
extern DECL_EXP bool AddSingleWaypointEx(PlugIn_Waypoint_Ex *pwaypoint, bool b_permanent = true);
xtern DECL_EXP bool AddPlugInRouteEx(PlugIn_Route_Ex *proute, bool b_permanent = true);
Add IconDescription field to PlugIn_Wayoint_Ex
wxString IconDescription;
See the OpenCPN Discussion
OD could do Route and Waypoint, but this would require Dave to make the decision. There is no point in having two ways of doing the same task as it would just waste developer resources. The current design of OD is based on OCPN Route and Waypoint code but modified to make it more generic hence Path and Points which are then specialised into the different objects that OD current handles. It would take little to generate Route and Waypoints, but the effort would be in handling autopilots and making the system resource efficient and fast enough to be really useful.
Good point about AP. Is that possible?
Anything is possible, but it would/may require further OCPN API's to do it. Again, unless Dave wants to have OD reintegrated into OCPN or offload the Route and Waypoint processing and all the associated funtions, i.e. AP, then there is little point in starting the process.
That said, if someone wants to play with OD and OCPN to get this functionality working they only need to have the two git repositories and create a new branch and work on those. That is what I did for OD when splitting it off from OCPN.
Thanks Jon.
Maybe I shoild close this.
https://github.com/OpenCPN/OpenCPN/discussions/2450