Algorithm for drawing lines and testing individual pixels

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • Hi, I made a line-drawing algorithm similar to Bresenham's (all integer calculations), but this allows you to test individual pixels.

    I made a video tutorial, because while it's not complicated, it's not trivial either.

    Please login to see this media element.

    (yes, my name "Myp" is from "Mate Y Pizza")

    I attached a .mfa, it requires the "surface" extension.

    Edit: I called it "hypothetical pixels algorithm". I also replaced the original video with a new version that fixes several production errors, there were too many to ignore.

    Edit 2: I should have included this in the video; it's the algorithm in the form of a single, multi-purpose loop. It's quite similar to Bresenham's in this form, I suppose because both drag errors:

    Please login to see this attachment.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!