Quantcast
Channel: beginners - openFrameworks
Viewing all 4929 articles
Browse latest View live

ofxColorSlider - How to adjust values for colour sliders?


Is that support unity?

$
0
0

@HiYang_Chan wrote:

Is that support unity engine?

I want to ask if I build ofimage framework dll for uinty ,can use getTexture convert to unity Texture2d?

use API getTexture() or getPixels? and then SetPixels to unity ?

Posts: 1

Participants: 1

Read full topic

[solved] Stitching PNG images and save it

$
0
0

@jrengmusic wrote:

Hi

I'm creating a very simple apps which have only one purpose, to stitch a series of PNG images (with alpha) and append them vertically and sequentially.

void ofApp::stitch(ofDirectory _dir){
  size_t size;
  string folder_name;
  vector <string> folder_path;
  vector <ofImage> img;
  ofFbo       compose;
  ofPixels    pixels;
  folder_path = ofSplitString(_dir.getAbsolutePath(), "/");
  folder_name = folder_path[folder_path.size()-1]; //get folder name
  cout << folder_name << endl;
  cout << _dir.getAbsolutePath() << endl;
  size = _dir.listDir();
  _dir.allowExt("png");
  _dir.sort();
  img.assign(_dir.getFiles().size(), ofImage());
  for (int i=0; i<size; i++) {
    img[i].load(_dir.getFile(i));
  }
  compose.allocate(img[0].getWidth(), img[0].getHeight()*img.size(), GL_RGBA);
  pixels.allocate(img[0].getWidth(), img[0].getHeight()*img.size(), OF_IMAGE_COLOR);
  ofClear(0, 0, 0, 0); // 0 is important
  pixels.clear();
  compose.begin();
  int dy = 0;
  for (int i = 0; i<img.size(); i++) {
    img[i].draw(0,dy);
    dy += img[i].getHeight();
  }
  compose.end();
  //get the frame buffer pixels
  compose.readToPixels(pixels);
  ofSaveImage(pixels, folder_name + ".png", OF_IMAGE_QUALITY_BEST);
}

But i always get weird final result. Sometimes i get weird random color pixels, even if it stitch correctly sometimes the colors are different from the image sources.

I have tried to move the ofClear after the ofFbo.begin()

compose.begin();
ofClear(0, 0, 0, 0); // 0 is important
 ...
compose.end()

No artifact or glitch, but the image result looks thinner (in opacity), not as bold as the original image.

I'm really new at openframeworks and with C++ :grin:

How can i append the images correctly with same exact pixel color with its sources?

Thanks

Posts: 2

Participants: 1

Read full topic

Errors about GLM sytax when using ofxShadowMap addon

$
0
0

@jerryleung wrote:

I am a total beginner of OF. I just started 1 month ago.

And I am using Visual Studio 2015....

Today I tried to play around with the add on ofxShadowMap. I just copied the examples and try to build it. Yet, I got a lot of error messages about GLM.

Thought there are other errors but I have the feeling that I need to fix the GLM error first. I would like to know how I can fix it.

Thanks in advance.

PS the followings are the errors when trying to build the example project

Severity	Code	Description	Project	File	Line	Suppression State
Error (active)		name followed by '::' must be a class or namespace name	171022-shadowmaptest	f:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	18
Error	C3861	'angleAxis': identifier not found	171022-shadowmaptest	F:\studying\siberian federal university\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	18
Error	C2653	'glm': is not a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	238
Error	C2653	'glm': is not a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	239
Error	C2653	'glm': is not a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	241
Error	C2653	'glm': is not a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	18
Error	C2653	'glm': is not a class or namespace name (compiling source file ..\..\..\addons\ofxShadowMap-master\src\ofxShadowMap.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxshadowmap-master\src\ofxShadowMap.h	39
Error	C2653	'glm': is not a class or namespace name (compiling source file src\main.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error	C2653	'glm': is not a class or namespace name (compiling source file src\ofApp.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error	C3861	'inverse': identifier not found	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	239
Error	C2065	'lastBiasedMatrix': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	246
Error	C2065	'lastBiasedMatrix': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	270
Error	C3646	'lastBiasedMatrix': unknown override specifier (compiling source file ..\..\..\addons\ofxShadowMap-master\src\ofxShadowMap.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxshadowmap-master\src\ofxShadowMap.h	39
Error	C3646	'lastBiasedMatrix': unknown override specifier (compiling source file src\main.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error	C3646	'lastBiasedMatrix': unknown override specifier (compiling source file src\ofApp.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error	C2065	'listener': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	20
Error	C3646	'listener': unknown override specifier (compiling source file src\main.cpp)	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.h	46
Error	C3646	'listener': unknown override specifier (compiling source file src\ofApp.cpp)	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.h	46
Error	C3861	'mat4': identifier not found	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	241
Error	C2039	'newListener': is not a member of 'ofParameter<bool>'	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	20
Error	C2065	'NoDefaults': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	248
Error	C2653	'ofFboBeginMode': is not a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	248
Error	C2665	'ofLoadMatrix': none of the 2 overloads could convert all the argument types	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	251
Error	C2039	'orbitDeg': is not a member of 'ofLight'	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	41
Error	C3536	'ortho': cannot be used before it is initialized	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	238
Error	C2039	'setCustomUniform1f': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	271
Error	C2039	'setCustomUniform1f': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	272
Error	C2039	'setCustomUniform1f': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	273
Error	C2039	'setCustomUniform1f': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	274
Error	C2039	'setCustomUniform1i': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	281
Error	C2039	'setCustomUniformMatrix4f': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	270
Error	C2039	'Settings': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	214
Error	C2065	'Settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	214
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	214
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	215
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	216
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	217
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	218
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	219
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	220
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	228
Error	C2065	'settings': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	229
Error	C2039	'setup': is not a member of 'ofMaterial'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	229
Error	C2065	'vec3': undeclared identifier	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	18
Error	C3536	'viewProjection': cannot be used before it is initialized	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	246
Error (active)		class "ofLight" has no member "orbitDeg"	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	41
Error (active)		class "ofParameter<bool>" has no member "newListener"	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	20
Error (active)		expected a ')'	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	18
Error (active)		identifier "ofEventListener" is undefined	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.h	46
Error	C2228	left of '.ambient' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	215
Error	C2228	left of '.customUniforms' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	220
Error	C2228	left of '.diffuse' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	216
Error	C2228	left of '.emissive' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	217
Error	C2228	left of '.postFragment' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	228
Error	C2228	left of '.shininess' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	219
Error	C2228	left of '.specular' must have class/struct/union	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	218
Error	C4430	missing type specifier - int assumed. Note: C++ does not support default-int (compiling source file ..\..\..\addons\ofxShadowMap-master\src\ofxShadowMap.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxshadowmap-master\src\ofxShadowMap.h	39
Error	C4430	missing type specifier - int assumed. Note: C++ does not support default-int (compiling source file src\main.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error	C4430	missing type specifier - int assumed. Note: C++ does not support default-int (compiling source file src\main.cpp)	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.h	46
Error	C4430	missing type specifier - int assumed. Note: C++ does not support default-int (compiling source file src\ofApp.cpp)	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error	C4430	missing type specifier - int assumed. Note: C++ does not support default-int (compiling source file src\ofApp.cpp)	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.h	46
Error (active)		name followed by '::' must be a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.h	39
Error (active)		name followed by '::' must be a class or namespace name	171022-shadowmaptest	F:\model\openframeworks\apps\171022-shadowmaptest\171022-shadowmaptest\src\ofApp.cpp	18
Error	C2146	syntax error: missing ';' before identifier 'settings'	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	214
Error	C2064	term does not evaluate to a function taking 6 arguments	171022-shadowmaptest	F:\model\openframeworks\addons\ofxShadowMap-master\src\ofxShadowMap.cpp	238

Posts: 1

Participants: 1

Read full topic

Unwanted pixelisation

$
0
0

@nctr wrote:

Hello,

I'm encountering a problem with a basic processing chain and need some help as I'm stuck and don't understand what happens.

I would like to write texcoords on the target of a fbo within my first shader, then use this texture to read and display an image with my second shader. The goal is to make some king of pixel drifting by manipulating texcoords.
But using a texture to read texcoords give me an unwanted pixelisation effect.

//========================================================================
int main( ){

    ofGLFWWindowSettings gl_settings;
    gl_settings.setGLVersion( 3, 2 );
    gl_settings.width = 1920;
    gl_settings.height = 1080;
    gl_settings.visible = true;
    gl_settings.decorated = false;
    gl_settings.numSamples = 2;

    shared_ptr<ofAppBaseWindow> of_main_window = ofCreateWindow(gl_settings);
    shared_ptr<ofApp> of_main_app(new ofApp());

    ofDisableArbTex();

    ofRunApp( of_main_window, of_main_app );
    ofRunMainLoop();
}

//--------------------------------------------------------------
void ofApp::setup()
{
    this->m_tex_width = 1920;
    this->m_tex_height = 1080;

    // FBO
    ofFbo::Settings fbo_settings;
    fbo_settings.width = this->m_tex_width;
    fbo_settings.height = this->m_tex_height;
    fbo_settings.colorFormats = std::vector<GLint>({GL_RGBA});
    fbo_settings.useDepth = true;
    fbo_settings.useStencil = false;
    fbo_settings.depthStencilAsTexture = false;
    fbo_settings.textureTarget = GL_TEXTURE_2D;
    fbo_settings.internalformat = GL_RGBA;
    fbo_settings.wrapModeHorizontal = GL_CLAMP_TO_EDGE;
    fbo_settings.wrapModeVertical = GL_CLAMP_TO_EDGE;
    fbo_settings.minFilter = GL_LINEAR;
    fbo_settings.maxFilter = GL_LINEAR;
    fbo_settings.numSamples = 0;

    this->m_fbo.allocate(fbo_settings);

    // SHADERS
    this->m_init_shader.load( "shaders/init.vert", "shaders/init.frag" );
    this->m_shader.load( "shaders/update.vert", "shaders/update.frag" );

    // PRIMITIVES
    this->m_quad.set( 2, 2, 2, 2 );

    // MISC
    this->m_init = true;

    this->m_image.load("forest.png");
}
//--------------------------------------------------------------
void ofApp::draw()
{

    if ( this->m_init ) {

        this->m_fbo.begin();

        this->m_init_shader.begin();

        this->m_quad.draw();

        this->m_init_shader.end();

        this->m_fbo.end();

        this->m_init = false;
    }

    this->m_shader.begin();

    this->m_shader.setUniformTexture( "u_pos_texture", this->m_fbo.getTexture(), this->m_shader.getUniformLocation("u_pos_texture") );
    this->m_shader.setUniformTexture( "u_texture", this->m_image.getTexture(), this->m_shader.getUniformLocation("u_texture") );

    this->m_quad.draw();

    this->m_shader.end();
}

// init.frag

#version 150

in vec2 vs_texcoord;
out vec4 frag_color;

void main()
{
	frag_color = vec4( vs_texcoord, 0.f, 1.f );
}

//update.frag

#version 150

in vec2 vs_texcoord;
uniform sampler2D u_pos_texture;
uniform sampler2D u_texture;
out vec4 frag_color;

void main()
{
	frag_color = texture( u_texture, texture( u_pos_texture, vs_texcoord ).xy );
}

This is a screenshot of what I got

Any hints, by chance ? Thank you

Posts: 2

Participants: 1

Read full topic

Newbie listener question using PiMapper

$
0
0

@ddh wrote:

Forgive me - just getting into this, looks great. I am trying to extend the example app and send instructions from another process. The ofxPiMapper example has keyPress actions - i want to be able to invoke these from other methods. As a simple example, can someone advise how i might catch a SIGINT or SIGUSR and invoke the info function (as in, when the user clicks the 'i', the info/help panel appears).

ideally i want to have an apache server running on this host and somehow IPC (socket/pipe/whatever) but just trying to understand the framework first.

Any guidance would be helpful!

Thanks

Posts: 2

Participants: 2

Read full topic

Vs2017(or vs2015) OF0.9.8 ofxOSC errata and solution

$
0
0

@ZJH wrote:

(I start to try OF for one week and today I start to read a book form amazon but not also fellow thisinstuction. but there is a problem on my first project.)
I need crate a project using ofxOSC and I use OF in visual studio 2017 on windows. When I create it by
openframwworks plugin for visual studio 2017 to create a project. This is some mistake and show error message like this:
can not open file "pthread.h"
can not open file "netdb.h"

I search on github and find there is some same problem. So I solve it like this:
method 1: add compile control sentences
find file NetworkingUtils.cpp and UdpSocket.cpp
and add the next sentence below the first include line

if !defined( WIN32 ) && !defined( _WIN32 )

and add the next sentence at end od the file

endif

method 2: just not include posix folder in project

And I guess some beginner using win32 and vs must will come across the same problem. Try it.

Posts: 1

Participants: 1

Read full topic

Change image trasparence - png alpha channel

$
0
0

@Taconito wrote:

Hello to all.
I have two pictures: the first is the background, the second is a png logo (it is saved with the transparent background - alpha channel to zero).
I want the logo to blink, and I thought I would intervene on the alpha channel but I do not know how.
How do I change the transparency of the png logo?

Posts: 1

Participants: 1

Read full topic


3D Camera Movement - Position and Quaternion

$
0
0

@Anthony_Dunphy wrote:

I have to move my ofCamera position through the 3D world. Im having an issue with stopping my movement from the starting point. When I get to the end point of my target, I want the movement to stop but I dont know why its not. The code is as follows for the main part -

the draw part -

easyCam.begin();

ofVec3f lookatPos = ofVec3f(width / 2.5, height / 2.5, 950);
easyCam.setPosition(lookatPos);
//easyCam.lookAt(node);
//easyCam.move(0, -150, 0);
//easyCam.truck(-300);
easyCam.setVFlip(true);

// ofCamera myCam;
float tweenvalue = (ofGetElapsedTimeMillis() % 20000) / 20000.f; // this will slowly change from 0.0f to 1.0f, resetting every 2 seconds

ofQuaternion startQuat;
ofQuaternion targetQuat;
ofVec3f startPos;
ofVec3f targetPos;

// we define the camer's start and end-position here:
startQuat.set(0, 0, 0, 1000);
startPos.set(0, 0, 0);
targetPos.set(-500, -300, -1000);

//easyCam.setGlobalPosition(-500, -500, -1000);


ofQuaternion tweenedCameraQuaternion;	// this will be the camera's new rotation.

										// calculate the interpolated orientation
tweenedCameraQuaternion.slerp(tweenvalue, startQuat, targetQuat);

ofVec3f lerpPos;					//this will hold our tweened position.

									// calculate the interpolated values.
lerpPos.x = ofLerp(tweenvalue, startPos.x, targetPos.x);
lerpPos.y = ofLerp(tweenvalue, startPos.y, targetPos.y);
lerpPos.z = ofLerp(tweenvalue, startPos.z, targetPos.z);

// alternative way to calculate interpolated values:
// lerpPos = startPos + ((targetPos-startPos) * tweenvalue);

// now update the camera with the calculated orientation and position.
easyCam.setOrientation(tweenedCameraQuaternion);
easyCam.setGlobalPosition(lerpPos);
if (lerpPos == ofVec3f(-500, -300, -1000)) {
	easyCam.setGlobalPosition(-500, -300, -1000);
}

What am i doing wrong?

Posts: 1

Participants: 1

Read full topic

Sublime + make: where does cout go / where is console.log

$
0
0

@a__ wrote:

I've started using Sublime and compiling/running with make in Terminal as per this old thread, it's all working fine except that I can't find where my console output (cout << "hello world" << endl;) goes. It doesn't output to the Sublime console, and it says here:

I think it might go to your "console.log". The usual way to get to this
is to open the Console.app located in /Applications/Utilities. The
physical file is located under /Library/Logs/Console/<uid>/

I don't have a Console directory in /Library/Logs nor in ~/Library/Logs. Any ideas? Thanks a lot.

Posts: 2

Participants: 2

Read full topic

Capture data with sensors, send it to a web server, access it from OF

$
0
0

@noobCoder wrote:

hey

im trying to connect my particle photon to openframeworks, i want simple data to send, not images but numbers, or booleans.
i looked at sending data from the photon to arduino and then to openframeworks, and sending photon data to webhook(thingspeak).
i would like to use the second option, thingspeak is in matlab and thats not c++, to convert it i need an application that costs money, and im not even sure that will work. i hope maybe somebody knows how i can acces my data on thingspeak from openframeworks. otherwise i hope somebody will know a different kind of webhook that works good with openframeworks. i hope my question is clear and somebody can help me.

thank for reading

Posts: 1

Participants: 1

Read full topic

Substr does not handle unicode?

$
0
0

@stephanschulz wrote:

I have a unicode string
myStrig = "üöéñ and so on"

OF can print it nicely to the screen. But when I try to create an array of each separate letter by using
string letter = currentString.substr(i,1);
then some letters do not get stored in the array.

Is there a work around for this?

Thanks.
I'm on OSX 10.12 with OF 0.10

Posts: 5

Participants: 4

Read full topic

Openframeworks ios

When opening the camera library with ofxiOS, designate an album

$
0
0

@taketori7616 wrote:

When declaring openLibrary in ofxiOS with ofxiOSImagePicker, is there a way to specify the "video" folder in the camera folder, "panorama", "favorite" etc?

Posts: 1

Participants: 1

Read full topic

Sublime and OF build configuration and Make

$
0
0

@cyrstem wrote:

hi i been trying to use sublime as my main IDE so far so good with OF 0.9.8 following this link OF &Sublime
but at the time of building the project i get this message in the console has anyone have success with building and running OF from sublime can anyone share any light on this ?

Makefile:13: /Volumes/GhOsT/Creative: No such file or directory
Makefile:13: Coding/OF/of_v0.9.8/libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk: No such file or directory
make: *** No rule to make target `Coding/OF/of_v0.9.8/libs/openFrameworksCompiled/project/makefileCommon/compile.project.mk'.  Stop.
[Finished in 0.0s with exit code 2]

Posts: 1

Participants: 1

Read full topic


ofxPiMapper example - load a new video

$
0
0

@ddh wrote:

Has anyone loaded a new video dynamically? i am using the ofxPiMapper example and am trying to change the video on a keystroke. When i try to call ofx::piMapper::VideoSource::loadVideo("/fullpath/../") I get a compile issue.. Any help?

Thanks

Posts: 1

Participants: 1

Read full topic

How to use Vamp plugin into Openframeworks code for sound detection?

$
0
0

@baguette wrote:

Hello,

I started to learn OF with the tutorials of the OF website. My goal is to create some sketches with sound vizualisation.
So I read this one : http://openframeworks.cc/ofBook/chapters/sound.html, where the author is talking about Vamp Plugin. It seems that this plugin is interesting for beat detection, key detection and so on.
So I tried to read and build some stuff with examples provided in this website : vamp-plugins.org, and I couldn't achieve this...

So my question is : how to use and include Vamp plugins in OF application ?

I'm working on windows 10, and I build using cmd prompt.

Thank you very much :slight_smile:

keywords : sound, vamp, plugins, openframeworks, sound detection, onset detection, audio beat tracking, audio key detection,

Posts: 1

Participants: 1

Read full topic

Using ofSoundStream in my own class

$
0
0

@guardabrazo wrote:

Hi, I'm trying to make an audio visualizer class and I wanted to separate the responsibilities between ofApp and my class implementing ofSoundStream only in the visualizer class.

I thought that this would work:

#include "AudioVizClass.h"
#include "ofApp.h"

AudioVizClass::AudioVizClass(){
//...
}

void AudioVizClass::setup(){
//...
    soundStream.setup((ofApp*)ofGetAppPtr(), 0, 2, 44100, 256, 4);
}

//--------------------------------------------------------------
void AudioVizClass::audioIn(float * input, int bufferSize, int nChannels){
}

But the audioIn function is not being called at all.

Posts: 2

Participants: 2

Read full topic

Ios step sequence question!

Qr code generator and FBO

$
0
0

@Vis wrote:

Currently I am working on a project that will generate qr code in every play. And the qr code will be drawn on the fbo and then export it. The problem is the generated qr codes are same. Anyone have ideas to solve it?

qr.generate("http://www.testing.com/" + uuidFolder );

qrFbo.begin();
ofClear(255);
qr.draw(4);
qrFbo.end();

qrFrameFbo.begin();
ofClear(255);
imgFrame.draw(0,0);
qrFbo.draw(82, 506, 675, 675);
qrFrameFbo.end();

qrFrameFbo.readToPixels(qrPixels);
qrImg.setFromPixels(qrPixels);
qrImg.save( "qrCode/" + uuidFolder + ".jpg", OF_IMAGE_QUALITY_MEDIUM);

Posts: 1

Participants: 1

Read full topic

Viewing all 4929 articles
Browse latest View live