paintbrush

A place to share your brush
User avatar
maninmachine
 
Posts: 132
Joined: 28 Sep 2013, 06:20

paintbrush

Postby maninmachine » 07 Mar 2017, 02:47

Congratulations on the recent update! The amount of work put into it is astounding.

Here's a simple paintbrush made by swapping the color mixing from Smudge Colored to Smudge Rake (wasn't quite the same). Added a distance factor, so the applied color diminishes over time but it still smudges. Emulates oil painting? Changed the name of color alpha to Load (like loading paint).

It needs another slider added to change the rate at which the load decreases.

Will add and upload sample after I get a chance to use it. :p

Thank you for all your hard work!!

:bug: bsl extension is not allowed in post attachments

Image
Attachments
mixer4.zip
(20.07 KiB) Downloaded 83 times

User avatar
u2bleank
 
Posts: 948
Joined: 11 Jun 2012, 10:41

Re: paintbrush

Postby u2bleank » 08 Mar 2017, 09:21

Great !
It's nice to see user customization ;)

User avatar
maninmachine
 
Posts: 132
Joined: 28 Sep 2013, 06:20

Re: paintbrush

Postby maninmachine » 09 Mar 2017, 08:11

:draw: some changes
Attachments
paintbrush v2.zip
(10.65 KiB) Downloaded 70 times

User avatar
maninmachine
 
Posts: 132
Joined: 28 Sep 2013, 06:20

Re: paintbrush

Postby maninmachine » 16 Mar 2017, 01:39

Is there a way for color "auto picking" to apply to final location? (sweet feature, btw) Would like to pull color from canvas per stroke.


render test:
Attachments
Machu Picchu test small.jpg
Machu Picchu test small.jpg (124.56 KiB) Viewed 2310 times

User avatar
u2bleank
 
Posts: 948
Joined: 11 Jun 2012, 10:41

Re: paintbrush

Postby u2bleank » 16 Mar 2017, 09:49

Is there a way for color "auto picking" to apply to final location?


:? Hum I dont see what you mean.
the Auto picking will get the "Merged" color ( the color you see on the screen ) at the start of the Stroke.
If I understand you want an option to retrieve the color at the end of the stroke... but it's not possible to know this color before you finalize your stroke... Can you give me more detail on what you want to achieve.

User avatar
maninmachine
 
Posts: 132
Joined: 28 Sep 2013, 06:20

Re: paintbrush

Postby maninmachine » 17 Mar 2017, 02:50

You've got it. :up: Really, I was wondering if the end of a stroke could be treated as an event that can update parameters. In this case it would be color; at stroke end set new color to last merged color. Also, if no color was preset, brushing the canvas or a palette would pick up some color. Mixing on screen would be easier.

We could use it to have gradual effects, too. "Load" in this brush, for instance. At stroke end, read stroke length, diminish load percentage accordingly. Clamp percentage set this way to a minimal value to simulate amount of paint the brush might typically carry from the canvas.

Randomizing effects could be great when using textures (or bristle density in this one) if you don't want a stenciled look between strokes.

User avatar
u2bleank
 
Posts: 948
Joined: 11 Jun 2012, 10:41

Re: paintbrush

Postby u2bleank » 20 Mar 2017, 17:35

Really, I was wondering if the end of a stroke could be treated as an event that can update parameters. In this case it would be color; at stroke end set new color to last merged color.


Ok I see. But it's seems to me introducing a complex system to achieve somehting to can be made with the EyeDropper or the AutoPicking.


Also, if no color was preset, brushing the canvas or a palette would pick up some color. Mixing on screen would be easier.


You can do that with a BSL which look like that :

Code: Select all
globals{
   float4 colorVoid ;
}

float4 main( idatas i){
   float4 c = i.color ;
   c = lerp( colorVoid, c, saturate(10*c.a) );
   return c ;
}



We could use it to have gradual effects, too. "Load" in this brush, for instance. At stroke end, read stroke length, diminish load percentage accordingly. Clamp percentage set this way to a minimal value to simulate amount of paint the brush might typically carry from the canvas.


it's also already possible with something like this :


Code: Select all
float4 main( idatas i){
   float4 c = lerp( i.color, i.color*float4(1,1,1,0), saturate(0.005*toDrawSpace(i.dist)) );
   return c ;
}


Randomizing effects could be great when using textures (or bristle density in this one) if you don't want a stenciled look between strokes.


I often use the i.nbUserStroke as a seed for your Random effect to have each stroke unique.

User avatar
maninmachine
 
Posts: 132
Joined: 28 Sep 2013, 06:20

Re: paintbrush

Postby maninmachine » 21 Mar 2017, 23:43

The mixing effects would be different if successive strokes don't overlap, though. I tried to illustrate the difference below using two strokes that start as red, run through first blue, then yellow.

Image

User avatar
u2bleank
 
Posts: 948
Joined: 11 Jun 2012, 10:41

Re: paintbrush

Postby u2bleank » 22 Mar 2017, 09:16

Ok +1 for the request ;)

User avatar
bonnie
 
Posts: 225
Joined: 11 Jun 2012, 10:41

Re: paintbrush

Postby bonnie » 22 Mar 2017, 10:23

Hey Mim :)

What purpose do you have with this idea?
Do you have a concrete example?
:?:

Next

Return to Brush Exchange