This file contains 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 "TwitterStream.h" | |
#include <sstream> | |
#include <iostream> | |
#define CHECK_CURL_ERROR(result) if((result) != CURLE_OK) { printf("Curl error: %s.\n", curl_easy_strerror((result))); return false; } | |
#define CHECK_CURLM_ERROR(result) if((result) != CURLM_OK) { printf("Curl multi error: %s.\n", curl_multi_strerror((result))); return false; } | |
using std::stringstream; | |
namespace roxlu { |
This file contains 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
on appIsRunning(appName) | |
tell application "System Events" to (name of processes) contains appName | |
end appIsRunning | |
on hideDock() | |
tell application "System Events" | |
keystroke "d" using [command down, option down] | |
end tell | |
end hideDock |
This file contains 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
/* | |
struct VertexP : public Vertex { }; | |
struct VertexPT : public Vertex { }; | |
struct VertexPN : public Vertex { }; | |
struct VertexPNC : public Vertex { }; | |
struct VertexPTN : public Vertex { }; | |
struct VertexPTNC : public Vertex { }; | |
struct VertexPTNT : public Vertex { // with tangent. }; | |
struct VertexPTNTB : public Vertex { // can be used for normal mapping |
This file contains 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 "Cards.h" | |
Cards::Cards(rb::World& w) | |
:world(w) | |
{ | |
} | |
Cards::~Cards() { | |
} | |
void Cards::create() { |
This file contains 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 "Cards.h" | |
Cards::Cards(rb::World& w) | |
:world(w) | |
{ | |
} | |
Cards::~Cards() { | |
} | |
void Cards::create() { |
This file contains 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 "Cards.h" | |
Cards::Cards(rb::World& w) | |
:world(w) | |
{ | |
} | |
Cards::~Cards() { | |
} | |
void Cards::create() { |
This file contains 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 "testApp.h" | |
void testApp::setup(){ | |
ofBackground(33); | |
ofSetVerticalSync(true); | |
take_screenshot = false ; | |
// create quad width size "s", centered | |
float s = 1; | |
float hs = s * 0.5; |
This file contains 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
// create VBO | |
VertexP* vertex_data = plane_data.getVertexP(); | |
glGenBuffers(1, &plane_vbo); eglGetError(); | |
glBindBuffer(GL_ARRAY_BUFFER, plane_vbo); eglGetError(); | |
glBufferData(GL_ARRAY_BUFFER, sizeof(VertexP) * plane_data.size(), vertex_data, GL_STATIC_DRAW); eglGetError(); |
This file contains 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
uniform mat4 projection_matrix; | |
uniform mat4 view_matrix; | |
attribute vec4 pos; | |
void main() { | |
gl_Position = projection_matrix * view_matrix * pos; | |
} |
This file contains 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 main() { | |
gl_FragColor = vec4(1.0, 0.0, 0.4, 1.0); | |
} |