-
Notifications
You must be signed in to change notification settings - Fork 210
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CRTImageDrawer-DedFishy #368
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
It's cool to demonstrate the rasterization techniques with Blot. Could you implement the image processing in a single HTML file? There is a similar example here: https://github.com/hackclub/blot/blob/main/art/BitMap-AdityaPV/Image_to_array_coverter.html |
Unfortunately, I am fairly certain it is not possible to make the Blot accept an image file and just print that out without preprocessing. |
@leomcelroy I finally understood what you meant. I've reimplemented the data generation algorithm in HTML. All you have to do is put an image named |
Can you make sure the files it uses are in the same folder? Also your |
@leomcelroy I've renamed the file. I'm not sure what you mean by making sure the files it uses are in the same folder. If you mean the data it reads, I still don't know how to add those documents along with the file, and including the data in the JS directly makes the file too big. To fix this, I've been loading the raw files from another GitHub repo: https://github.com/DedFishy/Cheese |
Sorry, I'm a little slow in the head lol. I've uploaded the files that I used as examples. |
@leomcelroy It's been three weeks, any updates on this? |
The snapshot is still missing the .png extension. |
@leomcelroy I think you're looking at the txt files that contain the image data. The snapshots have a .png extension: |
Oh, thanks @BrightTheBackpack ! I have just updated that. |
You can order your Blot here. |
This is a combination of two different algorithms. First, I have a Python script that will be given an image and output a text document containing monochrome data of that image. It can be configured to different thresholds of whiteness and blackness. Secondly, the JavaScript that runs on the blot will read this image data, generate a map of lines that represent rows of black pixels, and draw them onto the canvas. Due to how much processing is required to create the final image, I feel that this doesn't count as just "dropping an SVG" on the canvas. I know it's not as cool as the actual freaking raytracer that somebody made somehow, but I think that there's a lot of value in this project.
As for me, I began learning with Python, eventually getting into web development as well. This meant that coming into this, I had a lot of experience with JavaScript and Python. I also have learned Java, C#, SQL, and a few other languages.
Here's Rick Astley (it probably is impractical to draw, but there are other images that would work better):