Creating gradient in Gaussian-shaped dimple

Post questions on how to use or achieve an effect in Inkscape.
sisvullr
Posts: 2
Joined: Wed Oct 01, 2014 7:34 am

Creating gradient in Gaussian-shaped dimple

Postby sisvullr » Wed Oct 01, 2014 7:47 am

Hello everyone,

I want to draw a surface with a dimple in it with a Gaussian shape of the dimple. I am wondering if I can get some ideas or help how to create an appropriate gradient “inside” the dimple for better visualization. Please find the svg drawing with this link. https://www.dropbox.com/s/n4ye3ai725z2epw/Dimple_Geometrie.svg?dl=0

I am new to Inkscape, so any ideas or hints for finding the solution will already help me :) Thanks a lot,

Sven
Attachments
Dimple_Geometrie.svg
(154.59 KiB) Downloaded 259 times

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Creating gradient in Gaussian-shaped dimple

Postby Lazur » Wed Oct 01, 2014 8:17 am

Hello Sven,

That's some tough one.
To start with, that is even harder.

Here on a different problem two of the solutions that may produce something appropriate are presented.
One of them is the "yet to be fully developed" gradient mesh -I would consider it the more approximate here -if not perception driven, it could take for ages to make right-.

The other, is to use the interpolate fill attribute between group members, on groups created with interpolation.
Which, for that matter would only be good if the dimple's cross section was made of straight segments for each gradient steps.


Making it approximate with the using of blurring and clipping may be alot more effective, depending on the final output.

sisvullr
Posts: 2
Joined: Wed Oct 01, 2014 7:34 am

Re: Creating gradient in Gaussian-shaped dimple

Postby sisvullr » Wed Oct 01, 2014 11:02 am

Hi Lazur,

Thanks a lot for your ideas! I guess it's quite some work and exercise for me ;)

As soon as I have a solution, I'll let the forum know.

Thanks :)

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Creating gradient in Gaussian-shaped dimple

Postby Lazur » Wed Oct 01, 2014 11:23 pm

Another thought, if you are familiar with blender or alike,
you can model the dimple in 3D with it's side cut, then export it as an obj file and
import it through the render 3D polyhedron extension in inkscape for a good start.
Each of the faces will be represented as separate paths in 2D, so for a good obj it may not be a proper 3D shape/topology.

Somewhere there is even a render to svg addon for blender, though I couldn't get it to work.

User avatar
brynn
Posts: 10309
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Creating gradient in Gaussian-shaped dimple

Postby brynn » Thu Oct 02, 2014 2:42 am

Attached file shows a simple radial gradient fill. I don't know how geometrically precise it is. But it doesn't look too bad.... :?
Attachments
Dimple_Geometrie-1.svg
(159.87 KiB) Downloaded 180 times

Lazur
Posts: 4717
Joined: Tue Jun 14, 2016 10:38 am

Re: Creating gradient in Gaussian-shaped dimple

Postby Lazur » Thu Oct 02, 2014 9:11 am

Geometrically each of the iso-lines of the dimple is an ellipse -they are congruent-, and, each colour should represent a particular height, probably steps in the gradient with equal steps in the height.
Then, in this case, there is a cut at the side, so it would only be elliptical arces instead of full ellipses.
So the problem is, articulating the scale parameter of the basic object, making each of the width of the arches at equal heights follow the Gaussian shape as an envelope.
Like those in that old topic.
The interpolate option can only give linear interpolation as an lpe, and, as an extension the only option is to add an exponent.
Each of those can be used to represent isolines of solids of revolution, which with the linear option would produce cones, with the exponent some more curved surface, if the resulted new isolines are repositioned in equal heights.
If calculated right, this may give a close match to the Gaussian shape but I assume it would be too complicated to make two interpolation matching eachother with their exponents -if possible at all, as the imputs are limited by decimals.

And, once those iso-lines are being made, somehow each of two should be paired, to form a fill-able area,
Maybe would need a bit more tweaking to avoid the zero-width gap rendering issue.


Radial gradients can represent regular cone's isolines.
If they are viewed from the top.
Like in the attached example, with a diffuse lighting filter it may get clearer.
Attachments
cone iso.svg
(11.51 KiB) Downloaded 153 times


Return to “Help with using Inkscape”