Code 7
How do I make an code 7?
Drop a line and press play. You can use all Math functions directly.. What is a code 7? How do you make a code 7? This script and codes were developed by André Michelle on 18 October 2022, Tuesday.
Code 7 - Script Codes HTML Codes
<!DOCTYPE html>
<html >
<head> <meta charset="UTF-8"> <title>Code 7</title> <link rel="stylesheet" href="css/style.css">
</head>
<body> <h1>Code 7</h1>
<h5>drop your music</h5>
<input type="button" onclick="togglePlayback();" value="START" id="toggle-button"></input><canvas id="waveform" width="384" height="32"></canvas>
<textarea type="text" oninput="compile();" onLoad="focus(this);" onBlur="focus(this);" name="dsp" id="dsp"></textarea>
<label id="message"></label> <script src="js/index.js"></script>
</body>
</html>
Code 7 - Script Codes CSS Codes
html, body { background: #1A1A1A; margin: 0; padding: 16px; width: 90%; height: 80%; color: #16d6ff; font-size: 16px; font-family: "Open Sans"; overflow: hidden;
}
h1 { line-height: 0px;
}
textarea#dsp { width: 99%; height: 5em; color: #16d6ff; font-size: 12px; line-height: 14px; background: black; border-width: 0; margin: 0; padding: 4px; border: none; overflow: auto; outline: none; -webkit-box-shadow: none; -moz-box-shadow: none; box-shadow: none; resize: none;
}
textarea::selection { background: #999999;
}
canvas { float: right; background-color: black;
}
input#toggle-button { width: 64px; height: 32px; border: 0; color: #16d6ff; margin-bottom: 8px; background: black; border-color: transparent; cursor: pointer; outline: 0;
}
label { color: #ff6616; font-size: 10px;
}
Code 7 - Script Codes JS Codes
// Minimal Audio Driver
//
var audioContext = new (window.AudioContext || window.webkitAudioContext)();
var sampleRate = audioContext.sampleRate;
var seconds = 0.0;
var scriptProcessor = audioContext.createScriptProcessor( 2048, 1, 1 );
var bufferSize = scriptProcessor.bufferSize;
scriptProcessor.onaudioprocess = function ( event )
{ var data = event.outputBuffer.getChannelData( 0 ); for( var i = 0 ; i < bufferSize ; ++i ) data[i] = f( seconds += 1.0 / sampleRate ); render(data);
};
var e = document.getElementById( "dsp" );
var m = document.getElementById( "message" );
var b = document.getElementById( "toggle-button" );
var w = document.getElementById( "waveform" );
var f = function (t) { return 0.0 };
var isPlaying = false;
function togglePlayback()
{ if( isPlaying ) { scriptProcessor.disconnect( audioContext.destination ); isPlaying = false; b.value = "PLAY"; } else { seconds = 0.0; scriptProcessor.connect( audioContext.destination ); isPlaying = true; b.value = "STOP"; }
}
function render(values)
{ var width=w.width; var height=w.height; var heightHalf=height/2; var ratio=bufferSize/width; var ctx=w.getContext("2d"); ctx.clearRect(0,0,width,height); ctx.lineWidth=0.0; ctx.strokeStyle='#16d6ff'; ctx.beginPath(); ctx.moveTo(0,heightHalf+values[0]*heightHalf); for(var x=0;x<width;++x) ctx.lineTo(x,heightHalf+Math.min(1,Math.max(-1,values[Math.floor(x*ratio)]))*heightHalf); ctx.stroke();
}
function compile()
{ try{f=new Function('t',"with(Math){"+e.value+"}");m.innerHTML="";} catch(e){m.innerHTML=e.message;}
}
e.value="var q=1-(t*2.15)%1,s=sin,p=pow;\nreturn s(24*p(q,24))*.9+3*s(p((q*4)%1,5)*3)*min(.1,max(-.1,(6+s(t*.5)*3)*s(40*(1+q)*s(690+q*3))));";
e.focus();
compile();
Developer | André Michelle |
Username | andremichelle |
Uploaded | October 18, 2022 |
Rating | 4 |
Size | 2,837 Kb |
Views | 22,264 |
Find the perfect freelance services for your business! Fiverr's mission is to change how the world works together. Fiverr connects businesses with freelancers offering digital services in 500+ categories. Find Developer!
Name | Size |
Animated text on bezier curve | 2,252 Kb |
Web Audio Api Equalizer | 2,606 Kb |
Dub Techno Chords | 3,909 Kb |
Instable Connection | 2,828 Kb |
Web Audio Api HardLimiter | 2,697 Kb |
Battery Api | 2,899 Kb |
Happy PI Day | 2,402 Kb |
Web Audio Api MultiBandCompressor | 3,553 Kb |
Sonic Brain Food | 2,234 Kb |
Web Audio Api Convolver | 3,023 Kb |
Jasper is the AI Content Generator that helps you and your team break through creative blocks to create amazing, original content 10X faster. Discover all the ways the Jasper AI Content Platform can help streamline your creative workflows. Start For Free!
Name | Username | Size |
Static Image to Video Block | Grayghostvisuals | 4,864 Kb |
No Vacancy 404 CSS Only | Sethkontny | 0 Kb |
Material design - button rainbow circle | Kunukn | 3,652 Kb |
Foundation 5 Menu - Accessibility | Xporter | 1,999 Kb |
Personal Logo Animation | Lloydwheeler | 3,795 Kb |
Lightning | Akm2 | 19,150 Kb |
Twitch API | Coderpilot | 3,412 Kb |
Next Word Predictor | Rfalor | 2,776 Kb |
Alumni ECA | MatheusLima92 | 3,777 Kb |
Sticky Navbar | Phantomesse | 5,106 Kb |
Surf anonymously, prevent hackers from acquiring your IP address, send anonymous email, and encrypt your Internet connection. High speed, ultra secure, and easy to use. Instant setup. Hide Your IP Now!