@@ -6,9 +6,7 @@ Video Components in OLX
66
77.. tags :: educator, reference
88
9- You can add video components to any container in your course (such as
10- a vertical or sequential). Studio places all video components inside
11- verticals (which it calls units).
9+ You can add video components to a course unit via the ``video/<video_name>.xml `` file.
1210
1311.. contents ::
1412 :local:
@@ -19,19 +17,23 @@ Create the XML File for a Video Component
1917**********************************************
2018
2119To add a video component to your course, add it to the course XML tree as
22- follows.
20+ follows. This is `` video/purpose_power_reach.xml `` in the olx_example_course.
2321
2422.. code-block :: xml
2523
2624 <video
27- youtube =" 1.00:o2pLltkrhGM"
28- url_name =" Introduction_Lecture"
29- display_name =" Introduction Lecture"
30- youtube_id_1_0 =" o2pLltkrhGM" >
31- </video >
25+ youtube =" 1.00:lVPPPpyUOR4"
26+ url_name =" purpose_power_reach"
27+ display_name =" The Purpose, Power and Reach of the Open edX® Platform"
28+ edx_video_id =" "
29+ end_time =" 00:00:00"
30+ html5_sources =" []"
31+ start_time =" 00:00:00"
32+ track =" "
33+ youtube_id_1_0 =" lVPPPpyUOR4" />
34+
3235
33- If you prefer to place the video component in its own file, you create an XML
34- file in the ``video `` directory for each video component in your course.
36+ Place an XML file in the ``video `` directory for each video component in your course.
3537
3638The name of the XML file must match the value of the @url_name attribute of the
3739``video `` element in the vertical XML file.
@@ -40,12 +42,12 @@ For example, the vertical XML file uses the following format.
4042
4143.. code-block :: xml
4244
43- <vertical display_name =" Lesson_1_Unit_1" >
44- <video url_name =" Introduction_Lecture" />
45- . . .
45+ <vertical display_name =" Unit 1: Video" >
46+ <video url_name =" purpose_power_reach" />
4647 </vertical >
4748
48- You create the file ``video/Introduction_Lecture.xml `` to define the video
49+
50+ You create the file ``video/purpose_power_reach.xml `` to define the video
4951component.
5052
5153*************************************
@@ -54,24 +56,6 @@ Video Component XML File Elements
5456
5557The root element of the XML file for the HTML component is file is ``video ``.
5658
57- The ``video `` element contains a single ``source `` element.
58-
59- ==============================
60- ``source `` Element
61- ==============================
62-
63- The ``source `` element contains the following attribute.
64-
65- .. list-table ::
66- :widths: 10 70
67- :header-rows: 1
68-
69- * - Attribute
70- - Meaning
71- * - ``src ``
72- - The file path for the video file.
73-
74-
7559*************************************
7660``video `` Element Attributes
7761*************************************
@@ -83,33 +67,53 @@ The ``source`` element contains the following attribute.
8367 * - Attribute
8468 - Meaning
8569 * - ``display_name ``
86- - Required. The value that is displayed to students as the name of the
87- video component. If you do not supply a ``display_name `` value, "video"
88- is supplied for you.
70+ - Required. The value that is displayed to learners as the name of the
71+ video component. If a ``display_name `` is not supplied, "video" will appear to learners.
8972 * - ``youtube ``
90- - The speed and ID pairings for the YouTube video source. The value can
91- contain multiple speed:ID pairs, separated by commas.
73+ - The speed and 1.0 pairings for the YouTube video source (see Note below)
74+ * - ``youtube_id_1_0 ``
75+ - The YouTube id for the video
9276 * - ``download_track ``
93- - Whether students can download the video track. ``true `` or ``false ``.
77+ - Whether learners can download the video track. ``true `` or ``false ``.
9478 * - ``download_video ``
95- - Whether students can download the video. ``true `` or ``false ``.
79+ - Whether learners can download the video. ``true `` or ``false ``.
9680 * - ``html5_sources ``
9781 - The file path for the HTML5 version of the video.
9882 * - ``show_captions ``
99- - Whether students can view the video captions. ``true `` or ``false ``.
100- * - ``source ``
83+ - Whether learners can view the video captions. ``true `` or ``false ``.
84+ * - ``start_time ``
85+ - The HH:MM: SS value of when within the video playback should begin. Defaults to ``00:00:00 ``
86+ * - ``end_time ``
87+ - The HH:MM: SS value of when within the video playback should end. Defaults to ``00:00:00 `` (will play whole video)
88+ * - ``track ``
10189 - TBD
102- * - ``sub ``
103- - TBD
104- * - ``youtube_id_0_75 ``
105- - The YouTube ID for the video that plays at 75% normal speed.
106- * - ``youtube_id_1_0 ``
107- - The YouTube ID for the video that plays at 100% normal speed.
108- * - ``youtube_id_1_25 ``
109- - The YouTube ID for the video that plays at 125% normal speed.
110- * - ``youtube_id_1_5 ``
111- - The YouTube ID for the video that plays at 150% normal speed.
90+ * - ``edx_video_id ``
91+ - Only used on ``edx.org `` courses. Will be deprecated.
92+
93+ .. note ::
94+
95+ For historical reasons, the ``youtube `` attribute requires a speed mapping. Since YouTube introduced the
96+ native ability to speed up/slow down video circa 2014, the speed mapping is no longer required. However, the ``youtube ``
97+ attribute still maps the YouTube id to the 1.0 speed as follows:
98+
99+ .. code-block :: xml
100+
101+ youtube="1.00:lVPPPpyUOR4"
102+
103+ ==============================
104+ ``source `` Element
105+ ==============================
112106
107+ The optional ``source `` element contains the following attribute.
108+
109+ .. list-table ::
110+ :widths: 10 70
111+ :header-rows: 1
112+
113+ * - Attribute
114+ - Meaning
115+ * - ``src ``
116+ - The file path for the video file.
113117
114118*************************************
115119Example Video Component XML File
@@ -120,16 +124,15 @@ The following example shows an XML file for a video component.
120124.. code-block :: xml
121125
122126 <video
123- youtube =" 0.75:xGKlr7nT_Zw,1.00:o2pLltkrhGM,1.25:XGsB9bA6rGU,1.50:_HuIF16HdTA"
124- url_name =" Introduction_Lecture"
125- display_name =" Introduction Lecture"
126- download_video =" true"
127- html5_sources =" [" https://s3.amazonaws.com/edx-course-videos/school/DemoCourseIntroductionVideo.mov" ]"
128- source =" "
129- youtube_id_0_75 =" xGKlr7nT_Zw"
130- youtube_id_1_0 =" o2pLltkrhGM"
131- youtube_id_1_25 =" XGsB9bA6rGU"
132- youtube_id_1_5 =" _HuIF16HdTA" >
127+ youtube =" 1.00:lVPPPpyUOR4"
128+ url_name =" purpose_power_reach"
129+ display_name =" The Purpose, Power and Reach of the Open edX® Platform"
130+ edx_video_id =" "
131+ end_time =" 00:00:00"
132+ html5_sources =" []"
133+ start_time =" 00:00:00"
134+ track =" "
135+ youtube_id_1_0 =" lVPPPpyUOR4" >
133136
134137 <source src =" https://s3.amazonaws.com/edx-course-videos/mit-6002x/6002-Tutorial-00010_100.mov" />
135138 </video >
0 commit comments