daihase / Sketch

Sketch have a lot of basic functions to develop a drawing app for iPhone. Anyone can easily create drawing iOS Application.
MIT License
337 stars 57 forks source link

How can I color my sketch drawing using Pen tool inside the shape boundaries? #8

Closed MrPradip closed 5 years ago

MrPradip commented 5 years ago

I want to colour the drawing using pen tool .And if the shape boundary is closed while colouring ..the colour should not come out from the boundary.. The feature is exactly like the fillcolour thru paint bucket.. Is it possible here?

daihase commented 5 years ago

Do you assume something like a mask function?

Currently sketch draws shapes such as Rect, and even if you try to paint with Pen tool on it, the line will be overflowed and painted.

MrPradip commented 5 years ago

Exactly creating a mask or some other way.. Any idea how to achieve it? @daihase

daihase commented 5 years ago

@mrpradipkumar46 In fact, that algorithm is difficult. First of all, how do you decide the mask? In order to clip, boundary path of the mask is also required. If complex graphics and stamps are nearby, the difficulty level is higher.

As a current implementation, incorporating them is somewhat difficult for me. Sorry... 🙇

MrPradip commented 5 years ago

@daihase I am using FloodFill Algorithm and working on customising it.. lets see if I could able to get the desired output.. Anyway thanks for cooperating.. am closing it ..