Weitere ähnliche Inhalte
Ähnlich wie JUCEではじめるBLOCKS開発_TOKYO BLOCKS HACKATHON 2018 (20)
JUCEではじめるBLOCKS開発_TOKYO BLOCKS HACKATHON 2018
- 2. 自己紹介
塩澤達矢 / JUCE JAPAN 編集部代表
JUCEとの出会いは2015年末
VSTプラグインを自作する中で、
その強力な開発環境に衝撃を受ける。
素晴らしいフレームワークなのに、
日本語ドキュメントが皆無…。
日本のJUCEユーザーを増やすべく、
非公式ガイド「JUCE JAPAN」を刊行する。
※JUCE JAPAN vol.1/vol.2/2018 がAmazon Kindleにて販売中
- 3. JUCE = Jules' Utility Class Extensions
作者:Julian Storer (Head of Software Architecture @ ROLI)
C++で書かれたクロスプラットフォームライブラリ
対応プラットフォーム:Windows, macOS, Linux, iOS, Android
Projucer = IDE用プロジェクトジェネレータ
各プラットフォームのIDEに対応
VST/Audio Units/RTAS/AAXプラグインが作れる!!
GUIコンポーネントが用意されているからがサクッと実装
プラットフォームに依存しないのも魅力!!
ライセンスは、有償/無償/OSSから選べる
無償で使える、Personal/Education と GPL
常に改良が行われていて、最新のOS, IDEへの対応も早い!!
GitHub:https://github.com/WeAreROLI/JUCE.git
- 19. 2. GitHubリポジトリをクローン
$ git clone https://github.com/WeAreROLI/JUCE.git
・Projucerを自分の環境でビルドしてください
ディレクトリ: JUCE/extras/Projucer
- 21. コードスニペット PluginProcessor.cpp
void xxxAudioProcessor::processBlock (AudioSampleBuffer& buffer, MidiBuffer& midiMessages)
{
ScopedNoDenormals noDenormals;
const int totalNumInputChannels = getTotalNumInputChannels();
const int totalNumOutputChannels = getTotalNumOutputChannels();
for (int i = totalNumInputChannels; i < totalNumOutputChannels; ++i)
buffer.clear (i, 0, buffer.getNumSamples());
for (int channel = 0; channel < totalNumInputChannels; ++channel)
{
float* channelData = buffer.getWritePointer (channel);
const float level = 1.0f;
for (int sample = 0; sample < buffer.getNumSamples(); ++sample)
{
channelData[sample] = sinf (juce::MathConstants<float>::twoPi * sample
/ buffer.getNumSamples() * 2) * level;
}
}
}
- 28. Littlefoot言語(例: BlocksSynthDemo)
class WaveshapeProgram : public Block::Program
{
〜中略〜
String getLittleFootProgram() override {
// 文字列としてLittlefootプログラムを記述する
return R"littlefoot(
#heapsize: 256
int yOffset;
void drawLEDCircle (int x0, int y0)
{
blendPixel (0xffff0000, x0, y0);
int minLedIndex = 0;
int maxLedIndex = 14;
blendPixel (0xff660000, min (x0 + 1, maxLedIndex), y0);
blendPixel (0xff660000, max (x0 - 1, minLedIndex), y0);
blendPixel (0xff660000, x0, min (y0 + 1, maxLedIndex));
blendPixel (0xff660000, x0, max (y0 - 1, minLedIndex));
〜中略〜
)littlefoot";
}
}