Advertisement
BrU32

JS Canvas Webcam Super Dope FLIR SRC

Nov 18th, 2016
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.93 KB | None | 0 0
  1. <style>
  2. body{
  3. overflow: visible;
  4. position:center;
  5. width: 100%;
  6. height: 100%;
  7. filter:invert(1.0);
  8. }
  9. .container{
  10. position: center;
  11. width: Math.random()*5vmax+1vmax;
  12. height: Math.random()*15vmax+10vmax;
  13. top: 50%;
  14. left: 50%;
  15. }
  16. </style>
  17. <canvas id="canvas" width='1000' height='1000'></canvas>
  18. <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubleclick="drawe;">
  19.  
  20. <br>
  21. <video id="video" autoplay hidden>
  22. </video>
  23. <canvas id="canvas" width="1000" height="1000"style="opacity:0.0;fillColor:none;">
  24. <script>
  25. var ii=444;
  26. var video = document.getElementById("video");
  27. var c = document.getElementById("canvas");
  28. var ctx = c.getContext("2d");
  29. var canvas = document.getElementById('canvas');
  30. var context = canvas.getContext('2d');
  31. var video = document.getElementById('video');
  32. var mediaConfig = { video: true,audio:false};
  33. function zoomin(){
  34. ii+=5;
  35. }
  36. function zoomout(){
  37. ii-=5;
  38. }
  39. navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
  40. video.src = this.window.URL.createObjectURL(stream);
  41. video.play();
  42. video.addEventListener("play", function() {i = window.setInterval(function() {
  43. canvas.style.opacity+=1233.9;
  44. ctx.drawImage(video,ii--,Math.random()*500,ii-1,Math.random()*ii)},1);
  45. ctx.draw();
  46. drawe();
  47. }, false);
  48. });
  49. </script>
  50. </center>
  51. function PauseIt(mp3){
  52. var aud=document.getElementById("aud");
  53. aud.playbackRate=1.0;
  54. aud.volume=1.0;
  55. aud.pause();
  56. }
  57. function MuteIt(){
  58. var aud=document.getElementById("aud");
  59. aud.volume=.0;
  60. }
  61. function UnMuteIt(){
  62. var aud=document.getElementById("aud");
  63. aud.volume=1.0;
  64. }
  65. function PlayIt(mp3){
  66. mp3=prompt("Enter URL:");
  67. var aud=document.getElementById("aud");
  68. aud.src=mp3;
  69. aud.playbackRate=1.0;
  70. aud.volume=1.0;
  71. aud.play();
  72. }
  73.  
  74. function StopIt(){
  75. var aud=document.getElementById("aud");
  76. aud.src='';
  77. aud.playbackRate=1.0;
  78. aud.volume=1.0;
  79. aud.play();
  80. }
  81. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement