Welcome Guest! You need to login or register to make posts.



Go to last post Go to first unread
#1 Posted : Saturday, June 25, 2005 11:07:00 PM(UTC)

Rank: Member

Groups: Member
Joined: 6/23/2005(UTC)
Posts: 4

How i can get the brush type gradient or Texture? In the GM help the property Brush.type Specifies what type the brush is: solid, hatch, gradient or some other, but the BrushType Enumeration only has two options: BrushTypeSolid - 0 and BrushTypeHatch - 1. According with GDI+, brush may be: SolidBrush, HatchBrush, TextureBrush and GradientBrush. Are the options TextureBrush and GradientBrush available in Graphics Mill? Thanks Orlando R Bogota - Colombia
#2 Posted : Monday, June 27, 2005 3:15:00 PM(UTC)

Rank: Advanced Member

Groups: Member, Administration
Joined: 8/2/2003(UTC)
Posts: 866

Thanks: 2 times
Was thanked: 26 time(s) in 26 post(s)
It seems the documentation contains incorrect information (we did plan to add these features, but had to refuse this idea). Thank you for keeping us informed about this.

Graphics Mill supports only solid and hatch brush. Unfortunately neither texture nor gradient are not supported. However you could emulate it. The idea is the following:

1. Add alpha channel to the image you need to use as a texture (or generated gradient). This alpha channel should contain a shape you need to fill.

2. Draw the texture/gradient (using alpha blending).

3. Draw the shape (if you need outline).

Please let me know if you need more detailed code sample for this.

Also, there is a discussion how to generate a gradient on this forum. View post for more details on this.
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.