I am not sure if my title fits what I am asking about but here it is...

I have seen flash games where the player can actually draw objects.
Meaning they have like a pen cursor in the game, and they can just start creating vector art. I have a game in mind where it might be a cool feature to have the user draw a few things. I bet this is a heavy subject so I am not asking for every bit of code I'd need to create something like this, but I have searched quite a lot for anything remotely brushing on this subject and clearly I have no idea what I should be punching into google. If anyone can point me in the right direction I would appreciate it.