test/jwplayer-audio.htm
author veltr
Wed, 26 Sep 2012 18:55:36 +0200
changeset 966 c1c762ad1697
child 969 353b0881a0b9
permissions -rw-r--r--
Added Voice Annotation Support
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
966
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     1
<!doctype html>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     2
<html>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     3
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     4
    <head>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     5
        <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     6
        <title>Metadataplayer test with JwPlayer</title>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     7
        <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700,400italic,700italic' rel='stylesheet' type='text/css'>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     8
        <link href='test.css' rel='stylesheet' type='text/css'>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
     9
        <script type="text/javascript" src="metadataplayer/LdtPlayer-core.js" type="text/javascript"></script>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    10
        <script type="text/javascript" src="test-config.js" type="text/javascript"></script>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    11
    </head>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    12
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    13
    <body>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    14
        <h1>Metadataplayer test with JwPlayer</h1>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    15
        <div id="LdtPlayer"></div>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    16
        <div id="AnnotationsListContainer"></div>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    17
        <script type="text/javascript">
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    18
    IriSP.libFiles.defaultDir = "libs/";
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    19
    IriSP.language = 'fr';
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    20
    IriSP.widgetsDir = "metadataplayer";
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    21
    var _metadata = {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    22
        url: 'http://exp.iri.centrepompidou.fr/tralalere/tralalere/ldt/cljson/id/42a3fc0a-afee-11e1-82e8-58b035f6b93d?callback=?',
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    23
        format: 'ldt'
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    24
    };
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    25
    var _config = {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    26
        width : 550,
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    27
        container : 'LdtPlayer',
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    28
        default_options: {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    29
            metadata: _metadata
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    30
        },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    31
        css : 'metadataplayer/LdtPlayer-core.css',
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    32
        widgets: [
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    33
            {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    34
                type: "JwpPlayer",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    35
                live: true,
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    36
                width: 1,
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    37
                height: 1,
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    38
                provider: "rtmp",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    39
                streamer: function(_url) {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    40
                    var _matches = _url.match(/^[^\/]+\/\/[^\/]+\/[^\/]+\//);
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    41
                    if (_matches) {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    42
                        return _matches[0];
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    43
                    } else {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    44
                        return _url;
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    45
                    }
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    46
                }
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    47
            },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    48
            { type: "Slider" },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    49
            { type: "Controller" },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    50
            { type: "Polemic" },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    51
            { type: "Segments" },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    52
            { type: "Annotation" },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    53
            {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    54
                type: "CreateAnnotation",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    55
                api_endpoint_template: "post-test.php",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    56
                creator_name: "Metadataplayer",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    57
                creator_avatar: "https://si0.twimg.com/sticky/default_profile_images/default_profile_1_normal.png",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    58
                show_mic_record: true
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    59
            },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    60
            { type: "Tweet" },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    61
            {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    62
                type: "Tagger",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    63
                api_endpoint: "post-test.php"
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    64
            },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    65
            {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    66
                type: "Tagcloud"
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    67
            },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    68
            {
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    69
                type: "AnnotationsList",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    70
                container: "AnnotationsListContainer",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    71
                default_thumbnail : "http://ldt.iri.centrepompidou.fr/static/site/ldt/css/imgs/video_sequence.png",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    72
                show_audio: true,
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    73
                rtmp_streamer: "rtmp://media.iri.centrepompidou.fr/ddc_micro_record/"
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    74
                //ajax_url: "/pf/ldtplatform/api/ldt/segments/{{media}}/{{begin}}/{{end}}",
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    75
                //ajax_granularity : 300000
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    76
            },
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    77
            { type: "Mediafragment"}
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    78
        ]
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    79
    };
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    80
    
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    81
    var _myPlayer = new IriSP.Metadataplayer(_config);
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    82
    
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    83
        </script>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    84
    </body>
c1c762ad1697 Added Voice Annotation Support
veltr
parents:
diff changeset
    85
</html>