Advertisement
BrU32

JS Canvas Trippy Flat Head SRC

Dec 29th, 2016
128
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.38 KB | None | 0 0
  1.  
  2.  
  3. <style>
  4. body{
  5.  
  6. filter:contrast(7733%);
  7.  
  8. }
  9. canvas{
  10. filter:invert(180%)
  11. filter:brightness(206%);
  12.  
  13.  
  14. }
  15. </style>
  16. <center>
  17. <body bgcolor="black" onload="setInterval(Gen,333)">
  18. <video id="video" hidden>
  19. </video>
  20. <canvas id="canvas" width="1000" height="1000"style="opacity:1.0;fillColor:none;">
  21. <script>
  22. var ii=1;
  23. var inn=0;
  24. var video = document.getElementById("video");
  25. var c = document.getElementById("canvas");
  26. var ctx = c.getContext("2d");
  27. var i=0;
  28. var canvas = document.getElementById('canvas');
  29. var context = canvas.getContext('2d');
  30. var video = document.getElementById('video');
  31. var mediaConfig = { video: true,audio:1};
  32. navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
  33. video.src = this.window.URL.createObjectURL(stream);
  34. video.play();
  35. video.addEventListener("play", function() {i = window.setInterval(function() {
  36. canvas.style.opacity=1.0;
  37. canvas.style.opacity=+Math.random()*1.0;
  38. ctx.drawImage(video,1,1,500,50)},inn++);
  39.  
  40. }, false);
  41. });
  42. function Gen()
  43. {
  44. var text = "";
  45. var possible = ""
  46. for(var i=0; i!=6; i++)
  47. text+=possible.charAt(Math.floor(Math.random()*possible.length));
  48. document.body.style.backgroundColor=(text);
  49.  
  50. }
  51. </script>
  52. <center>
  53. <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
  54. <video id="video" autoplay hidden>
  55. </video>
  56. <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
  57. <script>
  58. var ii=10;
  59. var inn=24;
  60. var video = document.getElementById("video");
  61. var c = document.getElementById("canvas");
  62. var ctx = c.getContext("2d");
  63. var canvas = document.getElementById('canvas');
  64. var context = canvas.getContext('2d');
  65. var video = document.getElementById('video');
  66. var mediaConfig = { video: true,audio:false};
  67. function drawe(){
  68. var possible = "FABCGDE0123456789";
  69. var text = "";
  70. var canvas = document.getElementById("canvas");
  71. var ctx = canvas.getContext("2d");
  72. for(var i=0; i!=6; i++)
  73. text+=possible.charAt(Math.floor(Math.random()*possible.length))
  74. ctx.strokeStyle="#"+text;
  75.  
  76. ctx.topmost=false;
  77.  
  78. }
  79. navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
  80. if(ctx.width==500){event.mouseMove++;}
  81. video.src = this.window.URL.createObjectURL(stream);
  82. video.play();
  83. video.addEventListener("play", function() {i = window.setInterval(function() {
  84.  
  85. canvas.style.opacity=1.0;
  86. ctx.topmost=false;
  87. ctx.drawStyle=''
  88. ctx.drawImage(video,Math.random()+80,Math.random())},1);
  89. ctx.drawImage(video,Math.random()+80,Math.random())},1);
  90. ctx.drawImage(video,Math.random()+80,Math.random()},1);
  91. ctx.drawImage(video,1,1,50,50)},inn++);
  92. ctx.draw();
  93. drawe;
  94. }, false);
  95. });
  96. </script>
  97. <script>
  98. var context = new AudioContext();
  99.  
  100. </script>
  101.  
  102. <center>
  103. <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
  104. <video id="video" autoplay hidden>
  105. </video>
  106. <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
  107. <script>
  108. var ii=1;
  109. var video = document.getElementById("video");
  110. var c = document.getElementById("canvas");
  111. var ctx = c.getContext("2d");
  112. var canvas = document.getElementById('canvas');
  113. var context = canvas.getContext('2d');
  114. var video = document.getElementById('video');
  115. var mediaConfig = { video: true,audio:false};
  116. function drawe(){
  117. var possible = "FABCGDE0123456789";
  118. var text = "";
  119. var canvas = document.getElementById("canvas");
  120. var ctx = canvas.getContext("2d");
  121. for(var i=0; i!=6; i++)
  122. text+=possible.charAt(Math.floor(Math.random()*possible.length))
  123. ctx.fillStyle="#"+text;
  124. ctx.beginPath();
  125.  
  126. ctx.fill();
  127. ctx.topmost=true;
  128. ctx.stroke();
  129. text='';
  130. }
  131. var x,t
  132. navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
  133. window.onload=function ( b, c, d)
  134. {
  135. if (t == 0) return b;
  136. if (t == d) return b + c;
  137. if ((t /= d / 2) < 1) return c / 2 * Math.pow(2, 10 * (t - 1)) + b;
  138. return c / 2 * (-Math.pow(2, -10 * --t) + 2) + b;
  139. }
  140. });
  141. if(ctx.width==500){event.mouseMove++;}
  142. video.src = this.window.URL.createObjectURL(stream);
  143. video.play();
  144. video.addEventListener("play", function() {i = window.setInterval(function() {
  145.  
  146.  
  147. ctx.topmost=false;
  148. ctx.drawImage(video,x,t,x,t)},100);
  149. ctx.draw();
  150. drawe;
  151. }, false);
  152. });
  153. </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement