gws.gis.mpx.util
¶
Utility functions for MapProxy integration.
This module provides utilities for annotating and decorating MapProxy images.
Source code: gws.gis.mpx.util
Module Contents¶
- gws.gis.mpx.util.annotate(image: Any, service: str, layers: List[str], environ: Dict[str, Any], query_extent: Tuple[Any, Any], **kw: Any) mapproxy.image.ImageSource ¶
Annotate a MapProxy image with request information.
This function is used as a callback for MapProxy’s decorate_img middleware. It adds text information about the request to the image.
- Parameters:
image – The MapProxy image object to annotate.
service – The OWS service name (WMS, WMTS, etc.).
layers – List of requested layer names.
environ – The WSGI environment dictionary.
query_extent – A tuple containing SRS and coordinate information.
**kw – Additional keyword arguments.
- Returns:
An ImageSource object with the annotated image.