Raspberry Pi2 & openFrameworks TIPS
ofxRPiCameraVideoGrabber
Sampleをmakeすると
could not convert ‘ofGLProgrammableRenderer::TYPE’ from ‘const string {aka const std::basic_string<char>}’ to ‘std::shared_ptr<ofBaseRenderer>’ ofSetCurrentRenderer(ofGLProgrammableRenderer::TYPE);
とでる。
こちらを参考にmain.cppを以下に変更
int main{ ofGLESWindowSettings settings; settings.width = <span class="hljs-number">1280</span>; settings.height = <span class="hljs-number">720</span>; settings.setGLESVersion(<span class="hljs-number">2</span>); ofCreateWindow(settings); ofRunApp( <span class="hljs-keyword">new</span> testApp()); }
でmake成功した
makeオプション指定を楽にする
makeする時にいちいち、オプション指定するのが面倒くさいので
cd ls -a
で表示される
.profile
に
nano .profile
してnanoでオープンして
export MAKEFLAGS=-j4 PLATFORM_VARIANT=rpi2
と書き込むと
openFrameworksのExampleフォルダ等で
make
するだけで、コンパイルが走る!
GPIOの番号を表示
gpio readall
openFrameworksからgpioを使う場合は、wiringPiを使うようです。GPIOの番号は、Raspberry PiとwiringPiで割当が違うようで番号を調べてる中で、上記のコマンドを見つけました。
接続されているI2Cデバイスを探す
i2cdetect -y 1
addonの追加
addonフォルダにて
git clone 使いたいofxAddonのリポジトリURL
プロジェクトフォルダのaddons.makeにAddon名を記入
ofxAddon
debug
Program received signal SIGILL, Illegal instruction と出て起動時に止まってしまう問題。gdbで以下のコマンドを打つと取り敢えず回避できる。
handle SIGILL nostop handle SIGINT nonstop
Recent entries
- jit.gl.gridshape の matrixoutput についてのメモ #max8
- jit.gl.pix で簡易モーションブラー #max8 #jitter
- jit.gl.pix で Gold Noise #max8 #jitter
- Gen で配列をつくる検討 #Max8
- Package Managerで配布されているease objectを使いやすくしてイージング #max8
- Node for Max を用いて、定形外のUDPデータを受信 #Max8 #n4m
- 平ハウス物語 – 山田尚子監督作品 非公式ファンイベント
- The Splendid Expression – GITADORA×NOSTALGIA
- ghost in my place【from DEEMO II】
- EP “Boys O’Clock”
- 7th Album “多次元宇宙論”
- LEON.jpのWEB特集「大人のいい時間」にAromが紹介されました。
- 音できらめくキャンドルライト Arom(第2世代)発売開始
- EP “Strange Story”
- 都市の呼吸【from Cytus II】