Lucas Stadler преди 11 години
родител
ревизия
eb99f2b18e
променени са 1 файла, в които са добавени 8 реда и са изтрити 1 реда
  1. 8 1
      js/camera.html

+ 8 - 1
js/camera.html

@ -1,4 +1,11 @@
1
<p>(Intentionally left blank, take a look at the console.)</p>
1
<p>Quickstart: After you allow camera access there will be an image
2
in the <code>img</code> variable. <code>getImage();</code> takes a new
3
images, stores it there and returns it.</p>
4
5
<p><code>img</code> is of the type <a href="https://developer.mozilla.org/en/docs/Web/API/ImageData">ImageData</a>
6
and <code>img.data</code> contains the (flattened, rgba) pixel values.</p>
7
8
<p>Now go and do something with it! Have fun!</p>
2 9
3 10
<script>
4 11
  navigator.getUserMedia = navigator.getUserMedia || navigator.mozGetUserMedia || navigator.webkitGetUserMedia;