W3C home > Mailing lists > Public > www-svg@w3.org > February 2004

Re: value of required extension in conditional processing

From: Chris Lilley <chris@w3.org>
Date: Tue, 24 Feb 2004 22:38:16 +0100
Message-ID: <130112353.20040224223816@w3.org>
To: ruben Tech <rubentech2000@yahoo.com>
Cc: www-svg@w3.org

On Sunday, February 15, 2004, 11:12:09 PM, ruben wrote:

rT> I am in the process of developing an SVGTiny player. It works
rT> pretty much fine at this point,

Cool! What dos it run on?

rT> however, I am having little
rT> problem in understanding conditional processing.

In general,  conditional processing in SMIL and in SVG consists of
attributes which evaluate to true or false. If any conditional
attributes evaluate to false, the element is not rendered.

Also, if the conditional statement is the child of a switch, the the
first one where all conditionals evaluate to true is rendered and the
remaining children are not rendered (need not even be evaluated).

This is similar to the 'break' instruction in programming languages
whose switch or case statements have fall through, if that helps.

rT> In SVG conditional processing  (
rT> http://www.w3.org/TR/SVG11/struct.html#ConditionalProcessing )
rT> there is "required extention" attribute. According to spec, the
rT> value of "required extension" identified by URL reference (
rT> http://www.w3.org/TR/SVG11/struct.html#URIReference ). It is not
rT> easily understandable, what are the possible values?

The reason that it is a URI is that there can be no list of possible

rT> From the spec
rT> "The URI names for the extension should include versioning
rT> information, such as "http://example.org/SVGExtensionXYZ/1.0", so
rT> that script writers can distinguish between different versions of
rT> a given extension."


rT> What kind of SVG extension we are talking about?


rT> Does this
rT> mean that, if the user agent (in this case our SVGTiny player)
rT> supports any of the extension it would be statically(compile time
rT> information) known to the player?

Yes. So if your player had some extensions, it would assign URIs to
them, and content that was targetted at your player could use that
extensio if it was on your player and use some other content if not.

This is more likely to be used for round tripping by authoring tools
tan by players. As an example, suppose the Foo authoring tool has a
'pyramid fill'. It wants to preserve this pyramid fill so an SVG file
can be saved out, read back in, and continue to be edited.

Say it creates some content that uses the pyramid fill

<foo:pyrFill attribute="whatever"
 <foo:stop etc="toto"/>

So it makes a URI, http://foo.example.org/pyr

And puts that in a test inside a switch.

  <g requiredExtensions="http://foo.example.org/pyr">
    <foo:pyrFill attribute="whatever"
       <foo:stop etc="toto"/>
  <g> <!--note that no test is needed here-->
    <!-- some fallback probably involving four linear gradients plus
    some clipping paths -->

rT>  Can you give me one or two
rT> examples? Even after several days of searching I could not find
rT> any example on net.

That is a good thing. They are special purpose and not to be widely
used. Especially for Tiny.

 Chris Lilley                    mailto:chris@w3.org
 Chair, W3C SVG Working Group
 Member, W3C Technical Architecture Group
Received on Tuesday, 24 February 2004 16:38:17 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 8 March 2017 09:46:58 UTC