Select to view content in your preferred language

Zoom factor and Smoother Transition

1092
5
01-11-2024 12:51 PM
Labels (3)
deeprey
Emerging Contributor

Hey Esri Community,

I'm hitting a bit of a snag with the zoom functionality. I'm hoping to get the zoom transitions smoother and the zoom steps a bit more refined – especially for pinch-zoom on mobile and scroll wheel zoom on desktop.

Does anyone have tips or examples on tweaking the `MapView` for a smoother, more granular zoom? I'm all ears for any advice or tricks you've found useful in your own projects dealing with things like zoom factor and animation ...

Any help would be much appreciated!

Cheers,

0 Kudos
5 Replies
LucasDanzinger
Esri Frequent Contributor

Have you looked at using setViewpoint method that takes an AnimationCurve - https://developers.arcgis.com/qt/cpp/api-reference/esri-arcgisruntime-mapview.html#setViewpointAsync?

You could listen to the various mouse/wheel signals on the mapview and implement your own custom logic https://developers.arcgis.com/qt/cpp/api-reference/esri-arcgisruntime-mapquickview.html 

0 Kudos
deeprey
Emerging Contributor

Hi Lucas, 

spot on , we tested it and it works perfectly fine. thanks.

In ENC charts, text and line sizes initially adjust to the zoom factor and then undergo a secondary adjustment. Can you confirm that this behaviour is part of the ArcGIS Runtime SDK's dynamic styling, aimed at ensuring legibility at different scales. Initially, elements scale with the zoom, followed by a readjustment for clarity. While this preserves readability, it can lead to a jarring user experience due to the sudden and noticeable resizing.(attached a screen video )
Is there a way to avoid or mitigate this initial resizing effect, ideally cancelling the immediate scaling that's applied with the new zoom factor, and directly apply the final, adjusted size for text and lines?

Any guidance on this would be greatly appreciated.

Thank you.

0 Kudos
LucasDanzinger
Esri Frequent Contributor

Thanks for the video, I understand better what you mean now. Unfortunately, the resize and snap effect you see is part of the implementation. We use a different rendering path for ENC due to the large, complex features. This is similar to our "static" rendering mode for graphics (as opposed to dynamic)

 

https://developers.arcgis.com/qt/qml/api-reference/enums-graphicsrenderingmode.html

 

https://github.com/Esri/arcgis-maps-sdk-samples-qt/tree/main/ArcGISRuntimeSDKQt_CppSamples/Layers/Fe...

 

 

0 Kudos
deeprey
Emerging Contributor

Hello,

Thank you for all your previous responses. I understand the complexities involved in rendering ENC data. However, I'm curious about the possibility of implementing dynamic rendering for ENC in a future update of the ArcGIS Runtime SDK for Qt. Could you share any insights on what factors would influence the decision to develop this feature? Are there any plans or considerations for such an implementation in upcoming SDK versions?

Again your help has been  greatly appreciated Lucas.

Best

0 Kudos
LucasDanzinger
Esri Frequent Contributor

We can log an enhancement for that if you like. Otherwise, you can log an enhancement through Esri Support (or through your distributor if you are international). Ultimately, factors that influence whether we prioritize something like this include number of people impacted, business case, whether there are suitable workarounds, etc. If you can, please email me (ldanzinger@esri.com) with details about your company, project, etc. Perhaps we could also setup a call with our product managers to better understand your use cases and what other priorities you have.

0 Kudos