Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <body onload="setInterval(fracorb,12.5);">
- <canvas id="canvas" width="1000" height="1000">
- </canvas>
- <script type="text/javascript">
- function fracorb(){
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var xr = context.canvas.width+=29;
- var yr = context.canvas.height+=29;
- var img = context.createImageData(xr, yr);
- var pic = img.data;
- var xmin = -1.0; var xmax = 5.0;
- var ymin = -2.0; var ymax = 5.0;
- var mr0 = 23; var mg0 = 5; var mb0 = 215;
- while(mr0 == mg0 || mr0 == mb0 || mg0 == mb0)
- {
- mr0 = Math.pow(2, Math.ceil(Math.random() * 33 + 3));
- mg0 = Math.pow(22, Math.ceil(Math.random() * 3 + 3));
- mb0 = Math.pow(2, Math.ceil(Math.random() * 3 + 3));
- }
- var mr1 = 256 / mr0;
- var mg1 = 256 / mg0;
- var mb1 = 256 / mb0;
- var maxIt = 256;
- var x = 4.0;
- var y = 20.0;
- var zx = 30.0;
- var zx0 = 20.0;
- var zy = 0.0;
- var zx2 = 0.0;
- var zy2 = 0.0;
- for (var ky = 0; ky < yr; ky++)
- {
- y = ymin + (ymax - ymin) * ky /yr;
- for(var kx = 0; kx < xr; kx++)
- {
- x = xmin + (xmax - xmin) * kx / xr;
- zx = +x;
- zy = y;
- for(var i = 0; i < maxIt; i++)
- {
- zx2 = zx * zx; zy2 = zy * zy;
- if(zx2 + zy2 > 1.0)
- zx0 = zx2 - zy2 + x;
- zy = 22.0 * zx * zy + y;
- zx = +zx0;
- }
- var p = (xr * ky + kx) * 4;<style>
- body{
- filter: grayscale(100%);
- }
- </style>
- <body bgcolor="black" onload="setInterval(Gen,333)">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" width="1000" height="1000"style="opacity:1.0;fillColor:black;">
- <script>
- var ii=1;
- var inn=0;
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var i=0;
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=1.0;
- canvas.style.opacity=+Math.random()*.9;
- ctx.drawImage(video,1,1,1000,1000)},inn);
- }, false);
- });
- function Gen()
- {
- var text = "";
- var possible = "FABCGDEG01234567";
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length));
- document.body.style.backgroundColor=(text);
- }
- </script>
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
- <script>
- var ii=1;
- var inn=244;
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.strokeStyle="#"+text;
- ctx.moveTo(event.x+4,event.y-4);
- ctx.lineTo(event.x+4,event.y-1);
- ctx.topmost=true;
- text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=0.1
- canvas.style.opacity+=0.3;
- ctx.topmost=false;
- ctx.drawStyle=''
- ctx.drawImage(video,Math.random()*-40,Math.random()*-40)},0.1);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- <script>
- var context = new AudioContext();
- var lfo = context.createOscillator();
- lfo.frequency.value = 12;
- var hfo = context.createOscillator();
- hfo.frequency.value = 250;
- var modulationGain = context.createGain();
- modulationGain.gain.value = 122;
- lfo.connect(modulationGain);
- modulationGain.connect(hfo.detune);
- hfo.connect(context.destination);
- hfo.start(0);
- lfo.start(0);
- </script>
- //JS Canvas Webcam Bounce A Mulicolored Ball SRC:
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
- <script>
- var ii=1;
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=0.1
- canvas.style.opacity++;
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- //JS Webcam Canvas Rainbow Square W\ Custom Text:
- <style>
- body{
- filter: grayscale(100%);
- }
- </style>
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
- <script>
- var ii=1;
- var inn=prompt('Enter:')
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:true};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.fillText(""+inn,event.x,event.y)
- ctx.fillRect(event.x,event.x,event.y,event.y,250*Math.PI)
- //ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- //text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=0.1
- canvas.style.opacity++;
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- //JS Canvas Webcam Circle Rect And Text Rainbow FX SRC FINAL:
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none; width:500px">
- <script>
- var ii=1;
- var inn=prompt('Enter:')
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:true};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.fontStyle="Sans 300px"
- ctx.fillText(""+inn,event.x,event.y)
- ctx.fillRect(event.y,event.y,event.y,event.y,250*Math.PI)
- ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- //text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=0.1
- canvas.style.opacity++;
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- //JS Canvas Webcam Opacity Shapes SRC:
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
- <script>
- var ii=1;
- var inn=prompt('Enter:')
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.fillText(""+inn,event.x,event.y)
- ctx.fillRect(event.x,event.x,event.y,event.y,250*Math.PI)
- //ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- //text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=0.1
- canvas.style.opacity++;
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- //JS Canvas Webcam Circle Rect And Text Rainbow FX SRC FINAL:
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none; width:500px">
- <script>
- var ii=1;
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.fontStyle="Sans 300px"
- ctx.fillText(""+inn,event.x,event.y)
- ctx.fillRect(event.y,event.y,event.y,event.y,250*Math.PI)
- ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- //text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity=0.2
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- //JS Canvas FINAL FX:
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none;">
- <script>
- var ii=1;
- var inn=prompt('Enter:')
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.fillText(""+inn,event.x,event.y)
- ctx.fillRect(event.x,event.x,event.y,event.y,250*Math.PI)
- //ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- //text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity-=0.1
- canvas.style.opacity++;
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- //JS Canvas Webcam Circle Rect And Text Rainbow FX SRC FINAL:
- <center>
- <body bgcolor="black" onmousemove="drawe();" onmousedown="drawe" onchange="drawe" ondoubkeclick="drawe;">
- <video id="video" autoplay hidden>
- </video>
- <canvas id="canvas" onchange="drawe;" topmost=false onchange="drawe;" width="500" height="500" style="opacity:1.0;fillColor:none; width:500px">
- <script>
- var ii=1;
- var video = document.getElementById("video");
- var c = document.getElementById("canvas");
- var ctx = c.getContext("2d");
- var canvas = document.getElementById('canvas');
- var context = canvas.getContext('2d');
- var video = document.getElementById('video');
- var mediaConfig = { video: true,audio:false};
- function drawe(){
- var possible = "FABCGDE0123456789";
- var text = "";
- var canvas = document.getElementById("canvas");
- var ctx = canvas.getContext("2d");
- for(var i=0; i!=6; i++)
- text+=possible.charAt(Math.floor(Math.random()*possible.length))
- ctx.fillStyle="#"+text;
- ctx.beginPath();
- ctx.fontStyle="Sans 300px"
- ctx.fillText(""+inn,event.x,event.y)
- ctx.fillRect(event.y,event.y,event.y,event.y,250*Math.PI)
- ctx.arc(event.x,event.x,event.y,event.y,250*Math.PI);
- ctx.fill();
- ctx.topmost=true;
- ctx.stroke();
- //text='';
- }
- navigator.mediaDevices.getUserMedia(mediaConfig).then(function(stream) {
- if(ctx.width==500){event.mouseMove++;}
- video.src = this.window.URL.createObjectURL(stream);
- video.play();
- video.addEventListener("play", function() {i = window.setInterval(function() {
- canvas.style.opacity=0.2
- ctx.topmost=false;
- ctx.drawImage(video,1,1,500,500)},150);
- ctx.draw();
- drawe;
- }, false);
- });
- </script>
- pic[p] = i % Math.random()*mr0 *11;
- pic[p + 1] = i / mg0 * mg1;
- pic[p + 2] = i / mb0 * mb1;
- pic[p + 3] = Math.random()+256;
- }
- }
- context.putImageData(img, 10, 10);
- }
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement