Page 1 of 1

[C++/Lua] Whiteboard Library

Posted: Wed Feb 24, 2010 4:06 pm
by Montyphy
A whiteboard library providing functions for drawing various shapes and objects. Useful for debugging or whiteboard communication.

Project page:
Shinkutanku :: Defcon AI - Whiteboard Library

Download:
C++ - draw.h, draw.cpp
Lua - draw.lua

License:
Released under the MIT license

Documentation:
http://docs.shinkutanku.com/defcon/draw

Sample image:
Image

C++ example usage:
draw_bot_sample.h
draw_bot_sample.cpp

Lua example usage:
draw_main_sample.lua

Posted: Wed Feb 24, 2010 4:29 pm
by roflamingo
<yoink>

It's good for debugging!...already tired of x's, boxes, and o's

Posted: Wed Feb 24, 2010 4:34 pm
by elDiablo
That's actually quite cool!

Posted: Wed Feb 24, 2010 5:07 pm
by Ace Rimmer
Can you believe I was actually going to try to create the entire alphabet in Kremlin format using the whiteboard, but this is just crazy. :P

Thanks!

Posted: Wed Feb 24, 2010 5:16 pm
by Montyphy
Ace Rimmer wrote:Can you believe I was actually going to try to create the entire alphabet in Kremlin format using the whiteboard, but this is just crazy. :P

Thanks!


I was tempted to do the same. :P Would only require a modification of the teapot method(s).

Posted: Wed Feb 24, 2010 5:38 pm
by martin
I've been considering making a whiteboard library which would do two things:

1) Have persistent whiteboard objects, deleting an object will clear the entire board and redraw the old ones (no erase functionality for bots unfortunately)
2) Parse a font file, so I can draw text without hardcoding all the characters

However, while number 1 would be useful, it's not *that* useful, so I don't think I can be bothered. And I can't find any good info on how font files are structured, and proper research into this is beyond the scope of how much I can be bothered ;)

So I think I might just use this one...Thanks Monty :D

Side note: With all this talk in this forum, and an evident knowledge of programming, when are you gonna make a bot? ;)

Posted: Wed Feb 24, 2010 9:45 pm
by Montyphy
Added the C++ version I wrote prior to making the Lua version.

martin wrote:1) Have persistent whiteboard objects, deleting an object will clear the entire board and redraw the old ones (no erase functionality for bots unfortunately)


Yeah, it's a shame the bots can't use erase. Could try requesting it I suppose.

martin wrote:Side note: With all this talk in this forum, and an evident knowledge of programming, when are you gonna make a bot? ;)


I am tempted :P

Posted: Wed Feb 24, 2010 9:49 pm
by Ace Rimmer
Montyphy wrote:
martin wrote:Side note: With all this talk in this forum, and an evident knowledge of programming, when are you gonna make a bot? ;)


I am tempted :P

I was tempted to offer somebody with proper coding skills $ for a bot, that would do what I am trying to accomplish. Of course, there'd be a standard NDA. :P

I still toy with the idea occasionally, but am put off by the probably 'too' high cost and lack of learning opportunity.