FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Rendering of single pixels icons no longer functions the same way · Issue #218 · SharpMap/SharpMap · GitHub

Repository navigation

Rendering of single pixels icons no longer functions the same way  #218

Description

Between v0.9 and v1.1 of SharpMap the rendering function for a vactor layer has changed from the passing integers into the g.DrawImage function to passing doubles.
This means that icons aren't rendered exactly on single pixels so if you have a 1 pixel thick cross icon instead of it being rendered at X - 600, Y - 550 it gets renders at X - 600.1213, Y - 550.4871. Once these are drawn it looks like some kind of Anti-Aliasing is being applied but in reality the image is trying to be drawn as one pixel across two pixels. If that makes no sense at all there is an image that might make so more sense.

The image is a little over exhaggerated and in reality the its not as light.

The 'quick fix' for this is to override the Render method and pass integers into the g.DrawImage method.

Not sure if this was an intented outcome of the change or if there should be an property in the vector layer or a vector style to not render across pixels and instead truncate or round the x, y value to the nearest integer?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions


      Back | FazBrowse Home | New Git URL