OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

cgmopen-members message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: RE: A CGM Question: handling transparency


Hi guys,
 
Transparent black is RGBA = (0,0,0,0).  In SVG, every time you create an <svg> element, a canvas (image buffer if you prefer) is initialized to transparent black.  The same is true for any shape that gets rendered by the viewer.  Let say you want to draw an opaque green circle; first the renderer has to create a temporary canvas (i.e. buffer initialized to transparent black) onto which the opaque green circle will be drawn; once the circle is rendered onto the temporary canvas, then the renderer uses alpha compositing to composite the green circle onto the <svg> temporary canvas.  Only when it is time to composite the SVG final result in the browser, do you then introduce the concept of an opaque background.
 
Hope this helps a bit.
 
Back to my example...  I can understand why you would say it is 'kind of a workaround', but it does demonstrate what I'm saying above.  There are many ways to describe what you want (unless I misunderstood what you meant which is quite possible).
 
Attached you will find a simplified approach.
 
Cordialement,
Benoît
 
-----Original Message-----
From: DULUC Franck [mailto:franck.duluc@airbus.com]
Sent: Friday, August 29, 2003 3:46 AM
To: 'Lofton Henderson'; Benoit Bezaire
Cc: cgmopen members mailing list
Subject: RE: A CGM Question: handling transparency

Hi/bonjour, Lofton, Benoît,
 
    Thanks for having taken time to discuss it while I was sleeping :-).
 
    I have two questions:
        - Lofton, you give me the way to do it with WebCGM, what about ATA Profile ?
        - Benoît, the way you use defs/use SVG with rect and circle is a kind of workaround, but the question is how to have the canvas transparent. Then you said that canvas in SVG are initialized to transparent black. As I am a user and more a computer scientist than a graphical art specialist, what is transparent black? This is said many times in SVG but I did not manage to find a definition.
 
Regards and/et Cordialement,
 
Franck DULUC
AIRBUS FRANCE
SDND - Digital Data Definition and Research
B.P. D0611
316, route de Bayonne
31060 TOULOUSE Cedex FRANCE
Phone: (33)5.61.18.19.16
Fax: (33)5.61.93.59.44
mailto:franck.duluc@airbus.com
-----Message d'origine-----
De : Lofton Henderson [mailto:lofton@rockynet.com]
Envoyé : jeudi 28 août 2003 18:25
À : Benoit Bezaire
Cc : cgmopen members mailing list
Objet : RE: A CGM Question: handling transparency

Hi Benoit,
Hi Benoit,

At 12:16 PM 8/28/03 -0400, Benoit Bezaire wrote:
[...]
SVG 1.0 ... what is the background?  I.e., if you just have a simple file, <svg>...blah...blah...</svg>, what is the "...blah...blah..." drawn on or over?  You are much more involved with this than I, and I'm drawing a blank on the answer.  Is it well defined in the SVG 1.0 standard, or undefined (i.e., "nothing", transparent), or viewer-dependent?
[Benoit Bezaire] Yes, it is well defined.  A canvas in SVG 1.0/1.0 is always initialized to transparent black.  You can find more info at:
http://www.w3.org/TR/SVG11/render.html#Grouping
http://www.w3.org/TR/SVG11/render.html#Elements
 

Thanks, that's the bit that I couldn't remember.

The WebCGM solution that I proposed earlier achieves that same effect -- choose the RGB-alpha colour model, and set BACKGROUND COLOUR to (0,0,0,0).

Cheers,
-Lofton.

franck2.svg



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]