smoothcontract / mediate

Automatically exported from code.google.com/p/mediate
0 stars 0 forks source link

Add support for linear gradient fills #166

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Add a new fill type for linear gradients with multiple colour points. Will
need some way to specify colour position – maybe a percentage from 0-100.

Also need a method for specifying vertical or horizontal gradient.

Needs support for rendering sprites and text using this fade. For sprites
we’ll need to cut the sprite up into multiple quads split at each fade
reference point. For text we’ll need to enhance the canvas shade class and
font rendering class (maybe text could be rendered to an intermediate
texture and that could be rendered as a sectioned sprite).

Original issue reported on code.google.com by aretman...@gmail.com on 26 Jan 2009 at 3:30

GoogleCodeExporter commented 9 years ago
Implemented (mostly) in mediate designer v0.0.33. Linear fills are rendered 
using a single quad for sprites which 
means the colour choice may not be accurate, but this is far simpler than 
cutting up quads into smaller sections. 
For fonts this rendering approximation looks fine and allows soft clipping.

To improve upon this we need to support intermediate render targets, which 
means 3 render operations instead 
of 1.

Original comment by aretman...@gmail.com on 13 May 2009 at 3:57