POST
|
This: while I wait to see if ESRI makes progress on an "In Product Plan" enhancement they have for adding support for ImageOverlay to 2D MapViews. is the most exciting thing I've heard in a while... 🙂 Our implementation definitely leaves much to be desired. Do you have a link or anything to where that product plan is discussed?
... View more
09-13-2021
06:49 AM
|
0
|
1
|
2164
|
POST
|
Hi Lee, I had a similar problem with trying to display a sonar fan which refreshes at 15-20Hz; I cobbled something together which basically can manage about a 3-5Hz refresh rate. (on an Ubuntu system running with 12 cores). The framework of what we did was: 1) Use a KML Icon. 2) Create a memory-file (I didn't use the QImageProvider; and that is probably a better route than what I did do, which was to use a Temporary File directly) based on the image from the sensor. 3) Have a timer going (at that 3-5 hz rate) at which time the "QUrl" of the file is applied to a new KML Icon. ...yes, NEW KML Icon. There are some bugs in the KML framework that I haven't had time to report yet. Primarily is that the `refresh` of KML Icons cannot be set to less than 1000ms or they will just cease happening. I had found another earlier this year but again, been too bombed under with work to try and submit a case. So I am not from Esri, and I would definitely defer to their knowledge. I do know that there were all sorts of problems with the KML Icon "pathway" until ArcGIS for QT 100.10, which was released early this year. So if you're still on 100.9 I would definitely suggest upgrading before attempting anything in the KML framework. (You can look at my post history for cases I had involving this topic). I'm happy to discuss ideas around this topic. Displaying sonar information on the map is a very key piece of functionality for us, and we're always looking for ways to improve!
... View more
09-12-2021
07:54 AM
|
1
|
3
|
2172
|
POST
|
Hi James, thanks for your response! I am witnessing this in ArcGIS Runtime for QT version 100.10 running against QT 5.15.0 on an Ubuntu system (19.10). My primary computer is a Lenovo P1 Gen2 with 12 cores and 16gb of RAM. I've also observed this on a Dell 7220 tablet PC running Ubuntu 18.04 (I don't really know the hardware specs). The "Mapping Environment" has a total of 8 overlays, and I would say the total number of graphics divided amongst those would number at most a few hundred (but I am observing the behavior with less than 100 graphic objects). Also I should note that at least a few of the graphics are updated (position/orientation) at up to a 20 Hz refresh rate. By "a few" I mean less than 10 generally speaking. It would be exceedingly rare that we are tracking more than 10 "active" graphics. Also the situation seems to be exacerbated when there is an ENC (s.57) layer loaded underneath the graphics. I don't have any hard-and-fast data on this, but I definitely notice more trouble when an ENC is loaded than when there isn't an ENC. I'm traveling today, but I will take a look at the code snippet you posted and see what I can see. One thing I should note is that I'm using a Map / MapGraphicsView (not a MapQuickView) and the application we have requires a 2-d presentation. I can do a more thorough code posting if you'd like. (Again my internet access will be spotty today (7/21/21) but I can be online later this week). Thanks again for looking into this, Regards, Brian
... View more
07-21-2021
05:10 AM
|
0
|
1
|
1273
|
POST
|
I'm experiencing a situation where identifyGraphicsOverlay calls are never indicating they've finished to the application. I've got an application with several layers of GraphicsOverlays, and when an end-user clicks on the mapView, I need to identify what items in which layer may have been clicked. What I'm observing is that if I get "click happy" the identifyGraphicsOverlay calls will stack (I am keeping a list of taskWatchers) and nothing happens... eventually the mapView will lock up until I move the mouse off the application; at which point all of the tasks seem to execute and the mapView "frees up" as if nothing ever happened. I've put in a monitor function to gain information about the taskWatchers, and they are valid and remain so. Here's a little bit of that monitor's output: Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Other task count: 22 -- tasks started: 60 ; tasks finished: 38 "Hung states = [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid] [valid]" Again, as soon as I move the mouse off of the application, I am seeing this: Other task count: 0 -- tasks started: 60 ; tasks finished: 60 Other task count: 0 -- tasks started: 60 ; tasks finished: 60 Other task count: 0 -- tasks started: 60 ; tasks finished: 60 Here is the relevant code: connect(m_mapView, &MapGraphicsView::identifyGraphicsOverlayCompleted, this, &App::identify_overlay_completed); ... void App::build_taskwatchers(const QList<our_layer_enum> layers_to_watch, const int x, const int y) { constexpr double tolerance = 5; constexpr bool returnPopupsOnly = false; constexpr int maximumResults = 10; // Set up a bunch of identifyGraphics threads to see which (if any) overlay items // were clicked. for (our_layer_enum layer : layers_to_watch) { Esri::ArcGISRuntime::TaskWatcher tw = m_mapView->identifyGraphicsOverlay(m_overlays[layer].data(), x, y, tolerance, returnPopupsOnly, maximumResults); } } ... void App::identify_overlay_completed(const QUuid id, Esri::ArcGISRuntime::IdentifyGraphicsOverlayResult * raw_result) { ... do stuff Again, if you click like a sane human, this all works fine. But our users tend to get click happy; and when they do so "identify_overlay_completed" is never called. I have tried to do the identifyGraphicsOverlays / identifyGraphicsOverlaysCompleted pairing instead, and it did the same thing; that is, it never finished tasks if someone was click happy. I guess what I'm looking for is a way to actually have TaskWatcher::cancel work. I have tried cancelling the tasks in my little monitor function if they are aged out, and it does absolutely nothing. The only (seemingly magical) way to get these stuck identifications unstuck is to move the mouse off of the application. Note: I did build the "IdentifyGraphics" tutorial, and while it never freezes up, if you get click-happy with it, it will intermittently not pop up the "Tapped on Graphic" message. It never seems to lock up though.
... View more
07-16-2021
08:24 AM
|
0
|
3
|
1323
|
POST
|
Hi Y'all, This is an embarrassing question to ask, because it will expose my ignorance to GIS topics. But I can't figure out how to do this operation and I'm wondering if someone could throw me a bone. So I have an image that I need to scale based on the zoom level of the map and place in a PictureMarkerSymbol. (Operating in Map / MapGraphicsView). When I place the image at location 0,0 (WGS84), the UnitsPerDIP call returns a value that scales the image appropriately. But (perhaps obviously), when I place the image at a location away from (0,0), the image's size is different. So is the solution to use the GeometryEngine to MoveGeodetic to the location in question? If so, I don't really understand how to "move" a PictureMarkerSymbol (which is referenced by a single point) instead of something like the 4 corners of an envelope... but an envelope isn't the geometry I need. Another way to put it: I have an icon that is a 10x10 meter square. When I scale my original graphic's PNG using UnitsPerDIP at location 0,0 it scales properly. When I scale it at WGS84 lon,lat (-70.6, 41.9) the graphic renders to somewhere in the mid 7 meters per side. How do I make it 10x10 meters at (-70.6, 41.9)? Thank you, Brian Crist
... View more
11-03-2020
02:55 PM
|
0
|
1
|
777
|
POST
|
Hi, I've been trying to implement solution for displaying a sonar fan in a map for about 6 months now with little to no success due to various issues with PictureMarkerSymbols and KML Icons as they behave in the 2-d (map/mapview) environment. So I'm wondering if it's possible to implement my own Animated symbol derived from the MarkerSymbol class? I'm guessing it's not, but I felt like it was worth asking. If it is possible, is there a guide or sample code anywhere? Regards, Brian Crist
... View more
11-02-2020
12:04 PM
|
0
|
0
|
395
|
POST
|
Hi Lucas, Yes - I've got a case with Sami: 02650457 -- I uploaded a demonstration application via the FTP server yesterday.
... View more
10-05-2020
08:03 AM
|
0
|
1
|
1292
|
POST
|
Hi Lucas, Yes, I tried making it a member of the containing class and saw no difference. Well, the rectangle-to-square distortion happened at a farther sonar range, but it definitely still happened.
... View more
10-02-2020
09:13 AM
|
0
|
3
|
1292
|
POST
|
So the height() and width() calls reflect what I set the values to with setHeight() and setWidth(). I also verified that the height and width values are 0 if I do not set them. Setting the rendering mode made no difference in either case. I also have noticed that when you go from "big" to "little" it leaves detritus on the screen. Could this be happening because the PictureMarkerSymbol is a local (stack) variable? Should I make it static? Or should I make it a class member? It doesn't seem like you can "update" the imagery in a PictureMarkerSymbol, so I don't know if we can do that...
... View more
09-30-2020
10:02 AM
|
0
|
5
|
3425
|
POST
|
Calling setWidth and setHeight makes no difference to the appearance - I will double check what it does to the reported sizes and get back to you. I'll also set the rendering mode explicitly and let you know. Thanks! Brian
... View more
09-30-2020
09:20 AM
|
0
|
0
|
3425
|
POST
|
So that's an interesting thing actually. You can see in the code above that I've got it set to the width and height of the scaled image - but before I put those calls in there, the width and height would report 0 at all times! I'm trying several things right now on my end to make this work, but I feel like there's a key element I may have missed reporting above. It should be noted that in the code above, the overlay is set to setScaleSymbols of TRUE and the map has a reference scale. If this itself presents a problem please let me know.
... View more
09-30-2020
07:46 AM
|
0
|
8
|
3425
|
POST
|
Awesome, thank you. I am continuing to research here as well and I will post if I figure anything out. Regards, Brian
... View more
09-29-2020
01:44 PM
|
0
|
0
|
3425
|
POST
|
Hi James, I would love, love, love to use an ImageOverlay, but we are using a Map / GraphicsMapView (2d) architecture for our application for several reasons, and ImageOverlay does not operate on those. Regards, Brian
... View more
09-29-2020
01:36 PM
|
0
|
2
|
3425
|
POST
|
I have a graphic that is being updated at a regular interval (15-20hz) that I would really like to use a KML overlay for, but cannot since updating KML Overlays doesn't work in 2d maps. (Prior Conversation on GeoNet) So I've been using a PictureMarkerSymbol with some success, but I am now observing some weirdness with it. I'm wondering if it's something I am doing wrong or if I've stumbled on another bug. The basic workflow is the sensor (a sonar) that we're tracking feeds us a stream of QImages. I scale the QImage to the appropriate size according to our current zoom level and map scaling and create a PictureMarkerSymbol using this code block: Esri::ArcGISRuntime::Graphic m_graphic; // declared elsewhere Esri::ArcGISRuntime::GraphicsOverlay m_overlay; // Set up elsewhere Esri::ArcGISRuntime::Point point; // Set up elsewhere Esri::ArcGISRuntime::PictureMarkerSymbol pms(scaled_image,this); pms.setAngle(m_heading); pms.setWidth(scaled_image.width()); pms.setHeight(scaled_image.height()); if (m_graphic.isNull()) { m_graphic = new Esri::ArcGISRuntime::Graphic(point, &pms); m_overlay->graphics()->append(m_graphic); } else { m_graphic.data()->setSymbol(&pms); m_graphic.data()->setGeometry(point); } The functionality is great to an extent. But when the image exceeds a certain size (in this case, 20 meters), the PictureMarkerSymbol seems to unexpectedly change its shape as demonstrated in the 3 images I have attached. The first image shows a sonar at range of 16 meters, the second a range of 19 meters; you can see the aspect ratio of the image/PictureMarkerSymbol (dim red rectangle with the sonar fan in the front of it) is a distinct rectangle. When the range reaches 20 meters, the aspect ratio of the image / PictureMarkerSymbol changes into a square!! I know this is not in the QImage scaling code, as I've stepped through and observed the QImage itself scaling properly. The "change" happens within the PictureMarkerSymbol. Please advise. Regards, Brian
... View more
09-29-2020
12:48 PM
|
0
|
14
|
4864
|
POST
|
Thanks James, That is similar to what we're trying to accomplish, but we're using the Runtime for QT API - so I'd need the functionality behind what's in Pro exposed anyways, which it sounds like it isn't on the radar. Thanks for the info! I'm implementing a meter-based grid in our code, which is... well, it's sub-optimal. But I am glad to have confirmation that I am not doing something that's already been done! Regards, Brian
... View more
09-28-2020
04:07 PM
|
0
|
0
|
707
|
Title | Kudos | Posted |
---|---|---|
1 | 09-12-2021 07:54 AM |
Online Status |
Offline
|
Date Last Visited |
04-11-2023
09:08 PM
|