IBM Developer is your one-stop location for getting hands-on training and learning in-demand skills on relevant technologies such as generative AI, data science, AI, and open source.
Browsers have come a long way over the years, and we are now able to achieve amazing results using all of the great new technologies often referred to as HTML5. However, generally speaking, audio still sucks. Thankfully, Google decided to create Web Audio API and make all our lives easier. The problem is that only the latest browsers support this new-fangled browser audio, so what are we to do? We
基本 関数 process(L, R) の定義されたオブジェクトを用意 L と R の型は Float32Array です pico.play(gen); で処理開始 gen.process(L, R) が呼ばれるので L と R に信号を書き込みます pico.pause(); で処理停止 静寂に戻るまでが音楽です ex.01 Pause Play // ホワイトノイズを出力する var noise = { process: function(L, R) { for (var i = 0; i < L.length; i++) { L[i] = R[i] = Math.random() * 0.25; } } }; pico.play(noise); その他の便利な機能 サンプリングレートの変更 pico.setup({samplerate:24000}) サンプリングレートは 8000
WAMI recorderはJavaScriptから操作可能なFlash製の音声録音、再生ライブラリです。 HTML5が浸透しつつありますが、逆にJavaScriptでは出来ないもどかしい部分も明確になってきています。その一つにマイクロフォンへのアクセスがあります。しかしそんな時こそFlashと連携させれば良いのです。WAMI recorderを使えばオンラインの録音、再生環境が容易に実現します。 アクセス許可を求めるダイアログが出ます。 左側が録音、右側が再生ボタンになります。 WAMI recorderはごくシンプルなUIでボタンを押して録音、再生ができます。JavaScript向けのAPIも提供されていますのでWeb上で録音、再生環境が実現できるでしょう。WAMI recorderは録音したデータをPOSTで指定したURLに飛ばせるようになっています。その音声データを使えば面白いサー
FizzBuzzというプログラムがあります。1 - 2 ときて Fizz、つぎに 4 ときて Buzz、そして 12 - 13 - 14ときて FizzBuzz ですね。タイマーを使ってJavaScriptで書いたらこんな感じ。 Fizz Buzz var count = 0; function fizzbuzz() { count += 1; if (count % 15 === 0) { console.log("FizzBuzz"); } else if (count % 5 === 0) { console.log("Buzz"); } else if (count % 3 === 0) { console.log("Fizz"); } else { console.log(count); } } setInterval(fizzbuzz, 600); プログラミングの最初の方の課
dancer.js JavaScript Audio Library toggle FFT spectrum view API/source by jordan santell Now playing... Zircon - Devil's Spirit Loading . . .
UnitePlayer はモバイルとゲームに特化した HTML5 な音楽再生プレイヤー UnitePlayer は、モバイルブラウザ上で動作するゲームに音をもたらします。 扱いが難しい Mobile Safari や Android ブラウザの音周りをフォーマット化し、とっても扱いやすくします。 フィーチャーフォン用のソーシャルゲームが大流行な昨今ですが、 フィーチャーフォン用のゲームって音が無いですよね? そのゲームをそのままスマートフォン向けにコンバートしても、音がならずに寂しい感じですよね? 2012年は UnitePlayer で BGM も SE も鳴らしちゃいましょう。 そして没入感や色々なものを高めちゃいましょう! PCブラウザでもそのまま動くから、横展開もお手軽に! UnitePlayer なら iPhone でも BGM と SE を擬似的に同時再生できますよ。 Unit
IE6/7/8, Firefox, Operaを含む主要ブラウザ全てに、HTML5のaudio要素を使ってMP3を再生できるようにするスクリプトを紹介します。 audio.js デモページ [ad#ad-2] audio要素のサポート状況 audioはHTML5の要素で、サポートしているブラウザは限られたものとなっています。 audio要素のブラウザのサポート状況 IE9 Firefox 3.5+ Chrome Safari Opera 9.6+ また、対応している音声ファイルのフォーマットも異なり、現在音声ファイルの主流のMP3はChromeのみが対応しています(Safariも一応再生可)。 「audio.js」は、audio要素に非対応のIE6/7/8、MP3に非対応のFirefox, Safari, Operaで、audio要素を使ってMP3ファイルを再生できるようにします。 [ad
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く