This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "ofMain.h" | |
| void enableMidmap(ofTexture& texture) { | |
| texture.bind(); | |
| int textureTarget = texture.getTextureData().textureTarget; | |
| glTexParameteri(textureTarget, GL_TEXTURE_MAG_FILTER, GL_LINEAR); | |
| glTexParameteri(textureTarget, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR); | |
| glGenerateMipmap(GL_TEXTURE_2D); // automatically creates midmaps for textures | |
| texture.unbind(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| telnet localhost 12345 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| make clean | |
| make Release | |
| sudo chmod a+x app_binary |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| diskutil list | |
| diskutil unmountDisk /dev/disk3 | |
| // snappy ubuntu core | |
| sudo dd bs=1m if=~/Downloads/pi-snappy.img of=/dev/disk3 | |
| // raspbian | |
| sudo dd bs=1m if=~/Downloads/2015-01-31-raspbian.img of=/dev/disk3 | |
| // retropie (assumes .img is in Downloads folder) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // 1 update gcc to 4.8 | |
| sudo apt-get install g++-4.8 | |
| cd /usr/bin | |
| sudo rm g++ | |
| sudo ln -s g++-4.8 g++ | |
| // 1 download OF (from github or stable linuxarm7l release with https://github.com/openframeworks/openFrameworks/blob/master/libs/openFrameworksCompiled/project/linuxarmv7l/config.linuxarmv7l.rpi2.mk) | |
| cd ~ | |
| curl -o https://github.com/openframeworks/openFrameworks/archive/master.zip | |
| curl -o http://www.openframeworks.cc/versions/v0.8.4/of_v0.8.4_linuxarmv7l_release.tar.gz |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| - (void)updateData:(NSTimer*)timer { | |
| // if already getting data do nothing | |
| if(!self.isFetchDataComplete) { | |
| NSLog(@"Do not get data - flag is OFF..."); | |
| return; | |
| } | |
| // reset the flag | |
| self.isFetchDataComplete = FALSE; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cd rockhamptongallery | |
| heroku git:remote -a rockhampton-web | |
| //should list two remotes, origin/github and heroku | |
| git remote -v | |
| middleman build | |
| git add -f app/build # -f because we are ignoring git dir | |
| git push heroku develop:master # heroku only works with master branch, so push our develop onto their master. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| git clone http://github.com/trentbrooks/someproject | |
| git bundle create someproject.bundle --all | |
| - need to zip assets if not in archive | |
| - if OF, might need details about which version and addons |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #ifdef __OBJC__ | |
| ofAVFoundationVideoPlayer* p = (ofAVFoundationVideoPlayer*)videoPtr->getAVFoundationVideoPlayer(); | |
| if(p != nullptr) { | |
| double timeSec = CMTimeGetSeconds([p getCurrentTime]) - (1.0/[p getFrameRate]); | |
| CMTime time = CMTimeMakeWithSeconds(timeSec, NSEC_PER_SEC); | |
| [p seekToTime:time withTolerance:kCMTimeZero]; | |
| } | |
| #endif |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // 1. go into github repo via terminal | |
| cd brighthearts-beta | |
| // 2. check which branch your on - eg. HPV-Vaccine | |
| git branch | |
| // 3. delete all your local changes, and reset to what is on github | |
| git reset --hard HEAD | |
| // 4. pull down the latest changes |