Need to create a mask to be used as overlay with my video editor program (PowerDirector). Using Inkscape 0.91
Need to be a 1920x1080 (FullHD) black rectangle with a transparent hole in the center, sized 728x540.
I did define the Document properties with FullHD size, background white w 100% transparent alpha channel, used 4 rectangles to shape the central hole.
Using File>Export PNG Image I did obtain an image with the central rectangle white.
Tried to do the opposite and defining the document background black but 100% opaque and using a central white transparent rectangle, same result.
It's really a stupid task but I'm not able to do it, can you please give me any suggesion.
Stupid black rectangle with transparent hole
Stupid black rectangle with transparent hole
- Attachments
-
- Mask squared PD.png (7.23 KiB) Viewed 5310 times
- Espermaschine
- Posts: 892
- Joined: Thu Jun 05, 2014 9:10 pm
Re: Stupid black rectangle with transparent hole
set document properties (Shift + Ctrl + D) to 1920x1080px
activate 'snap to page border' in the snap bar
draw rectangle 1920x1080px, which should be easy because of the snapping
select, make it black with no Stroke
draw another rectangle (in any other colour than black), type in the values you want (728x540px)
align to the center of the page with the alignment tool
select black rectangle, then with the Shift key pressed down, include the white rectangle
perform a 'Difference' (Ctrl + minus)
export page
activate 'snap to page border' in the snap bar
draw rectangle 1920x1080px, which should be easy because of the snapping
select, make it black with no Stroke
draw another rectangle (in any other colour than black), type in the values you want (728x540px)
align to the center of the page with the alignment tool
select black rectangle, then with the Shift key pressed down, include the white rectangle
perform a 'Difference' (Ctrl + minus)
export page
- Attachments
-
- Mask.svg
- (2.08 KiB) Downloaded 217 times
Re: Stupid black rectangle with transparent hole
davide445 wrote:I did define the Document properties with FullHD size, background white w 100% transparent alpha channel...
Well, you're almost there.
The overlapping area can be made 'transparent' by selecting both and using 'ctrl K' or Path menu > combine. It's best if the smaller or inner path has a fill that you can see before so you can note its absence after. If this operation has no effect, one of the paths needs to be reversed (path menu reverse) or the fill rule needs to be switched (fill and stroke dialog, top right area)
Your mind is what you think it is.
Re: Stupid black rectangle with transparent hole
Thanks for your reply.
I think the problem is the export. Every time I export to PNG the central rectangle became a white and not transparent.
Need I to care about something exporting into png?
I think the problem is the export. Every time I export to PNG the central rectangle became a white and not transparent.
Need I to care about something exporting into png?
Re: Stupid black rectangle with transparent hole
It works for me. One thing to note -- when you say 100% transparent alpha channel in document properties - I wonder if you are making the alpha fully opaque instead. The A slider should actually be all the way to the left, not the right, minimum value (0), not maximum. In document properties for background color you should then see a checkerboard in half the area, not a fully white swatch.
Your mind is what you think it is.
Re: Stupid black rectangle with transparent hole
If it's a black and white image, you can make a quick fix -for this image at least- in gimp by adding alpha channel (to the layer) by (white) colour.
Re: Stupid black rectangle with transparent hole
Ok that works!! I'm dying for such a stupid task, really angered with my inability to obtain these trivial things.
Maybe using Inkscape for such stupid task is such as using a cannon for a bug, but Paint or Paint.net didn't achieve the result in an easier way.
So next task is: did want the border of the central transparent rectangle to be diffuse and not sharp so to have a gradual transition, any way to do this?
Maybe using Inkscape for such stupid task is such as using a cannon for a bug, but Paint or Paint.net didn't achieve the result in an easier way.
So next task is: did want the border of the central transparent rectangle to be diffuse and not sharp so to have a gradual transition, any way to do this?
Re: Stupid black rectangle with transparent hole
Sounds antialiasing made it smooth. Check if your exporting area -resolution- and object is laying on the same pixel grid, as well as there are no strokes.
Re: Stupid black rectangle with transparent hole
No way to use gradient tool to better control the transition size?
Re: Stupid black rectangle with transparent hole
Oh sorry I misunderstood. Usually the problem is sharp doesn't appearing enough sharp.
For a black to transparent, "random" shaped gradient you better off starting to draw black to white transitions, then using masking, or gimp to add alpha by colour as suggested above.
How sharp you want the corners of the gradient to look like?
For a black to transparent, "random" shaped gradient you better off starting to draw black to white transitions, then using masking, or gimp to add alpha by colour as suggested above.
How sharp you want the corners of the gradient to look like?
Re: Stupid black rectangle with transparent hole
This is the final result want to obtain (obtained using Blur effect in my video editor on that mask)
- Attachments
-
- Overlay with blur.JPG (44.73 KiB) Viewed 5213 times
Re: Stupid black rectangle with transparent hole
Aahh, if we only had the example from the start! I wasn't understanding the first description. And actually, I'm not very good with masks, so I won't try. But I think this particular effect is easier in GIMP than Inkscape. Although I could be wrong. Maybe there's a handy filter for this?
Basics - Help menu > Tutorials
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Manual - Inkscape: Guide to a Vector Drawing Program
Inkscape Community - Inkscape FAQ - Gallery
Inkscape for Cutting Design
Re: Stupid black rectangle with transparent hole
Here are some variants, the possibilities are infinite:
- Espermaschine
- Posts: 892
- Joined: Thu Jun 05, 2014 9:10 pm
Re: Stupid black rectangle with transparent hole
You can put the Mask i attached (exported as a png of course) in Gimp and apply Gaussian Blur (say 20px) to get what you want.