Here's what I'm attempting to do -- I'd like to know if there's a better way to go about it.
I'm trying to make hexagonal game pieces. Each game piece consists of:
1. A background image
2. A border around the whole hexagon, created by putting one hexagon inside another. The space between the smaller inner hexagon and the larger outer hexagon is the border.
3. Text, written in that border between the outer large hexagon and inner small hexagon.
I want the border to have the same image as the inside of the hexagon, but much fainter, so that it is easy to read the text printed over top of the image.
At the moment, I am:
- making two copies of the image in GIMP, one at full saturation and jacking the contrast and saturation of the other to fade it.
- importing the faded version to Inkscape and using the larger hexagon as a clipping mask, then placing the faded image inside the game hex.
- importing the full-saturation version to Inkscape and using the smaller hexagon as a clipping mask, placing the full-saturated image inside the smaller hexagon in the game hex.
- writing the text in the border.
This seems wasteful -- I am effectively doubling the images in the Inkscape file just to have a fade effect for the background image in the border of these cards. Is there a better way to go about this?
Fading by shape?
-
- Posts: 8
- Joined: Fri Sep 09, 2011 8:36 pm
Re: Fading by shape?
Here's a quick example -- hopefully this file upload will work.
- Attachments
-
- Faded hex border example
- timerift.png (32.98 KiB) Viewed 1442 times
Re: Fading by shape?
There is a very much easier way to do this but first let me tell you I applaud your willingness to go back and forth from GIMP to Inkscape, which is something I often suggest for other issues that dDON'T have an in-Inkscape resolution.
1. Import the image into Inkscape however you are doing it - just the regular (saturated) version. If you are making it in Inkscape from vector elements, you don't have to convert it to a bitmap.
2. Select it and make it a pattern. that's in the object menu,objects to pattern. You get a rectangle with the image used as the fill.
3. Draw a hexagon, and in the fill and stroke select the pattern fill option. The list should have your newly created pattern at the top.
4. Now you can draw a larger hexagon, and use the same pattern fill on it and change the transparency. Note that the result will not be matched to the edges of your original in terms of the pattern. The variables that you can play with here that will give you a variety of effects are:
a. Use the pattern in the fill of the lower hexagon, which should be made the same size as the top opaque hex. Now you can just change the width of the fill to get widr and narrower borders. Downside: you can't add an opaque stroke to enclose the transparent hex which is rather a nice effect.
b. In the selector toolbar there is an option for scaling patterns with objects. This will affect your object if you make it the same size as the original and then scale it up after applying the pattern fill.
c. Most daring of all! <jk> you can apply the pattern fill to your hexagon, and clone it! Twice! Reduce the opacity of the bottom one and scale it up to get the effect you want. Why do it this way? Because you can change the pattern fill of the original and update the clones automatically - that includes scaling, rotating, translating or outright just switching to a different image. The downside to this method is that you can't ever get the pattern in the two hexagons to match at the transition edge because one will always be a scaled up version. Boo-hoo.
![Image](http://imgh.us/lhamo1.png)
MattShepherd wrote:I want the border to have the same image as the inside of the hexagon, but much fainter, so that it is easy to read the text printed over top of the image.
1. Import the image into Inkscape however you are doing it - just the regular (saturated) version. If you are making it in Inkscape from vector elements, you don't have to convert it to a bitmap.
2. Select it and make it a pattern. that's in the object menu,objects to pattern. You get a rectangle with the image used as the fill.
3. Draw a hexagon, and in the fill and stroke select the pattern fill option. The list should have your newly created pattern at the top.
4. Now you can draw a larger hexagon, and use the same pattern fill on it and change the transparency. Note that the result will not be matched to the edges of your original in terms of the pattern. The variables that you can play with here that will give you a variety of effects are:
a. Use the pattern in the fill of the lower hexagon, which should be made the same size as the top opaque hex. Now you can just change the width of the fill to get widr and narrower borders. Downside: you can't add an opaque stroke to enclose the transparent hex which is rather a nice effect.
b. In the selector toolbar there is an option for scaling patterns with objects. This will affect your object if you make it the same size as the original and then scale it up after applying the pattern fill.
c. Most daring of all! <jk> you can apply the pattern fill to your hexagon, and clone it! Twice! Reduce the opacity of the bottom one and scale it up to get the effect you want. Why do it this way? Because you can change the pattern fill of the original and update the clones automatically - that includes scaling, rotating, translating or outright just switching to a different image. The downside to this method is that you can't ever get the pattern in the two hexagons to match at the transition edge because one will always be a scaled up version. Boo-hoo.
![Image](http://imgh.us/lhamo1.png)
Last edited by druban on Sat Nov 17, 2012 8:16 pm, edited 1 time in total.
Your mind is what you think it is.
-
- Posts: 8
- Joined: Fri Sep 09, 2011 8:36 pm
Re: Fading by shape?
That looks amazing! Unfortunately, I can't get past the pattern fill part for the first hexagon -- instead of filling the hex with the pattern image, it fills it with a shrunken, tiled version of the image.
Re: Fading by shape?
MattShepherd wrote:instead of filling the hex with the pattern image, it fills it with a shrunken, tiled version of the image.
You're almost there! Pattern fills can be scaled, rotated and translated using the node tool
![Node :tool_node:](images/smilies/tool_node.gif)
Your mind is what you think it is.