| 2707 | */ |
| 2708 | |
| 2709 | void msImageStartLayer(mapObj *map, layerObj *layer, imageObj *image) |
| 2710 | { |
| 2711 | if (image) |
| 2712 | { |
| 2713 | if( MS_RENDERER_PLUGIN(image->format) ) { |
| 2714 | char *approximation_scale = msLayerGetProcessingKey( layer, "APPROXIMATION_SCALE" ); |
| 2715 | if(approximation_scale) { |
| 2716 | if(!strncasecmp(approximation_scale,"ROUND",5)) { |
| 2717 | MS_IMAGE_RENDERER(image)->transform_mode = MS_TRANSFORM_ROUND; |
| 2718 | } else if(!strncasecmp(approximation_scale,"FULL",4)) { |
| 2719 | MS_IMAGE_RENDERER(image)->transform_mode = MS_TRANSFORM_FULLRESOLUTION; |
| 2720 | } else if(!strncasecmp(approximation_scale,"SIMPLIFY",8)) { |
| 2721 | MS_IMAGE_RENDERER(image)->transform_mode = MS_TRANSFORM_SIMPLIFY; |
| 2722 | } else { |
| 2723 | MS_IMAGE_RENDERER(image)->transform_mode = MS_TRANSFORM_SNAPTOGRID; |
| 2724 | MS_IMAGE_RENDERER(image)->approximation_scale = atof(approximation_scale); |
| 2725 | } |
| 2726 | } else { |
| 2727 | MS_IMAGE_RENDERER(image)->transform_mode = MS_IMAGE_RENDERER(image)->default_transform_mode; |
| 2728 | MS_IMAGE_RENDERER(image)->approximation_scale = MS_IMAGE_RENDERER(image)->default_approximation_scale; |
| 2729 | } |
| 2730 | MS_IMAGE_RENDERER(image)->startLayer(image, map, layer); |
| 2731 | } |
| 2732 | else if( MS_RENDERER_IMAGEMAP(image->format) ) |
| 2733 | msImageStartLayerIM(map, layer, image); |
| 2734 | |
| 2735 | } |
| 2736 | } |
| 2737 | |
| 2738 | |
| 2739 | /** |
no test coverage detected