From: Ari H. <ahe...@an...> - 2001-07-22 17:24:24
|
On Sun, Jul 22, 2001 at 01:10:48PM -0400, Arthur Siegel wrote: > Not sure its directly responsive - but high on my wish list is some simple > access to 4 factor coloring - some access to an alpha transparency. Full > opaqueness often fully hides objects where I wish to at least hint at > their existence. > > It has been already explained to me why this is not a simple matter, > though I didn't get it. I know in opengl its simply a matter of using a > color4 rather than a color3. Why can't that be an option, with the alpha > factored defaulted to 1 if one uses only a 3 elements. oh, that's not the problem. yeah yeah, we could turn on transparency, and things would alpha :) iirc (and we have talked about this before, as usual scherer please correct me) the problem is that Visual doesn't know enough about the spacial relationship between objects, at least as far as rendering. so it can't guarantee anything like correct behaviour -- if you're rendering opaques, you just tell GL to depthbuffer, and render in whatever order you happen to render in, and everything magically works right. but alpha is a cumulative effect that you calculate in the output buffer as you render, so order matters. fixing visual's core renderer to handle this correctly would not be a simple thing. i haven't looked seriously at doing it, and i'm not planning to (immediately anyhow). but it could be done -- hackishly, you could sort the objects before render. there are fast ways of doing things that involve maintaining much more info at all times. > > Seems to be that texturing is harder than this. Will the work necessary > have any impact on the ability to implement transparency? not really :) except possibly making me even more insane and unstable, which could result in me doing all kinds of unpredictable things. textures are an additional feature of the primitives. they work (in GL) about the same way vertices do, so you just need a way of getting texture data (per vertex) into the primitive, and you need to say to the renderer "this vertex has this texture coordinate". > > I realize I am missing something - depth cuing or something. Personally I'd > happily settle for a not-so-good transparency if that were easily > achievable. well. utterly unpredictable transparency is quite possible ;) you'll just never know whether you'll see the back object thru the transparent front object, or if the back object will just obscure the front object. i guess it might produce results that weren't too visually jarring if you made all the objects transparent, and all your users lost their contacts beforehand :) ari |