Replacing Photoshop with NSString
cocoamine.net
cocoamine.net
I also created this page: http://asciimage.org, with my friend @mz2. There is a simple editor as well called ASCIImage Super Studio.
And check out Monodraw, I love it!! http://monodraw.helftone.com
(see comment here: https://news.ycombinator.com/item?id=9240942)
I didn't quite understand how the single points worked. It seemed to me that your definition for, say, 3 single points was the same as a triangle. How does it know which is which? Or do the curves have to be closed?
So, 1-2-3 5-6-7 = 2 triangles
But 1 3 5 = 3 points
I'm not 100% sure I'll really get regular use out of it, but I'm tempted to buy a copy anyway, mainly because I think you deserve reward for the effort that's obviously gone into it.
If I could wish for anything it would be this: is it even remotely possible for shapes from a plain text file to be interpreted as monodraw objects, rather than just one big text field?
Thank you for your kind words :) I think the business model has been inspired from the indie scene over the years. Simply put, I do not want to charge customers before the product is of quality that I deem adequate. That's why the beta is freely available without any restrictions. If anyone feels generous enough to support us before v1 ships, they get 40% off in return.
Yes, I plan to provide ample warning over email, Twitter + our blog.
> I'm not 100% sure I'll really get regular use out of it, but I'm tempted to buy a copy anyway, mainly because I think you deserve reward for the effort that's obviously gone into it.
I greatly appreciate the support. Even if you don't purchase it, knowing that you like the app is enough to motivate me to further work on it. From a financial perspective, every purchase counts - as an indie, my livelihood depends on the apps I make, I don't have any other income.
> If I could wish for anything it would be this: is it even remotely possible for shapes from a plain text file to be interpreted as monodraw objects, rather than just one big text field?
That has been requested a few times and it's something that I'm considering. It's not very high on my list but if I receive enough requests for it, I'll bump up it. I don't have a roadmap that is set in stone and I'm pretty flexible when it comes to the development of Monodraw - I'm willing to listen to the users.
I guess a Windows or Linux version is never going to happen? I'd love to be able to run this.
I'm a supporter of all platforms but I do not have any cross-platform desktop GUI skills.
> Once the beta period ends, your copy of Monodraw would expire and you would not longer be able to use it.
Does this apply when you purchase the beta?
It is also inspiring for ascii to graphics representation utilities as well. I wonder if this could be extended to make shape holder content, where in the art you can specify the stretch locations and protected zones. (kinda like how you can do a boxy like configuration on images for dynamic content inside via CSS3)
It's a brilliantly simple but effective ideas. Very tempted to use it in my next project.
It seemed like the author's original problem was having to do so over and over to deal with different pixel densities, but this is exactly the sort of problem SVG exists to solve. I do admire the technical skill, I just don't get the attraction of compiling ascii art into a vector image for anything practical, for much the same reason that I wouldn't want to use Photoshop or Illustrator to write code.
Maybe because it is (or at least can be, the more advanced usages become less so) tolerably self-describing in that you can readily see what it is producing, in a way that SVG isn't, while still being source-control and diffing-tool friendly text?
For small things like its intended uses, it fits well within coding tools and workflows, and avoids separately documenting and coding the art.
This kind of reeks of "If your only tool is a text editor, every problem looks like text".
Just as with programming, polyglot programming has value, but switching languages within a project had a complexity cost that isn't always justified even when for dinner task taken alone a different language is marginally superior.
For some applications, having something be both can be helpful.
Because programmers typically prefer typing in ASCII to drawing :-)
There has to be something wrong with SVG when people even thinks drawing icons in this day and age in ASCII is a must do.
Pixel alignment, asset management and being a one-man shop allowed more excentricities is what justifies this, for small icons with simple features (a few straight lines or rects).
you can probably google and find loads, but to get you started a little...
the main one I have experience of is 'cairo' which is quite a powerful library for all kinds of drawing things. there is an android build config (although its a bit old now) here: https://github.com/anoek/android-cairo - it is however not great for iOS or OS X...
i've not used, but heard good things about 'sugar' as well: http://sourceforge.net/projects/libsugar/
i do wonder how long it will take for Apple to come around to mipmapping and trilinear filtering to tackle their very normal problem of multiple resolutions.
it seems to work well enough in all their use cases for the last 20 years or so... :)
https://en.wikipedia.org/wiki/X_PixMap#Comparison_with_other...
· · · · 3 · · · · · · · · · · · · ·
· · · · · · · · · 7 · · · · · · · ·
· · · · · · · · · · · · · · · · · ·
· · · 1 3 · · 1 · · · · · · · · · ·
5 · · 5 · · · · · · · · · · · B · ·
· · · · · 2 · · · 7 · · · · 2 · · ·
· · · · · · · · · · · · · · · · · ·
· · · 1 · · · 1 · · · · · · · · · ·
· · · · · · · · · · · B · 9 · · · ·
· 8 · · · 8 · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · ·
· · · · · · · · C · · · · · · · · ·
· · · · · · · · · · · · · · · · · 9
· · · · · · · · A · · · · · · · · ·
· · · · · 2 · · · · · · · · 2 · · ·
· · · · C · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · A · · · · ·
But if you split it into two diagrams it becomes much more clear what's going on: · · · · · · · · · · · · · · · · · · · · · · 3 · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · 7 · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · 1 · · · 1 · · · · · · · · · · · · · · 3 · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · 5 · · 5 · · · · · · · · · · · B · ·
· · · · · 2 · · · · · · · · 2 · · · · · · · · · · · · 7 · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · 1 · · · 1 · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · B · 9 · · · ·
· · · · · · · · · · · · · · · · · · · 8 · · · 8 · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · C · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · 9
· · · · · · · · · · · · · · · · · · · · · · · · · · A · · · · · · · · ·
· · · · · 2 · · · · · · · · 2 · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · C · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · A · · · · ·
Especially if you name them. Here, "body" and "legs". Edit: add spaces for clarity. Edit2: use cdot. · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · 1 · · · · · · 1 · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· 3 · 1 · · · · · · 1 · 4 · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · A · · A · · · · ·
· · · 1 · · · · · · 1 · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · C D · · · · · ·
· · · · · · · · · · · · · · · · · · · A · · A · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · B E · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· 6 · · · · · · · · · · 5 · · · · · · · · · · · · · · ·https://twitter.com/mz2/status/579080005453398017
Your lock example from above is shown here:
All the best,
Additionally, XPM sucks (I'm aware), and I've been wishing for a significant update to it for a long while :P
For the actual drawing, I'm wondering if the cairo library and drawing model would help. It effectively gives you the move-to line-to curve-to drawing, with some additional capabilities. A simple script around cairo seems like it would cover many more cases, and then this ASCIImage mechanism will help generate those scripts.
Specific features that would make sense to have available rather than drawing art in an image editor:
Line width, to draw the chevron without having to draw two adjacent lines.
Dotted/dashed lines.
DRAW "BM+3,+1 R1 F4 D1 G4 L1 U1 E3 U1 H3 U1"
You could change the scale with "Sn" so you could draw any size, and there were commands to fill shapes etc.There was a similar language for music as well, they were both nice little DSLs.
Brush from a shape (like in the example chevron):
. 2 3 . . . .
. 1 4B# . . .
. . # # # . .
. . . # # # .
. . . # # 5 .
. . # # # . .
. # # # . . .
. # 6 . . . .
Brush from single line stroke (like a 'calligraphic pen'): . 1b# # # # 2
1 # # # # # .
. . . . # . .
. . . # . . .
. . # . . . .
. 3 # # # # 4
# # # # # # .
This would also ease creating complex strokes with rounded corners: with ellipses or other rounded shapes as a brushes.OT but why do you need three different and not just go with the 3x which you scale down?
Of course, in the context of the original ascii art icons, that level of polish doesn't matter.
Circle Square
..#1#.. 2#####2
.#####. #######
####### #######
1#####1 #######
####### #######
.#####. #######
..#1#.. 2#####2I wish there was an editor with an interface as great as (say) Pixelmator's, but with an optional script window that let you write and edit the code for your vector graphics if you need to. Something PostScript powered, maybe? (PaintCode does something like this, but it's more of a one-way, vector-to-code mapping. Bloom promises to do a lot of this, but I haven't used it in a while.[1])
Indeed you shouldn't! That's why all serious image manipulation programs have this capability built in.
Most of them also let you write your own plugins for those cases where you need more than what the interface provides.
I think going to all-code drawing is more limiting than freeing. It seems more like a case of having a hammer and seeing that everything can be made to look like a nail.
As for plugins, that's not really integrated into the workflow in the way I'm envisioning. I shouldn't have to write heavy code just to experiment with a quick artistic idea! Think web development. It should be as simple as editing a JS file and refreshing the page.
1 2 3 4 5 6 7
a · 1 2 · · · ·
b · A # # · · ·
c · · # # # · ·
e · · · 9 # 3 ·
f · · · 8 # 4 ·
h · · # # # · ·
i · 7 # # · · ·
j · 6 5 · · · ·
It is textually 58 characters of data: 7 ·12·····A···············9·3····8·4·········7······65····
(Axis headers and whitespace ommited, two characters added to keep the row width information.)It is almost the same size of the smallest possible SVG polygon of similar shape consisting of 59 characters:
data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg"><polygon points="0,0 2,0 5,3 5,5 2,8 0,8 0,6 2,5 2,3 0,2"/></svg>
Using even the simplest coordinates notation it could look like 24 characters: a2a3e6f4j5j6i7f6e9b2f cf
(Three characters added to keep "Close and fill" information.)Smallest 7×8 px PNG with the same image is 96 bytes large:
data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAIAQMAAAAPyndFAAAABlBMVEX///8AAABVwtN+AAAAFUlEQVQI12NIYChgsGCQAUILICsBABJQAkm4hriIAAAAAElFTkSuQmCChttps://twitter.com/mz2/status/579283430858465280
It could of course be rendered to a PDF or TIFF or other Cocoa supported image file format, consider that just a 5-minute hack to demonstrate the idea.
http://tanehp.ec-net.jp/heppoko-lab/diary/artist_mode_test.p...
I added the js port on asciimage.org. There is a Go version as well I will link to.
I'm considering using this to redesign the UI on one of my products. Hiring a designer is a huge pain, but this is a viable alternative.
... which just about sums up the Objective-C experience
When I first started learning it, I absolutely _hated_ it. With a burning passion.
It is probably now my current favourite and most productive language.
I seem to very rarely write buggy/poor/badly structured code and almost never hit compiler errors/hard crashes unless they are something relatively obscure. It's quite common for me to write 1k+ lines of code, hit build and have exactly what I wanted compile & work pretty much first time.
That's kind of the point though. If you want something on the stack, you write plain old C structs or work with primitives. There's plenty of this happening throughout the cocoa frameworks. On the other hand, if you find yourself writing C structures to the heap in objc, you're probably wasting your effort.
It has gotten a lot better thanks to tagged pointers: https://www.mikeash.com/pyblog/friday-qa-2012-07-27-lets-bui...
Objective C is mostly used for UI code, and I think it's a fantastic language for that, with its Ruby-like weak typing and strong metaprogramming capabilities.
Productivity wise (i.e. making something and shipping it), it's a fantastic language.
You do realise that Objective-C was used because iOS is effectively OSX. And OSX is effectively NextStep. Apple is a big company sure but rewriting your entire SDK is never a quick or simple endeavour. So of course when the iPhone came out Objective-C was going to be used.