Page 1 of 1
peut-on dessiner avec une brosse?
Posted: Wed Apr 22, 2015 9:38 am
by sinisrus
Hello,
can you draw with a brush?
Have you exemple for this?
Thnak you
Re: peut-on dessiner avec une brosse?
Posted: Wed Apr 22, 2015 9:24 pm
by airsoftsoftwair
Code: Select all
LoadBrush(1, "test.png")
DisplayBrush(1, #CENTER, #CENTER)

Re: peut-on dessiner avec une brosse?
Posted: Thu Apr 23, 2015 12:03 pm
by sinisrus
no that's not it: - /
I want to draw with a brush to make drawing as dpaint or PPaint?
I want to do a drawing program with hollywood
I can draw with the mouse I use
Line()
is it possible to draw with brush and mouse?
Thank you
Re: peut-on dessiner avec une brosse?
Posted: Thu Apr 23, 2015 1:13 pm
by Bugala
Yes, it is possible, just more trouble in fixing it to work the way you want, small example:
Code: Select all
If IsLeftMouse() = true then displaybrush(1, mousex(), mousey() )
by other words, if left mouse button is down, then it will display brush to current mouse x, y location.
However notice, that when you use DisplayBrush command, nromally it doesnt yet draw anything to the picture, but it is rather attaching a movable picture to the picture. That if you deside to display the same brush (or actually layer) in some other location, it will remove the original brush picture and move it to new location.
To achieve it actually drawing that brush to the picture, you need to for example make a screensized layer that you keep altering by drawing another layer inside it. This is also the way you can save that pciture, since if i correctly remember, you cant actually save a picture in Hollywood, but you for example make copy of the picture to a layer, and save that layer (as a picture)
Re: peut-on dessiner avec une brosse?
Posted: Thu Apr 23, 2015 4:52 pm
by sinisrus
@Bugala
thank, I already try the problem is that it draws only point is not continuous line. :-/
Re: peut-on dessiner avec une brosse?
Posted: Thu Apr 23, 2015 11:31 pm
by Bugala
If i understood right what you meant, then the point is that you need to save or copy the brush each time you make a change to it.
There might be better method to do this, but I think it goes about so that:
1. DisplayBrush(1, x, y)
2. SelectLayer(1) - - - Selects brush 1 as the place where everything will be drawn to.
3. If Isleftmouse... then DisplayBrush(2, x, y) - - - This will draw brush 2 into brush 1. - - - Suppose you have brush 1 sized 200x200, then you have brush two sized 50x50, you could draw brush 2 into location 75, 75 to have it in center of brush 1.
4. ConvertToBrush(#LAYER, 1, 1) - - - This makes the brush 2 become permanent to brush 1, instead of just movable object.
5. SelectLayer(1) - - - to select the new brush which have been drawn to
6. isleftmouseagain - - - to get it to paint next displaybrush and make it permanent again by repeating this procedure.