I got a bit bored today and because of that, I decided to do this:

The image looks a lot better from a distance!

In order to do this, I took an 18MP image (which in hindsight was a little excessive for the job!), then I cropped it in GIMP. After that, I used PIL (Python Imaging Library) to convert the image to B&W with dithering. Then, I took the image back into GIMP, resized it and transferred it to my calculator with TI connect. Sorted!

I'll try and post some other images soon.

I think I will also try and turn the code I used into a utility so others can use it at some point, so watch this space!
Might I assume this might tie into WAti?
Probably not, ordelore since this uses TI pic files. It was more just proving that I could do it.

It might be an option for WAti, but really there are items of higher priority on the WAti development to-do list.
Another option would be to throw the photograph at SourceCoder. It will take care of thresholding and resizing any image at most 320x240 for you and allows you to export as a .8xi (or a .8ca/.8ci if you have a TI-84+CSE). Smile Anyway, nice.
I quickly and recklessly wrote this WBMP viewer in BASIC, which draws a hex WBMP image onto the graphscreen. This could have a use in WAti, as the hex images could be sent as strings over Calcnet.

Here's the unoptimized code:

:If "1"=sub(Str2,8(Q-1)iPart(1+A/8)+P,1

In this code, variables X and Y can be replaced with P and Q, as I made that change to the final loops at the last minute as access to the graph screen was overwriting X and Y. Str8 contains the hex WBMP image, according to Wikipedia's description of the format. Images must be smaller than 255 pixels on either dimension as my code assumes the size of the image is one byte. Also, the loop that makes L₂ can be eliminated and the image size calculated directly from L₁. And finally, the first two bytes (four nibbles) are ignored, so you can deviate from the standard and use those bytes to indicate if a picture doesn't fit in a single gCn frame.
I haven't tested this on anything except the image 00000303A040A0, as I'm too lazy to make larger images. But it should work.
Thanks very much, CVSoft, I'll have a look at that soon Smile

Here's another one I did. My cat, Frankie:
Tip: you can do all the image manipulation you need (other than converting to a file format you can send to your calculator) in GIMP. As I'm sure you're aware, GIMP has resizing and cropping tools. But you may not be aware of the Image > Mode > Indexed... dialog, which allows you to convert an image to an indexed palette (black and white is a built-in palette), as well as specifying no dithering, positioned dithering (which is what you've been using), or one of two variants of Floyd-Steinberg dithering.
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum