Idividual Stroke Gradient For Rectangle

Post questions on how to use or achieve an effect in Inkscape.

Idividual Stroke Gradient For Rectangle

Postby axpen » Sun Feb 03, 2008 7:27 pm

Hello all, my problem is proving to be rather troublesome. Basically what I'm wanting is an individual shade on each stroke, but with combined edges. Let me explain with pictures.

Basically I'm wanting a box that looks like a pipe on the edges (like a bevel), like this: Image, to get this effect i'm using a gradient that goes from the edge to the center with a reflected repeat option, like so: Image.

I just want to know how to connect the edges to they look right, I did full cap ending and they overlapped. I assume you couldn't create a rect and use multiple gradients could you?

Anyways, thanks alot in advance for your time and help!

--Alex
axpen
 
Posts: 3
Joined: Sun Feb 03, 2008 7:07 pm

Re: Idividual Stroke Gradient For Rectangle

Postby Simarilius » Mon Feb 04, 2008 3:35 am

the simplest way to achieve what your after is probably to stack a couple of identical rects on top of each other, then increase the stroke size and blur the bottom one. Should look pretty much how you want I think.
Simarilius
 
Posts: 612
Joined: Wed Jun 06, 2007 2:37 am

Re: Idividual Stroke Gradient For Rectangle

Postby axpen » Wed Feb 06, 2008 3:41 pm

Thanks for the reply, I also have successfully made a gradient part-circle that did it. However I was just wondering with as powerful as Inkscape is, if maybe there isn't some more advanced way to do this. Like stroke a path with a thin line stroke with the gradient we have, that will ''bend'' at the corners along the round rect path. Or maybe a way of connecting the corners so that the gradient doesn't tile (or maybe i'm doing something wrong with the gradient and it should already bend?).

Thanks again for the quick reply to one possible solution, I'd still like to hear others' opinions as well, to get an idea how they would do it.

The help is greatly appreciated,
--Alex
axpen
 
Posts: 3
Joined: Sun Feb 03, 2008 7:07 pm

Re: Idividual Stroke Gradient For Rectangle

Postby sas » Wed Feb 06, 2008 7:16 pm

Inkscape doesn't support gradients that bend with a path (because SVG doesn't support it, and it can't easily be mimicked with anything that SVG does support).

For the sort of thing you want to do, the approach that Simarilius suggests is probably best, although blurring the top rectangle rather than the bottom one is an alternative. (Also, you may want to clip the blurred rectangle, to make the edges sharp.)
User avatar
sas
 
Posts: 404
Joined: Sat Oct 06, 2007 5:42 am

Re: Idividual Stroke Gradient For Rectangle

Postby axpen » Mon Feb 11, 2008 5:52 am

Thanks for the help everyone, I decided that the approach of using a 45 degree part circle with the radial gradient on each end looked the best.

--Alex
axpen
 
Posts: 3
Joined: Sun Feb 03, 2008 7:07 pm

Re: Idividual Stroke Gradient For Rectangle

Postby microUgly » Thu Feb 21, 2008 3:53 pm

Since your using such a simple gradient for the effect, have tried simply drawing the rectangle, giving it rounded corners, applying a green stroke and bluring it?
User avatar
microUgly
Site Admin
 
Posts: 2977
Joined: Sat Jun 02, 2007 3:13 pm

Re: Idividual Stroke Gradient For Rectangle

Postby PomCompot » Mon Oct 13, 2008 7:35 pm

There's a huge limitation of the use of the blur tool to simulate a gradient : you loose the hue of the color. Indeed, the blur effect dilute the color with the background with a kind of transparency. With a true gradient, you can have intense color, it is not possible with blur.

Could we expect either an evolution of the SVG standard to allow bent gradients, or a trick in Inkscape allowing that ?
PomCompot
 
Posts: 1
Joined: Mon Oct 13, 2008 6:49 pm

Re: Idividual Stroke Gradient For Rectangle

Postby microUgly » Mon Oct 13, 2008 7:54 pm

I believe Illustrator allows manipulation of gradient by expoding the gradients into lots of small objects where each object is a slice of colour from the gradient. In this sense I think it could be possible.
User avatar
microUgly
Site Admin
 
Posts: 2977
Joined: Sat Jun 02, 2007 3:13 pm


Return to Help with using Inkscape

Who is online

Users browsing this forum: No registered users and 14 guests