THL Toolbox > Developers' Zone > Web Development > Xml Markup in THL > XML Markup Of Videos
Videos are marked up using the <figure> element with its "rend" attribute set to "movie". The "entity" attribute is set to the name of the entity, declared at the top of the document, referencing the movie file. If there is a small and larger version of the same video, the smaller version is encoded first, followed by the encoding for the larger version, and the "corresp" attribute on the smaller version is set to the "id" attribute value of the larger version. The <figure> element contains a <figureDesc> element with the caption for the image. However, the <figureDesc> element may also contain some hidden <rs> elements defining the size of the picture. These elements are empty elements (that is, they contain no text between the opening and closing tags) with their "rend" attribute set to "none"; their "type" attribute set to either "height" or "width", and their "n" attribute set to the numeric value for the height and width respectively. This n-value should be purely numeric and not have a suffix such as "px", "in" or the like.
An example of the first video mark-up is found in Mona Schremp’s article in the second issue of JIATS on “Hwa shang at the Border” as the first back section. The mark-up looks like this:
<div1 id="c1" n="video"> <milestone unit="page"/> <head>Video of a Ritual Dance</head> <p> <-- Small Version of Movie --> <figure entity="mov01" corresp="mv1lg" rend="movie"> <figDesc> <persName corresp="entry1" n="Hashang" lang="tib">hwa shang</persName> Ritual Dance <rs type="height" n="275" rend="none"/> <rs type="width" n="350" rend="none"/> </figDesc> </figure> <-- Large Version of Movie --> <figure entity="mov01lg" rend="movie large" id="mv1lg"> <figDesc> <persName corresp="entry1" n="Hashang" lang="tib">hwa shang</persName> Ritual Dance <rs type="height" n="500" rend="none"/> <rs type="width" n="650" rend="none"/> </figDesc> </figure> </p> </div1>
To specify the width and height of the movie, append a search string (i.e. a question mark followed by parameters) defining the parameters w (for width) and h (for height), separated by the ampersand. This search string would thus have a format of
http://www.thdl.org/…path to movie…/movie.mp4?w=300&h=200
An example can be found in The Mé College section of “An Introduction to Sera’s Colleges”.
The entity in that document is marked up as follows:
<!ENTITY mov1 SYSTEM "http://www.thlib.org/places/monasteries/sera/essays/images/01044_sera_mgon.mp4?w=320&h=256" NDATA MP4>
Below in the text the link is then marked up thus:
<xref doc="mov1" type="mp4">View a video of the Taok Chapel</xref>
Provided for unrestricted use by the Tibetan and Himalayan Library