Comments (3)
Hi,
Glad that you have found this code helpful.
The easiest way might be to write a class which inherits MapGraphicsView and overrides the virtual mouse-handling events in that class.
There is an example of this in another one of my projects (which consumes this project) here: https://github.com/raptorswing/FlightPlanner/tree/UserStudy/WaypointPlanner/gui
See the "WaypointMapView" class.
Hopefully this helps.
from mapgraphics.
thanks raptorswing for the response .
in last 2 3 days i was working on your code , that's really good,
i add waypoints by double click ,
remove points,
make a polygon with those points,
and also changed it's server to Bing satellite server.
there was some problem to convert cursor position to latitude and longitude(find method in your code),well because of my weakness :)
although i'm not so good in ObjectOriented and inheritance but i did something :)
last night i was thinking it will be grate if it's possible to add markers(instead of points(circles)) and sequence number of marker added to map beside it's marker (for waypoints,) and/or another .png image as UAV(multirotor) .
now it is :
is it possible now with current code?? if not , any help would be grate
from mapgraphics.
Hi,
Yes, it's definitely possible to add custom markers for a series of points. It looks like you've experimented with the PolygonObject provided in MapGraphics. This may not be the best choice for representing the flight path of a UAV since PolygonObject will always make a loop.
When I was working on a similar effort I represented a UAV's flight path as a series of connected LineObject objects. I used a wrapper class to manage the LineObjects based on inputs (adding a new waypoint, deleting a waypoint, moving a waypoint, etc.).
These might be helpful as examples:
https://github.com/raptorswing/FlightPlanner/blob/UserStudy/PlanningCommon/WaysetDisplayManager.cpp
https://github.com/raptorswing/FlightPlanner/blob/UserStudy/PlanningCommon/MapObjects/Waypoint.cpp
In fact, you might be able to get some reuse in general out of the WaypointPlanner sub-project here: https://github.com/raptorswing/FlightPlanner/tree/UserStudy . If you build the top-level FlightPlanner project you should be able to run WaypointPlanner and get some context.
from mapgraphics.
Related Issues (20)
- Compatibility with Qt 4 may be broken? HOT 1
- Downstream HOT 1
- LineObject is not positioned properly on the map HOT 3
- Change map CRS (Coordinate Reference Systems) support. HOT 2
- PolygonObject painting as if open, Only repainting at certain zoom levels HOT 2
- Get latitude/longitude on mouse double click HOT 2
- Network Error: "Host otile1.mqcdn.com not found" HOT 2
- Tile references to openstreetmap.org should be https not http now. HOT 2
- Zoom the map with the mouse wheel
- Itβs good written code. HOT 1
- TestApp is not working - URL changed HOT 1
- How to rotate map HOT 5
- Map Flicking HOT 1
- Error compilation with Qt 6 HOT 5
- Image could not be redrawn HOT 1
- SSL Error
- Can offline tiles be loaded HOT 1
- Software license is missing HOT 1
- Issues compiling using MSVC11 (2012)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mapgraphics.