Hello, i need help with a project i am doing, basically i have created a script that whenever you press the mouse button it create a new line renderer, and until you put your mouse up it will create a new points, so you can draw things with it. Anyway i would like after you press a key stop/start drawing that it identifys the shape of the thing that the line renderer built. Kinda like this game : http://www.nitrome.com/games/magictouch/
P.S: i am sorry for bad grammer, English isn’t my first laungage
FYI, Many people won’t be able to see that game because it’s Flash, which is now being disabled by default more and more on browsers. So I’m just going by your description.
Shape detection isn’t easy, and certainly not something you’ll be able to figure out from a forum post - we’re talking probably weeks of work to figure it out. My advice would be to search for an existing detection algorithm already written in C#, and then run your points through that.
Doing some quick googling I came up with a Hough Transform:
I haven’t read through the entire thing, but this is where you would probably want to start if you try to code it yourself. you might also find some free libraries implementing this.
Thank you all,after i did some resarch, i found out about P dollar ,a open source shape recognition project, and i searched “P dollar unity C#” and it came up with this : Unity P Dollar gesture recognizer | Aymeric Lamboley