Alternatively, join us on Discord.

[TI-83+/84+] Draw (Axe)

Started by Snektron, February 14, 2015, 04:25:53 pm

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Snektron

February 14, 2015, 04:25:53 pm Last Edit: March 06, 2015, 06:48:35 am by DJ Omnimaga
One of my friends asked if i could make a draw program, so i did :D.

Features:
  Menu's:
- Mode menu
    - Select actions/drawing modes
    - Open with [mode]
    - Navigate with [up]/[down]
    - select with [2nd], [mode] or [enter]

  - Size menu
    - Set pen size
    - Open with [alpha]
    - change size with [up]/[down]
    - Select with [alpha]

  - Pattern menu
    - Set drawing pattern
    - Open with [X,T,θ, n]
    -  Navigate with [up]/[down]
    - Select with [2nd], [X,T,θ, n] or [enter]

  Actions/Drawmode's
    - Pen:
      - Draws with the selected pattern and size
      - draw by holding [2nd]
      - Set size with [alpha]
    - Eraser:
      - Clears with the selected size
      - erase by holding [2nd]
      - Set size with [alpha]
    - Quit:
      - Exits the program
    - Clear:
      - Clears the image
      - Activates immediately and selects pen after activating
    - Line:
      - Draw a line
      - Press [2nd] for point 1 and a second time for point 2
      - Press [Del] to cancel
    - Invert:
      - Inverts the image
      - Activates immediately and selects pen after activating
    - Circle:
      - Draws a circle
      - Press [2nd] to set the origin and a second time for a point to specify the radius
      - Press [del] to cancel
    - Flood:
      - Floods an area with the selected pattern
      - Activates when [2nd] is pressed
    - Save:
      - Save current image to a pic var
      - Displays an error message when there is too little free ram
    - Open:
      - Open pic var and copy to image, overwriting everything
      - Diplays an error message when the pic var is undefined

  Misc
    - Hold [Y=] to speed up the cursor
    - When quitting, the current image is saved to an appvar and loaded when the program is reopened

Credits to DarkestEx for the pic pixel test algoritm and to MGOS for the flood fill
Download zip contains:
  - Draw.8xk -- the main app
  - Draw.8xp -- the axe source
  - readme.txt -- the readme

This was intended as App but will probably work when compiled as Program, though you will have to change the name
as it contains lower case characters.
If you find any bugs or have any ideas i should add let me know.
Have fun with it :P
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


DJ Omnimaga

I don't have much time to test it now, but do you have a screenshot? I know there are many paint programs for the 84+ series so I am curious about what this one has to offer that others lack :) The flood filling feature seems like a great addition, though.

Is there grayscale support?

One issue that many paint programs had in the past was the very large amount of RAM they took during runtime.

Snektron

Quote from: DJ Omnimaga on February 14, 2015, 04:33:50 pm
I don't have much time to test it now, but do you have a screenshot?


Oh right. i knew i forgot something :3=

Quote from: DJ Omnimaga on February 14, 2015, 04:33:50 pm
Is there grayscale support?


Sadly, no. I already had to use all the freeram areas for the rest, especially the floodfill tool
uses a lot.

Quote from: DJ Omnimaga on February 14, 2015, 04:33:50 pm
One issue that many paint programs had in the past was the very large amount of RAM they took during runtime.


While i use allmost all the freeram areas, it only uses the appvar to save the current image as temporary
ram.
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


DJ Omnimaga

February 14, 2015, 04:44:40 pm #3 Last Edit: February 14, 2015, 05:06:41 pm by DJ Omnimaga
Aah ok that seems good about the RAM. Back then I never really used on-calc image editors because to run them I needed like 8 KB of RAM, so I hated to have to archive my entire game then unarchive the drawing utility and vice-versa, especially when I used a regular 83+ with lots of garbage collects (and the resulting battery bill). Free RAM areas helps a lot at least. How much free RAM does flood fill use to fill a 24x24 area by the way? What if the image is very complex like if you try to flood fill a maze?


EDIT: Also my 2000th post *.* (this was twice faster than on Omnimaga)

Snektron

February 14, 2015, 04:59:13 pm #4 Last Edit: February 14, 2015, 05:10:12 pm by Cumred_Snektron
It uses a fixed size algoritm i found on omnimaga.org :3=. So it doesn't matter how
complex the area is, it will always use 3x768 bytes (2x768 for the algorithm and another 768 to mark
the changed pixels for the pattern)
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


DJ Omnimaga

Erm, Omnimaga.net doesn't exist. :P But I see. I wasn't sure if smaller areas used less RAM. I assume more complex areas must be slow though, but it's understandable on a 6 MHz calc. Even on a 100 MHz computer flood filling simple areas was rather laggy.


EDIT: Woah I just saw the screenshots. Looks good so far, especially the sliding menu :D

Snektron

Thanks :D
I've made a few gifs of filling complex areas.
Indeed it takes a few sec, but not too too long :)
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


DJ Omnimaga

That isn't particularly complex. By complex I meant something like this starting from the middle in the white areas :P


Snektron

February 14, 2015, 05:22:59 pm #8 Last Edit: February 14, 2015, 05:44:23 pm by Cumred_Snektron
i'd fill it up... if i knew how to convert png's to 8xi's :3=
EDIT: Well i can just send them to my calc and get them back, only it doesnt convert properly >.<
EDIT2: A finaly got it :D
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


DJ Omnimaga

Wow that seems pretty fast actually! O.O

Also I think SourceCoder can convert images to hexadecimal that can be used in Axe.TokenIDE can probably do it too. Otherwise I'm sure there are 8xi to hexadecimal converters on ticalc as well.

Keoni29

Wow this is a really nice paint program. I like the animation of the tool menu :D
If you like my work, why not give me an internet?

matrefeytontias

I especially like the flooding feature. How do you achieve it ? Do you use a flood-filling algorithm, or is there some trick you use ?
My TI games (some got their own article on non-calc websites !) : http://www.ticalc.org/archives/files/authors/112/11202.html

My moozik (100% free metal) : http://www.soundcloud.com/matrefeytontias

Snektron

As i said earlier, i didn't make the algorithm myself :P
here is a link to the topic.
I did modify it a bit to allow for the patterns :)
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


matrefeytontias

Ah okay. Thanks for the precision.
My TI games (some got their own article on non-calc websites !) : http://www.ticalc.org/archives/files/authors/112/11202.html

My moozik (100% free metal) : http://www.soundcloud.com/matrefeytontias

DJ Omnimaga

March 05, 2015, 07:19:33 pm #14 Last Edit: March 05, 2015, 07:22:40 pm by DJ Omnimaga
By the way, in the last screenshot, I was wondering what causes the screen to go blank while it's flood-filling? Also should I move this topic to the Downloads section?

Powered by EzPortal