{"comment":{"created_at":"2011-10-11T16:21:17Z","body":"[cmarqu] Oh, thanks very much for that hint, the problem had bitten me too!","updated_at":"2011-10-11T16:21:17Z","url":"https://api.github.com/repos/artemp/mapnik/issues/comments/2366874","id":2366874,"user":{"avatar_url":"https://secure.gravatar.com/avatar/941f68386168a8a6b60f2529a7830af7?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","url":"https://api.github.com/users/artemp","id":59056,"login":"artemp"}},"action":"created","issue":{"number":477,"created_at":"2011-10-11T16:21:15Z","pull_request":{"diff_url":null,"patch_url":null,"html_url":null},"body":"Current png256 format allows only full opacity or full transparency pixels. Discussion about it can be found in http://trac.mapnik.org/ticket/202#comment:5. Now I'm presenting patch implementing mentioned solution: using 3 octrees, one per alpha range. Boundaries and assigned color numbers are computed based on image alpha distribution.\r\nThis allows more smooth transparency changes and eliminates jagged edges.\r\n\r\nIn attachment, beside patch and fixed files, there are: readme.txt with more info, some sample images for testing different cases and little program, that can be used to test png256 without need to compile all mapnik libraries. I used it while writing this fix to test different approaches.\r\n\r\nIn image attachments below You can see effects in different cases. Those images are divided to 3 columns:[[BR]]\r\n- left : source image[[BR]]\r\n- center : new algorithm[[BR]]\r\n- right : previous algorithm\r\n\r\nCodes are prepared against 0.7 branch (including latest fix to #445, #447).\r\nI suggest testing in different scenarios before committing. It isn't perfect, but in most situations should be enough, without much cputime or image size trade off (only 10% longer time and bigger image).","comments":7,"title":"semitransparency support for png256","updated_at":"2011-10-11T16:21:20Z","url":"https://api.github.com/repos/artemp/mapnik/issues/477","id":1877738,"assignee":null,"milestone":{"number":10,"created_at":"2011-10-11T15:50:24Z","due_on":"1970-01-01T09:21:08Z","title":"0.7.1","creator":{"avatar_url":"https://secure.gravatar.com/avatar/941f68386168a8a6b60f2529a7830af7?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","url":"https://api.github.com/users/artemp","id":59056,"login":"artemp"},"url":"https://api.github.com/repos/artemp/mapnik/milestones/10","open_issues":1,"closed_issues":2,"description":"= Mapnik 0.7.1 =\r\n\r\nThe 0.7.1 is a bugfix release, but also includes some new PNG output features.\r\n\r\nUntil tagging, source is here (after which this branch will be removed):\r\n{{{\r\nsvn co http://svn.mapnik.org/branches/0.7.1-dev/\r\n}}}\r\n\r\nRelease page: wiki:Release0.7.1\r\n\r\nCHANGELOG: source:tags/release-0.7.1/CHANGELOG\r\n\r\nUsage, either via Python or XML stylesheets should be fully compatible with the 0.6.x series.\r\n\r\n== Plugins ==\r\n * #500 - postgis: fixing full support for schemas in postgis plugin\r\n * #502  - gdal: bug in gdal scaling when using map buffer leading to poor image scaling\r\n * #504  - shapefile: support for pointz\r\n\r\n== Python ==\r\n * No changes\r\n\r\n== Core ==\r\n * #508 - image symbolizers: made optional use of width/height/type attributes in LinePatternSymbolizer and PolygonPatternSymbolizer to match PointSymbolizer\r\n * #512 - gamma: preservation of AA across symbolizers if gamma modified on PolygonSymbolizer\r\n * #484  - scons: applied preferential sorting to lib/inc directories to ensure linking first to source compiled libs in /usr/local/lib (like icu and boost) if duplicate libraries are in /usr/lib\r\n * Raster Fixes/Enhancements\r\n  * #522 - fix colors in huge png256 output\r\n  * #475 - fixed small shift in raster output\r\n  * #477 - added new hextree based quantization\r\n  * #477 - new png image compression options","state":"open"},"closed_at":null,"user":{"avatar_url":"https://secure.gravatar.com/avatar/941f68386168a8a6b60f2529a7830af7?d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png","url":"https://api.github.com/users/artemp","id":59056,"login":"artemp"},"html_url":"https://github.com/artemp/mapnik/issues/477","labels":[{"name":"Core_Library","url":"https://api.github.com/repos/artemp/mapnik/labels/Core_Library","color":"FFFFFF"}],"state":"open"},"legacy":{"issue_id":1877738,"comment_id":2366874}}