[MPlayer-DOCS] CVS: main/DOCS/xml/en mencoder.xml,1.44,1.45

Josh Varner jlvarner at gmail.com
Wed Apr 13 17:31:56 CEST 2005


On 4/12/05, Torinthiel <torinthiel at megapolis.pl> wrote:
> On Tue, Apr 12, 2005 at 08:33:49AM -0500, Josh Varner wrote:
> > I think you want to use informal equation rather than equation, and
> > then don't specify any attributes for the graphic so that it has to
> > use the alt data (the graphic is still mandatory though).
> > <informalequation>
> >   <alt>bitrate = (target_size_in_Mbytes - sound_size_in_Mbytes) *
> >      1024 * 1024 / length_in_secs * 8 / 1000</alt>
> >   <graphic></graphic>
> > </informalequation>
> 
> Wow, I didn't know you can pass empty <graphic>. In this case it can be
> further simplified, change <graphic></graphic> to <graphic/>.
> Probably inlineequation would be better, true.
> But now it's a matter of discussion if we want such obscure constructs.
> Especially as at least two browsers I've tested don't display such
> equations - Opera places empty place for missing image and (old) mozilla
> displays nothing. which sort of disqualifies the method.
> Torinthiel
> 
Let me try again - I assumed the alt information would be placed into
the generated output as an alternate to the image, but it seems that
is incorrect. This is a known probllem, for which MediaObject was
created:
     This element contains graphical data, or a pointer to an external
entity containing
     graphical data. One of the deficiencies of the DocBook Graphic
element is that
     there is no way to specify an alternate text description of the
graphic. This has
     been rectified by the introduction of MediaObject.
     from http://www.oasis-open.org/docbook/documentation/reference/html/graphic.html

On the MediaObject page
(http://www.oasis-open.org/docbook/documentation/reference/html/mediaobject.html)
they had this example:
<!DOCTYPE mediaobject PUBLIC "-//OASIS//DTD DocBook V3.1//EN">
<mediaobject>
<imageobject>
<imagedata fileref="figures/eiffeltower.eps" format="eps">
</imageobject>
<imageobject>
<imagedata fileref="figures/eiffeltower.gif" format="gif">
</imageobject>
<textobject>
<phrase>The Eiffel Tower</phrase>
</textobject>
<caption>
<para>Designed by Gustave Eiffel in 1889, The Eiffel Tower is one of the
most widely recognized buildings in the world.
</para>
</caption>
</mediaobject>

which produces the following html
</DIV
><DIV CLASS="example-output"><DIV
CLASS="MEDIAOBJECT"
><P
><IMG
SRC="figures/eiffeltower.gif"
ALT="The Eiffel Tower"
></IMG
><DIV
CLASS="CAPTION"
><P
>Designed by Gustave Eiffel in 1889, The Eiffel Tower is one of the
most widely recognized buildings in the world.</P
></DIV
>

so I believe this should do it:
<informalequation>
  <mediaobject>
    <imageobject><imagedata/></imageobject>
    <textobject>
      <phrase>bitrate = (target_size_in_Mbytes - sound_size_in_Mbytes) *
         1024 * 1024 / length_in_secs * 8 / 1000</phrase>
    </textobject>
  </mediaobject>
</informalequation>

I unfortunately am not set up to test this on this computer, but I
believe this should produce a broken image link with alt text, giving
you the desired output. But this is becoming a ridiculous number of
hoops to jump through as MediaObject still requires at least one
image/audio/video object.

Josh




More information about the MPlayer-DOCS mailing list