Hi Nicolas,
Let me make it clear that the code sample we provided is just for the purpose of showing how to override the Draw method of CustomWmsOverlay and control the request submitting in certain condition. It’s just a prototype of the CustomWMSOverlay, and you should have your own implementation of the overridden Draw method, in order to restrict the requested extend or accomplish other tasks.
In the sample class, the process of the Draw method is more like a single tile way, once the requested extend is not inside of the LayerBoundingBox, no WMS request will be submitted to server. If you want to handle the WMS requests tile by tile, you’ll have to override the DrawCore method, and that’s totally a different case from the sample.
For your first concern, it’s correct that the Draw method will be called just once, because it’s the DrawCore method that deals with tiles, not the Draw method.
It’s a strange case, as you described in your post, that zoom on CentralEurope there will still be WMS requests submitted to the server, but I’m not sure about that, because I can’t see what exactly the world extend is passed in the draw method when performing the zooming on central Europe. If the program goes into the base.Draw(worldExtent, OverlayDrawType.DoNotDraw) branch there will be no request. So I’m guessing that maybe the center point of zooming is very close to the edge of the BoudingBox. In fact, you can restrict this kind of request by adding some other condition judgments in the overridden Draw method to make sure the program will go to the DoNowDraw branch.
Still you can have a try overriding the DrawCore method; there you can control the requests tile by tile.
Thanks you very much.
James