User Tools

Site Tools


mp3player

MP3Player

The MP3Player loads the MP3Element, Menu, and other tags to create a high-level audio-based interactive component.

A stylized viewer holding an MP3 element with a waveform.
MP3Player screenshot

Characteristic

Definition
Type Interactive Display Object
Category Component
Scope Local
Position *
Parents Container
Children *
Gestures *
Attributes
Requirements The nesting structure and class attributes must match the example below.

Attribute

Type

Description
mp3 object reference the MP3 element

See Also: Display Attributes

<MP3Player x="600" y="170" mouseChildren="true" disableNativeTransform="false" disableAffineTransform="false">

    <TouchContainer class="mp3_container" visible="true" targetParent="true" mouseChildren="false">
        <MP3 src="RuthCalledShot_vbr.mp3" 
            display="waveform"
            width="600" height="400" 
            autoplay="true"
            preload="true"
            loop="true"
            pan="0.0"
            volume="1.0"
            waveColor="0xF97D41"
            backgroundColor="0xFFF9EC"
            backgroundAlpha="1" />
    </TouchContainer>
	
    <TouchContainer class="info_container" visible="false" targetParent="true" mouseChildren="false" >
        <Graphic color="0xE9BB4F" alpha="0.6" lineStroke="0" class="info_bg" shape="rectangle"/>
        <Text class="title" border="false" selectable="false" text="Babe Ruth's Called Shot"/>				
        <Text class="desc" text="An interview going over the narrative of Babe Ruth's famously called shot."/>		
    </TouchContainer>
	
    <TouchContainer class="frame_container" visible="true" targetParent="true" mouseChildren="false">
        <Frame frameColor="0x0E5923" frameAlpha="0.6" frameThickness="10" frameShape="rectangle" class="frame_element"/>
    </TouchContainer>
	
    <Menu class="menu_container" x="0" y="-65" alpha="0.6" position="bottom" paddingLeft="30" paddingBottom="-50" paddingRight="20" autoHide="true" visible="false">
        <Include src="infoButton.cml"/>
        <Include src="playButton.cml"/>
        <Include src="pauseButton.cml"/>
        <Include src="closeButton.cml"/>
    </Menu>
	
    <GestureList>
        <Gesture ref="n-drag" gestureOn="true"/>
        <Gesture ref="n-scale" gestureOn="true"/>
        <Gesture ref="n-rotate" gestureOn="true"/>
        <Gesture ref="tap" gestureOn="true"/>
    </GestureList>
</MP3Player>
mp3player.txt · Last modified: 2015/09/18 14:58 by glass