This file is indexed.

/usr/share/doc/beignet-dev/howto/video-motion-estimation-howto.html is in beignet-dev 1.3.2-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>video-motion-estimation-howto</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />

<link rel="stylesheet" href="../style.css" type="text/css" />

<link rel="stylesheet" href="../local.css" type="text/css" />










</head>
<body>

<div class="page">

<div class="pageheader">
<div class="header">
<span>
<span class="parentlinks">

<a href="../index.html">wiki</a>/ 

<a href="../index.html">howto</a>/ 

</span>
<span class="title">
video-motion-estimation-howto

</span>
</span>



</div>









</div>





<div id="pagebody">

<div id="content" role="main">
<h1>Video Motion Vector HowTo</h1>

<p>Beignet now supports cl_intel_accelerator and cl_intel_motion_estimation, which are
Khronos official extensions. It provides a hardware acceleration of video motion
vector to users.</p>

<h2>Supported hardware platform</h2>

<p>Only 3rd Generation Intel Core Processors is supported for vme now. We will consider
to support more platforms if necessary.</p>

<h2>Steps</h2>

<p>In order to use video motion estimation provided by Beignet in your program, please follow
the steps as below:</p>

<ul>
<li><p>Create a cl_accelerator_intel object using extension API clCreateAcceleratorINTEL, like
this:
_accelerator_type_intel accelerator_type = CL_ACCELERATOR_TYPE_MOTION_ESTIMATION_INTEL;
cl_motion_estimation_desc_intel vmedesc = {CL_ME_MB_TYPE_16x16_INTEL,
                                           CL_ME_SUBPIXEL_MODE_INTEGER_INTEL,
                                           CL_ME_SAD_ADJUST_MODE_NONE_INTEL,
                                           CL_ME_SEARCH_PATH_RADIUS_16_12_INTEL
                                          };</p></li>
<li><p>Invoke clCreateProgramWithBuiltInKernels to create a program object with built-in kernels
information, and invoke clCreateKernel to create a kernel object whose kernel name is
block_motion_estimate_intel.</p></li>
<li><p>The prototype of built-in kernel block_motion_estimate_intel is as following:
_kernel void
block_motion_estimate_intel
(
 accelerator_intel_t accelerator,
 <strong>read_only  image2d_t src_image,
 </strong>read_only  image2d_t ref_image,
 <strong>global short2 * prediction_motion_vector_buffer,
 </strong>global short2 * motion_vector_buffer,
 __global ushort * residuals
 );
So you should create related objects and setup these kernel arguments by clSetKernelArg.
Create source and reference image object, on which you want to do video motion estimation.
The image_channel_order should be CL_R and image_channel_data_type should be CL_UNORM_INT8.
Create a buffer object to get the motion vector result. This motion vector buffer representing
a vector field of pixel block motion vectors, stored linearly in row-major order. The elements
(pixels) of this image contain a motion vector for the corresponding pixel block, with its x/y
components packed as two 16-bit integer values. Each component is encoded as a S13.2 fixed
point value(two's complement).</p></li>
<li><p>Use clEnqueueNDRangeKernel to enqueue this kernel. The only thing you need to setup is global_work_size:
global_work_size[0] equal to width of source image, global_work_size[1] equal to height of source
image.</p></li>
<li><p>Use clEnqueueReadBuffer or clEnqueueMapBuffer to get motion vector result.</p></li>
</ul>


<h2>Sample code</h2>

<p>We have developed an utest case of using video motion vector in utests/builtin_kernel_block_motion_estimate_intel.cpp.
Please go through it for details.</p>

<h2>More references</h2>

<p><a href="https://www.khronos.org/registry/cl/extensions/intel/cl_intel_accelerator.txt">https://www.khronos.org/registry/cl/extensions/intel/cl_intel_accelerator.txt</a>
<a href="https://www.khronos.org/registry/cl/extensions/intel/cl_intel_motion_estimation.txt">https://www.khronos.org/registry/cl/extensions/intel/cl_intel_motion_estimation.txt</a>
<a href="https://software.intel.com/en-us/articles/intro-to-motion-estimation-extension-for-opencl">https://software.intel.com/en-us/articles/intro-to-motion-estimation-extension-for-opencl</a></p>

</div>







</div>

<div id="footer" class="pagefooter" role="contentinfo">

<div id="pageinfo">






<div id="backlinks">
Links:

<a href="../Beignet.html">Beignet</a>


</div>






<div class="pagedate">


</div>

</div>


<!-- from wiki -->
</div>

</div>

</body>
</html>