Omnimaga
Calculator Community => Other Calc-Related Projects and Ideas => TI-Nspire => Topic started by: bwang on June 09, 2010, 02:34:28 am
-
I was experimenting with bitmap file loading today, and the program has reached a semi-usable state, so here it is.
It has no file browsing, so to use it, you will need a 24-bit bmp file with dimensions less than 320x240, renamed to
test.tns and placed in a folder called bmpviewer on the Nspire. It has only been tested with bitmaps produced by the GIMP.
Hopefully I will figure out how to add more features (like browsing) in the future.
Enjoy!
-
mhmm interesting I shall try it out when I get some time. I believe someone did something similar on TI-BANK a while ago but it was never tested on real hardware and is only in french.
Will you eventually support different bmp formats as well as gif/jpg/png?
-
Different bmp formats and gif, maybe.
JPG/PNG, probably no. The compression in JPG is rather complex.
-
aaah ok, sound good still :)
-
That's pretty sweet! It's nice that the Nspire will have an actual bmp viewer. Cool stuff! ^^.
-
Sorry but I can't get it to work :(
I followed instructions in the readme and even tried with both my own pics and your examples, renamed to test.tns and tested one by one and when I run the viewer all I get is a blank screen until I press ESC (which quits back to the Nspire) ???
-
Good stuff, bwang. Sounds pretty cool. Now, lets get a rickroll to work on an Nspire.
-
DJ, did you put them in a folder called bmpviewer? The pictures and the program need to be in the same directory.
-
oh it needs to be in that directory in particular? You should probably make it directory-independent in future versions (even if the images still has to be in the same directory as the app. just not force the app to be in bmpviewer, or at least explain more clearly in the readme (which I read, btw) that the app absolutely needs to be in that directory). Thanks for the tip, though.
-
oh it needs to be in that directory in particular? You should probably make it directory-independent in future versions (even if the images still has to be in the same directory as the app. just not force the app to be in bmpviewer, or at least explain more clearly in the readme (which I read, btw) that the app absolutely needs to be in that directory). Thanks for the tip, though.
DJ,Hopefully I will figure out how to add more features (like browsing) in the future.
Bwang, this sounds neat! Now if only I had an Nspire... ;D
-
Yeah I know, I meant it might be good to clarify that the viewer has to be in one folder in particular to run.
-
If this could work with animated gifs, it would be boss.
-
I think I missed this when it was originally posted. I just tried this out and it works nicely! :) Great job!
-
Many weeks later, I have finally added file browsing (of a sort).
Limitations:
bmps must be 320x240 or less, and 24-bit
bmp names must be of the form *.bmp.tns
bmps must reside in a directory called bmpviewer (the program itself need not reside there)
Controls: At the file selection screen, press RETURN (next to ENTER) to view. Press ESC to exit from the viewing.
The controls aren't very smooth since the keypress delay method I use is terrible so you may have to hold a key down for a while for it to register.
The program is compilable for NON-CAS only, since I don't have the directory listing functions for the CAS.
Next up: scrolling (easy) and images in different directories (I don't know how hard that will be yet).
-
Nice to see updates! :) I may actually be getting a Nspire soon, but I haven't decide yet.
-
Yaay! I just loaded up my calc with epic fail pics.
Why is the keypress detection slow?
-
From the previous page :):
The controls aren't very smooth since the keypress delay method I use is terrible so you may have to hold a key down for a while for it to register.
-
I wasn't clear, I really meant why is this keypress method used?
-
Because I haven't figured out an intelligent way to do it, so I just refresh the screen 20 times each iteration of the loop.
-
Doublepost is bad, I know, but here's a minor update. It now only refreshes 3x instead of 20.
Also, you now click at the file selection screen, instead of pressing RETURN.
-
It isn't as bad if it's made within the forum rules ;) (which is currently the case, since it has been more than one hour for a project update :P)
I'll have to give this a try again at one point. Last time I didn't get it to work, but I think I started to figure out
-
Yet another update! Press +/- when viewing to change the contrast.
-
A bugfix update: the program now calls free() appropriately at the end of main() to free the malloc'd blocks of memory. This should prevent some random crashes I've been getting.
Also, attached some screenies. We all love screenies, right? :)
-
Very nice bwang!
Great job :)
-
Wow, excellent job! Nice work bwang! ;D
-
Darn it must look quite nice on calc.
-
Heres a nice screenshot:
(http://i974.photobucket.com/albums/ae226/apcalc/bmpviewer.gif)
It looks great on hardware too!
-
Nice, even better with the dithering ^^
-
I think that dithering was from the screenshot program-it is dithered in the border of the emulator.
-
Yeah, I think that was caused by Windows Snipping Tool. It is like that on all screenshots I take with it.
-
Still, actual dithering wouldn't be too hard to implement.
-
oh that's why prbly then x.x, my bad
-
I just had another idea-256 level grayscale!
-
:O Thats so awesome Bwang! Heh nspire built in greyscale is making us all warm and fuzzy inside :]
-
Will we be able to see the difference between 64-level and 256-level?
Especially on the nspire's screen :P not to discourage.
-
Actually, the transition between the 16 shades of grayscale on the Nspire's screen is not that great. It is almost like there are only four levels with several close shades in each level. Although the still look nice, I have not found a pic that looks better on hardware than on the emulator.
-
Ouch that kinda sucks. I guess it's like the regular 83+ with more than 5 level grayscale x.x, where we only saw like 60% of the shades.