Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 41
Registered: ‎11-17-2013
My Device: Blackberry Simulator 10.2
My Carrier: Telcel

How to allow the user to handwrite in a photo

Hello everybody!

 

I want to allow to handwrite in a photo to the users, I mean, once they had taken a photo, I want they to be able to draw over that picture, and if it's possibler, to show a palette with different color and other available tools.

 

I'm developing with Cascades, but I can't find something like that in the documentation (BB10).

 

Well, I think this is possible but I don't know where to start. I need some help. Any suggestion.

 

Thanks!

Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: How to allow the user to handwrite in a photo

[ Edited ]

You will need to write your own editor effectively.

You can overlay either an ImageView or a Foreign WindowControl over the Image capturing the touch events to draw a bitmap,

 

http://developer.blackberry.com/native/reference/cascades/bb__cascades__foreignwindowcontrol.html

 

then on some action from the user indicating that they wish to save you can use the QT graphic APIs to merge the two images together,

 

http://qt-project.org/doc/qt-4.8/qimage.html

http://qt-project.org/doc/qt-4.8/qpainter.html

 

 


If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.
Developer
Posts: 6,152
Registered: ‎07-05-2012
My Device: Playbook, Dev Alpha C, Z10 LE, Z30
My Carrier: Orange

Re: How to allow the user to handwrite in a photo

It's just occurred to me that you could do the second part by displaying the image with the overlay without any chrome, say a sheet, and then take a screenshot.

 

It's the first part, the editor itself, which is the trickier bit any way.

 


If you've been helped click on Like Button, if you've been saved buy the app. Smiley Happy

Developer of stokLocker, Sympatico and Super Sentences.