{"id":18739589,"url":"https://github.com/springmeyer/mapnik-raster-overzoom","last_synced_at":"2025-07-24T00:05:36.823Z","repository":{"id":20030874,"uuid":"23298920","full_name":"springmeyer/mapnik-raster-overzoom","owner":"springmeyer","description":"Testcase for Mapnik raster overzooming","archived":false,"fork":false,"pushed_at":"2014-08-25T02:30:17.000Z","size":108,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-05-20T04:35:05.475Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/springmeyer.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-08-25T02:13:30.000Z","updated_at":"2019-08-13T15:49:15.000Z","dependencies_parsed_at":"2022-08-31T06:22:34.058Z","dependency_job_id":null,"html_url":"https://github.com/springmeyer/mapnik-raster-overzoom","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/springmeyer/mapnik-raster-overzoom","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/springmeyer%2Fmapnik-raster-overzoom","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/springmeyer%2Fmapnik-raster-overzoom/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/springmeyer%2Fmapnik-raster-overzoom/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/springmeyer%2Fmapnik-raster-overzoom/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/springmeyer","download_url":"https://codeload.github.com/springmeyer/mapnik-raster-overzoom/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/springmeyer%2Fmapnik-raster-overzoom/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266770554,"owners_count":23981584,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-23T02:00:09.312Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T15:36:25.684Z","updated_at":"2025-07-24T00:05:36.801Z","avatar_url":"https://github.com/springmeyer.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\n## Mapnik Raster overzoom\n\nThis testcase:\n\n - Renders a 256x256 final image\n - Uses a source image that is also 256x256 that is meant to represent the entire world's mercator bbox\n - Tests rendering at various extents that mimic a few tile requests\n - Uses a large buffer size to more clearly expose the problem\n - The farther you zoom in the more you overzoom on the existing raster (a pixelatted result is expect in a real world situation)\n\n The problem is:\n\n - The farther you zoom in the larger the intermediate buffer becomes that is created right here: https://github.com/mapnik/mapnik/blob/48c23f27dc1524fb17d7f81160a72cd2639d8b07/include/mapnik/renderer_common/process_raster_symbolizer.hpp#L113\n - This starts really hurting performance at higher zooms\n - Ultimately a very high zoom and very large buffer could end up allocating an image too big for the heap\n\n\nUsing the `debug.diff` patch against master and running the test `python test.py` gives:\n\n\n```\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans scale x/y 6.38802e-06/6.38802e-06\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans extent box2d(-20037508.3427892439067364,-20037508.3427892439067364,20037508.3427892439067364,20037508.3427892439067364)\nMapnik LOG\u003e 2014-08-24 19:28:30: source w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: source-\u003eext_ box2d(-20037508.3427892439067364,-20037508.3427892476320267,20037508.3427892439067364,20037508.3427892774343491)\nMapnik LOG\u003e 2014-08-24 19:28:30: ext box2d(0.0000000000000000,-0.0000000000002142,255.9999999999999716,256.0000000000000568)\nMapnik LOG\u003e 2014-08-24 19:28:30: raster width/height 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: start x/y 0/0\nMapnik LOG\u003e 2014-08-24 19:28:30: end x/y 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: image_ratio x/y 1/1\nMapnik LOG\u003e 2014-08-24 19:28:30: •••••••••••• SCALE 1:1 ••••••••••••\nMapnik LOG\u003e 2014-08-24 19:28:30: •••••••••••• DIRECT COMPOSITE ••••••••••••\n\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans scale x/y 1.2776e-05/1.2776e-05\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans extent box2d(-20037508.3427892439067364,0.0000000000000000,0.0000000000000000,20037508.3427892439067364)\nMapnik LOG\u003e 2014-08-24 19:28:30: source w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: source-\u003eext_ box2d(-20037508.3427892439067364,-20037508.3427892476320267,20037508.3427892439067364,20037508.3427892774343491)\nMapnik LOG\u003e 2014-08-24 19:28:30: ext box2d(0.0000000000000000,-0.0000000000004284,511.9999999999999432,512.0000000000001137)\nMapnik LOG\u003e 2014-08-24 19:28:30: raster width/height 512/512\nMapnik LOG\u003e 2014-08-24 19:28:30: start x/y 0/0\nMapnik LOG\u003e 2014-08-24 19:28:30: end x/y 512/512\nMapnik LOG\u003e 2014-08-24 19:28:30: image_ratio x/y 2/2\nMapnik LOG\u003e 2014-08-24 19:28:30: •••••••••••• TARGET TOO BIG ••••••••••••\n\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans scale x/y 2.55521e-05/2.55521e-05\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans extent box2d(-20037508.3427892439067364,-0.0000000009313226,-10018754.1713946219533682,10018754.1713946200907230)\nMapnik LOG\u003e 2014-08-24 19:28:30: source w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: source-\u003eext_ box2d(-20037508.3427892439067364,-20037508.3427892476320267,20037508.3427892439067364,20037508.3427892774343491)\nMapnik LOG\u003e 2014-08-24 19:28:30: ext box2d(0.0000000000000000,-256.0000000000009663,1023.9999999999998863,768.0000000000002274)\nMapnik LOG\u003e 2014-08-24 19:28:30: raster width/height 1024/1024\nMapnik LOG\u003e 2014-08-24 19:28:30: start x/y 0/-256\nMapnik LOG\u003e 2014-08-24 19:28:30: end x/y 1024/768\nMapnik LOG\u003e 2014-08-24 19:28:30: image_ratio x/y 4/4\nMapnik LOG\u003e 2014-08-24 19:28:30: •••••••••••• TARGET TOO BIG ••••••••••••\n\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans w/h 256/256\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans scale x/y 0.0523307/0.0523307\nMapnik LOG\u003e 2014-08-24 19:28:30: ctrans extent box2d(-166326.9735485427081585,6775378.1871980242431164,-161435.0037382915616035,6780270.1570082753896713)\nMapnik LOG\u003e 2014-08-24 19:28:30: source w/h 2/1\nMapnik LOG\u003e 2014-08-24 19:28:30: source-\u003eext_ box2d(-313086.0678560808300972,6731350.4589057825505733,0.0000000000000000,6887893.4928338229656219)\nMapnik LOG\u003e 2014-08-24 19:28:30: ext box2d(-7680.0000000001955414,-5632.0000000011696102,8704.0000000001946319,2559.9999999990254764)\nMapnik LOG\u003e 2014-08-24 19:28:30: raster width/height 16384/8192\nMapnik LOG\u003e 2014-08-24 19:28:30: start x/y -7680/-5632\nMapnik LOG\u003e 2014-08-24 19:28:30: end x/y 8704/2560\nMapnik LOG\u003e 2014-08-24 19:28:30: image_ratio x/y 8192/8192\nMapnik LOG\u003e 2014-08-24 19:28:30: •••••••••••• TARGET TOO BIG ••••••••••••\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspringmeyer%2Fmapnik-raster-overzoom","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspringmeyer%2Fmapnik-raster-overzoom","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspringmeyer%2Fmapnik-raster-overzoom/lists"}