[mapguide-trac] #996: non-PNG images in DWF drawing sources rendered upside down with AGG

MapGuide Open Source trac_mapguide at osgeo.org
Thu May 21 15:19:03 EDT 2009


#996: non-PNG images in DWF drawing sources rendered upside down with AGG
-------------------------------+--------------------------------------------
 Reporter:  waltweltonlair     |         Owner:  waltweltonlair
     Type:  defect             |        Status:  assigned      
 Priority:  high               |     Milestone:  2.1           
Component:  Rendering Service  |       Version:  2.1.0         
 Severity:  major              |    Resolution:                
 Keywords:                     |   External_id:  1042721.01    
-------------------------------+--------------------------------------------
Comment (by waltweltonlair):

 We had a similar problem a while back - see ticket #941.  For that ticket
 the original problem was that W2Ds containing PNG images were drawing
 upside down.  The correct fix was made to agr_process_pngGroup4Image (in
 AGGW2DRewriter.cpp), but the same code change was also made to
 agr_process_image.  The latter method should not have been changed.

 The agr_process_pngGroup4Image method calls AGGImageIO::DecodePNG which
 returns a buffer that already contains a pre-inverted image.  Therefore
 the subsequent call to !DrawScreenRaster needs to be done with a positive
 height.  This was corrected for ticket #941.

 But the image buffer used by agr_process_image method does not contain a
 pre-inverted image, and therefore the associated call to !DrawScreenRaster
 needs to be done with a negative height.

-- 
Ticket URL: <https://trac.osgeo.org/mapguide/ticket/996#comment:2>
MapGuide Open Source <http://mapguide.osgeo.org/>
MapGuide Open Source Internals


More information about the mapguide-trac mailing list