A summary of the methods of JSP playing video files _jsp programming

Source: Internet
Author: User
Tags prefetch shuffle

This article is an example of how JSP plays video files. Share to everyone for your reference, specific as follows:

1.avi format

The code snippet is as follows:

JSP Code:

<object id= "video" width= "height=" border= "0" classid= "CLSID:CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA" >
<param name= "showdisplay" value= "0" >
<param name= "Showcontrols" value= "1" >
<param name= "AutoStart" value= "1" >
<param name= "autorewind" value= "0" >
<param name= "playcount" value= "0" >
<param name= "appearance value=" 0 value= "" >
<param name= "BorderStyle value=" 0 value= "" ">
<param name= "moviewindowheight" value= "> <param name=" moviewindowwidth "the Value="
>
<param name= "FileName" value= "File:///D|/work/vod/Mbar.avi" > <embed width= "height=" "
200" Border= "0" showdisplay= "0" showcontrols= "1" autostart= "1" autorewind= "0" playcount= "0" moviewindowheight= "240" Moviewindowwidth= "Filename=" "File:///D|/work/vod/Mbar.avi" src= "Mbar.avi" >
</embed>
</ Object>

2.mpg format

The code snippet is as follows:

JSP code:

<object classid= "clsid:05589fa1-c356-11ce-bf01-00aa0055595a" id= "ActiveMovie1" width= "239" height= "> < param name= "appearance" value= "0" > <param name= "AutoStart" value= "-1" > <param name= " Allowchangedisplaymode "value="-1 "> <param name=" allowhidedisplay "value=" 0 "> <param name="
Allowhidecontrols "value="-1 "> <param name=" autorewind "value="-1 "> <param name=" Balance "value=" 0 "> <param name= "currentposition" value= "0" > <param name= "displaybackcolor" value= "0" > <param name= " Displayforecolor "value=" 16777215 "> <param name=" displaymode "value=" 0 "> <param name=" Enabled "value="-1 " > <param name= "enablecontextmenu" value= "-1" > <param name= "enablepositioncontrols" value= "-1" > < param name= "enableselectioncontrols" value= "0" > <param name= "enabletracker" value= "-1" > <param name= " Filename "Value=". /.. /.. /mpeg/halali.mpg "valuetype=" ref "> <param name=" fullscreenmode "value=" 0 "> <pAram Name= "moviewindowsize" value= "0" > <param name= "Playcount" value= "1" > <param name= "Rate" value= "1" > <param name= "SelectionStart" value= "-1" > <param name= "selectionend" value= "-1" > <param name= " Showcontrols "value="-1 "> <param name=" showdisplay "value="-1 "> <param name=" Showpositioncontrols "value=

 "0" > <param name= "showtracker" value= "-1" > <param name= "Volume" value= " -480" > </object>

3.SMI format

The code snippet is as follows:

JSP Code:

<object id=rvocx CLASSID=CLSID:CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA width=240 height=180> <param
"_extentx" value= "6350" >
<param name= "_extenty" value= "4763" >
<param name= "AUTOSTART" value= "-1 ">
<param name=" SHUFFLE "value=" 0 ">
<param name=" PREFETCH "value=" 0 ">
<param name=" Nolabels "value="-1 ">
<param name=" SRC "value=" rm.rm "> <param name=" CONTROLS "value="
Imagewindow ">
<param name=" CONSOLE "value=" Console1 ">
<param name=" LOOP "value=" 0 ">
<param name= "Numloop" value= "0" >
<param name= "CENTER" value= "0" >
<param name= " Maintainaspect "value=" 0 ">
<param name=" BackgroundColor "value=" #000000 "><embed src=" Real.smi " Type= "Audio/x-pn-realaudio-plugin" console= "Console1" controls= "Imagewindow" height= "180" width= "" autostart= " True "></OBJECT>

4.RM format

The code snippet is as follows:

Java code:

<object id=video1 classid= "CLSID:CFCDAA03-8BE4-11CF-B84B-0020AFBBCCFA" height=288 WIDTH=352>
Name= "_extentx" value= "9313" >
<param name= "_extenty" value= "7620" >
<param name= "AUTOSTART" Value= "0" >
<param name= "SHUFFLE" value= "0" >
<param name= "PREFETCH" value= "0" >
<param Name= "Nolabels" value= "0" >
<param name= "SRC" value= "rtsp://203.207.131.35/vod/dawan-a.rm";;; >
<param name= "CONTROLS" value= "Imagewindow" >
<param name= "CONSOLE" value= "Clip1" >
<param name= "LOOP" value= "0" >
<param name= "numloop" value= "0" >
<param name= "CENTER" value= " 0 ">
<param name=" Maintainaspect value= "0" >
<param name= "BackgroundColor" value= "#000000" ><embed SRC type= "Audio/x-pn-realaudio-plugin" console= "Clip1" controls= "Imagewindow" height= "" WIDTH= "352" Autostart= "false" >
</OBJECT>

5.wmv format

The

Code snippet is as follows:

<object id= "Nsplay" width=200 height=180 classid= "Clsid:22d6f312-b0f6-11d0-94ab-0080c74c7e95" codebase= activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#version=6,4,5,715 "standby=" Loading Microsoft Windows Media Player components ... "type=" Application/x-oleobject "align=" right "hspace=" 5 "> <!--ASX File Name--&
Gt <param name= "Autorewind" value=1> <param name= "FileName" value= "******.wmv" > <!--Display Controls > <param name= "showcontrols" value= "1" > <!--Display Position Controls--> <param name= " Showpositioncontrols "value=" 0 "> <!--Display Audio Controls--> <param name=" Showaudiocontrols "value=" 1 "&
Gt <!--Display Tracker Controls--> <param name= "Showtracker" value= "0" > <!--show Display--> <param n Ame= "Showdisplay" value= "0" > <!--Display Status Bar--> <param name= "ShowStatusBar" value= "0" > <!--Di Play go to Bar--> <param name= "Showgotobar" value= "0"; <!--Display Controls--> <param name= "showcaptioning" value= "0" > <!--Player Autostart--> <param na Me= "AutoStart" Value=1> <!--Animation at Start--> <param name= "Volume" value= " -2500" > <param name= " Imationatstart "value=" 0 "> <!--transparent at Start--> <param name=" Transparentatstart "value=" 0 "> < !--don't allow a change in display size--> <param name= "allowchangedisplaysize" value= "0" > <!--does not allo W Scanning--> <param name= "Allowscan" value= "0" > <!--Don't show contect menu on right mouse click--> &L T;param name= "Enablecontextmenu" value= "0" > <!--do not allow playback toggling on mouse click--> <param Name

 = "Clicktoplay" value= "0" > </object>

6.WMA format

Put it in <body>. Here is a partial explanation:

<object classid= "Clsid:22d6f312-b0f6-11d0-94ab-0080c74c7e95" id= "MediaPlayer1" >
<param name= " Filename "value=" 1.Wma > <!--the location of your files-->
<param name= "Playcount" value= "1" ><!--control Repeat Number: "X" For several repeat play several times; X=0, infinite loops. -->
<param name= "AutoStart" value= "0" ><!--control playback mode: x=1, open the Web page autoplay; x=0, play by play key. -->
<param name= "Clicktoplay" value= "1" ><!--control play switch: X=1, mouse click to control playback or pause status; x=0, disable this feature. -->
<param name= "displaysize" value= "0" ><!--control Playback screen: x=0, original size; x=1, half size; x=2,2 times size. -->
<param name= "Enablefullscreen Controls" value= "1" ><!--control Toggle Full Screen: X=1, allow switching to full screen; x=0, disable this feature. -->
<param name= "Showaudio Controls" value= "1" ><!--control Volume: X=1, allowing the volume to be adjusted; x=0, volume adjustment is prohibited. -->
<param name= "enablecontext Menu" value= "1" ><!--Control shortcut menu: X=1, allow right-click menu; x=0, disable right-click menu. -->
<param name= "Showdisplay" value= "1" ><!--Control Copyright information: x=1, display film and author information; x=0, do not display related information-->
</ Object >

I hope this article will help you with JSP program design.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.