PDA

View Full Version : cube edge lines/outlines


lloeki
April 12th, 2007, 03:04 PM
well, the thing that always striked me with the cube plugin is: wow, it looks good, but so cubely raw...
on top of that, almost nobody has symmetrically edged wallpapers fitted for continuous repetition, so, on the edges, the wallpaper sides don't match.

so, why not giving (optional) edge lines to the cube.

if my ol' opengl knowledge is good enough, it's as simple as
- drawing the cube textured
- drawing the cube wireframed, and offsetted towards the camera by a small amount (there's a nice one-line opengl call for just that that I can't remember)

with the same trick, we could give the cube a sorta 'cel-shading' outline by:
- either drawing the cube untextured (flat-shaded), offsetted to the back, and slightly oversized
- or drawing the cube wireframed, with fat enough lines, offsetted to the back
- and then drawing the real cube

options would be:
- type : none | outline | edge line | custom
- color
- if custom, line width
- if custom, offset