photoshop gradient fills

Discussion in 'The Front Room' started by granny, Jan 20, 2004.

  1. granny

    granny Fledgling Freddie

    Anyone know how to do gradient fills in photoshop that follow the contours of a custom shape rather than just linear/circular/diamond/reflected etc?

    An example of what I mean:
    I'd like for the blood vessel in that picture (the big grey thing running down the centre of the picture with the tubule branching off it) to be nicely filled with a grey->white gradient that follows the contours of the shape much more smoothly that I've managed there.

    I managed the effect there by shrinking the shape and using an innre glow layer style then enlarging it again (had to shrink & enlarge cos the image is massive and inner glow is limited to 250 pixels size, doh).

    Any suggestions on a better way to do it?
  2. dysfunction

    dysfunction FH is my second home

    I remember those!

    I had to draw mine with a pencil and paper
  3. granny

    granny Fledgling Freddie

    Not really an option when I'm submitting the pictures to a research journal ;)
  4. Sar

    Sar Resident Freddy

    There are a couple of ways.

    The first is by using a layer style as you've done.

    Another way is by selecting the area to be filled with the 3D effect. On a new layer fill that area with a dark colour (in this case dark grey). Reselect that area (CTRL click on the layer in the layer palette). Contract the selection by a bit (depending on the size of the image). Now you can either feather the selection by using CTRL+ALT+D (or going Select->Feather) and feathering the selection by an appropriate amount, or alternatively you can enter quick mask mode by pressing Q, and blurring that area (Filter->Gaussian Blur) to an appropriate degree, then exit quick mask by pressing Q again.

    Then when you've done either of those, and again on a new layer, fill your selection with a lighter colour than you've used for the background (here light grey). It should follow the contour of the shape no problem. If the blurred colour bleeds out beyond the border of the darker colour (it can do depending on what settings you've used earlier), select the darker layer's non-transparent area by CTRL-clicking on its layer in the layers palette, inverting the selection (CTRL+SHIFT+I) then pressing Delete. Or you can clip the blurred lighter area to the darker layer's shape by pressing CTRL+G while the lighter layer is selected (active).

    You can repeat this process until you build up a nice 3D effect, tweaked to your liking, by contracting the selection on each new layer and blurring it again before filling it, then clipping it as above.

    Or, you can ignore all of the above, and use this method: Select the area you want to use as your main shape, fill it on a new layer with your darker colour. Enter quick mask mode (Q), paint an area in the middle of the area where you want your contour to be, with a soft edged brush. By using this method you can manually define where the contour will be. Then exit quick mask mode (again, Q), and on a new layer fill this with a lighter colour. To emphasise the effect, reselect the lighter colour's area (Select->Reselect), contract it (Select->Modify->Contract) and on a new layer fill that area with a lighter still colour.

    Any of these methods should get you what you want.


    PS: Apologies for not answering earlier, been offline for a couple of days. :)
  5. granny

    granny Fledgling Freddie

    Cheers Sar :) I'll have a play later and see how I do... I've not got round to working out how masks work yet, bit of a pshop n00b :p
  6. Sar

    Sar Resident Freddy

    You can either set masks up in photoshop to protect the area indicated by the mask (default), or have any area other than the area indicated by the mask protected from changes (my personal preference, as it means I can paint in a selection by hand).
  7. jameslin

    jameslin Fledgling Freddie

    gradient in two shapes

    I would like to apply a gradient fill between two irragular shapes, one shape is inside another shape. To explain what I mean, I use two circles as an example (I know they are regular shapes).

    Two circles, one big and one small. Small circle is inside the big circle. The circles are not concentric, so the small circle is closer to one edge of the big cirlce. This create two extreme distance between small circle and big circle; the shortest distance between small and big circles is Disnatace A, and longest distance between small and big circles is Distance B. The small circle is filled with red color, and OUTSIDE of the big circle is filled with blue. Now I would like to apply a gradient fill in the area between small circle and big cirlce, from red to blue. Since the circles are not concentric, so color gradient chage is bigger (color chages faster) in Distance A than in Distance B.

    Anyone knows whether Photoshop 7 is able to achieve this? if yes, how can I achieve this? Many thanks
  8. Sar

    Sar Resident Freddy

    Circular gradient underneath the smaller circle layer, from the centre of the smaller circle to the edge of the bigger circle, using the shorter distance.

    That should work, if what you want, and what I think you're after are the same thing ;)
  9. jameslin

    jameslin Fledgling Freddie

    Thanks Sar,

    Yes, it is working. But I actually required is to gradient between two irregular shapes, the small one is inside the bigger one. Use the same method can't get a satisfactory result because in the far partion is about no gradient.

    Sorry, I don't know how to create a new title, so I put my question in this thread because it looks smiliar. :kissit:

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.