I've run into this problem and I've known about it for ages but noticed that for some reason it has never been posted, but DrawLine acts different on different platforms. This is definitely something that should be fixed so that I don't have to write these ridiculous workarounds. Like for instance with HTML5 and GLFW, I have to add 0.5 to the x and y. For HTML5 alone, I have to do a separate calculation from the one below because otherwise it doesn't come out correctly on all platforms.
Try compiling this to different platforms and notice how it has different results on many of them. Flash renders what I expect. GLFW, HTML5, and XNA all give off different results from one another.
Update Okay, so DrawPoint also acts differently on GLFW at least.
|