Select to view content in your preferred language

Would maptip for feature slow down the performance?

703
4
06-23-2011 12:37 PM
DanDong
Deactivated User
Hi everyone,

I have four featurelayers with maptip just like below and I found that the response time of the application seems been slowed down. Plus, sometimes the maptip doesn't stay on the map and sometimes it stays even my mouse has moved to other places, and it may not display the maptip. I guess these all result from the low response time. So does maptip slow down the performance? Or I lost some critical things in my codes? Thank you! 🙂

<esri:FeatureLayer ID ="EcocatParcelMaptip" Url="http://rmms-dev.atlas.illinois.edu/ArcGIS/rest/services/ecocatparcels_new/MapServer/0" Visible ="False" 
                               OutFields ="PROJCODE" >
                <!--<esri:FeatureLayer.OutFields>
                    <sys:String>PROJCODE</sys:String>
                </esri:FeatureLayer.OutFields>-->
                <esri:FeatureLayer.MapTip>
                    <Border esri:GraphicsLayer.MapTipHideDelay="00:00:01.5" CornerRadius="10" BorderBrush="#FF222957" BorderThickness="3" Margin="0,0,15,15">
                        <Border.Background>
                            <LinearGradientBrush EndPoint="1.038,1.136" StartPoint="0.015,0.188">
                                <GradientStop Color="#FFD1DFF2"/>
                                <GradientStop Color="#FF092959" Offset="0.946"/>
                            </LinearGradientBrush>
                        </Border.Background>
                        <Border.Effect>
                            <DropShadowEffect ShadowDepth="10" BlurRadius="14" Direction="300" />
                        </Border.Effect>
                        <StackPanel Orientation="Vertical" Margin="20,15,20,15">
                            <StackPanel Orientation="Horizontal" Margin="0,0,0,6">
                                <TextBlock Text="PROJCODE : " FontWeight="Bold" Foreground="#FF0F274E" FontSize="12" />
                                <TextBlock Text="{Binding [PROJCODE]}" Foreground="#FFFFFFFF" FontSize="12" FontStyle="Italic" FontFamily="Portable User Interface" />
                            </StackPanel>
                        </StackPanel>
                    </Border>
                </esri:FeatureLayer.MapTip>
            </esri:FeatureLayer>
0 Kudos
4 Replies
dotMorten_esri
Esri Notable Contributor
How many features do you have in your featurelayers, and how complex are they? It's very easy to hit the limit of the PC if you try and display too many layers on the client. This is what server-side rendering is much much much better for.

Also:
- Does performance improve if you remove the maptips? (I don't think that should matter too much though).
- Try and remove the dropshadow effect. Effects are VERY expensive.
0 Kudos
DanDong
Deactivated User
Hi Morten, thank your for the advices. I just checked the info. So four layers need maptips. They have 2000, 4337, 488, 1273 features, separately. Each layer only needs to display 1-3 fields in the maptip.

1. I remove the dropshadow effect for the maptip and the performance gets better.
2. I remove the featurelayer with maptip and the performance gets better.

You mentioned "server-side rendering". That means I should probably publish a feature service (like this: http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/BloomfieldHillsMichigan/LandusePlanning/F...)  How should I do to implement maptip in the server side?
In addition, I do have like 15 graphicslayer for different usage in my application and I put all of them in the xaml. I assign them to graphicslayer when I use them. If this will slow down the performance, then how should I do to render them in the server-side? Thank you!
GraphicsLayer wirtBufferGraphicslayer = MyMap.Layers["MyWirtBufferGraphicsLayer"] as GraphicsLayer;
0 Kudos
DanDong
Deactivated User
Hi guys, any tips on this issue? Thank you advance!
0 Kudos
dotMorten_esri
Esri Notable Contributor
Your problem is not the maptip. Your problem is that you have a serious amount of data on the client. Consider that the client have to download and render data for 1000s of features/megabytes, where they might actually only want to see information on a handful of features. That's a huge overhead to incur on the user.

I suggest you watch the "tricks" I used in the following video: http://proceedings.esri.com/library/userconf/devsummit11/videos/video90.html (jump to 26:30)
The InfoWindow approach covered at the end of the performance part is probably your best bet.

FeatureLayers should be used very wisely and limited. Often your best bet is to keep the data rendered on the server.
0 Kudos