unofficial introduction of openframeworks
TRANSCRIPT
![Page 1: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/1.jpg)
Unofficial Introduction of openFrameworks
Sadashige Ishida
![Page 2: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/2.jpg)
Who am I?
Name: Sadashige ISHIDAInterests: Math particularly in geometry, physics,
computer graphics, natural languagesPreference: Fun, beautiful, moving >>> Useful, high-
PerformanceAm researching computer graphics for 4 months.Am researching physics-based animation.Don’t have a Twitter account.
![Page 3: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/3.jpg)
Objectives of this slide.
Introduce a beginner-friendly tool “openFrameworks”.
Find people who read papers/books on computer graphics/OpenGL and implement them together.
![Page 4: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/4.jpg)
Motivation: Want to make an animation.Wanna make animations of characters, fluids, etc…
Need to render(draw on a screen).
![Page 5: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/5.jpg)
Pain of rendering.
Can render with OpenGL.
![Page 6: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/6.jpg)
Pain of rendering.
Can render with OpenGL.
Can render.
![Page 7: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/7.jpg)
Pain of rendering.
Can render with OpenGL.
Can render.
Pain of changing the view point…. Computation of matrices…ahh…
![Page 8: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/8.jpg)
Pain of rendering.
Can render with OpenGL.
Can render.
Pain of changing the view point…. Computation of matrices…ahh…
Wanna be free of them…
![Page 9: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/9.jpg)
Pain of rendering.
Can render with OpenGL.
Can render.
Pain of changing the view point…. Computation of matrices…ahh…
Wanna be free of them…
-> openFrameworks
![Page 10: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/10.jpg)
Let’s see a video.https://www.youtube.com/watch?v=6u6IDorMKAs
Seems you can do many things with it.
openFrameworks
![Page 11: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/11.jpg)
openFrameworks
The official site says openFrameworks is an open source C++ toolkit designed to assist the creative process by providing a simple and intuitive framework for experimentation.
![Page 12: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/12.jpg)
openFrameworks
The official site says openFrameworks is an open source C++ toolkit designed to assist the creative process by providing a simple and intuitive framework for experimentation.
…OK.
![Page 13: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/13.jpg)
(Official)openFrameworks can hundleGLEW, GLUT, libtess2 and cairo for graphicsrtAudio, PortAudio, OpenAL and Kiss
FFT or FMOD for audio input, output and analysisFreeTypeFreeType for fontsFreeImage for image saving and loadingQuicktime, GStreamer and videoInput for video
playback and grabbingPoco for a variety of utilitiesOpenCV for computer visionAssimp for 3D model loading
![Page 14: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/14.jpg)
I use openFrameworks for
Visualization of deformation of polygon meshes(a polygon mesh is a collection of triangles).
Implementation of physics based animations e.g. Position-based dynamics[Muller et. al. 2006].
Animation generally.
![Page 15: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/15.jpg)
Features of openFrameworksVery friendly with beginners!Easy.Write in C++.Friendly with IDEs like Xcode and VisualStudio.Need almost no knowledge of OpenGL.
![Page 16: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/16.jpg)
Takes 3 minutes for running a demo.Takes 5 minutes for making your own project.
Just need to follow very kind tutorials.
Quick for running something after download.
Features of openFrameworks
![Page 17: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/17.jpg)
Let’s compile and run a demo “ofBoxExample”.
1. Download and unzip openFrameworks.URL: http://openframeworks.cc/download/
2. [Mac]Open “Path of openFrameworks(have to write your own path)”/examples/3d/ofBoxExample/ofBoxExample.xcodeprojwith Xcode[Windows]Please refer http://openframeworks.cc/setup/vs/(Sorry, a bit more complicated than Mac.)
3. Run or Debug
A demo of openFrameworks
![Page 18: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/18.jpg)
openFrameworks’s nice points(my personal opinion) Very easy to zoom-in/out with mouse operation
<-painful to write this with OpenGL.Easy to make my own projects.No need for Cmake or Makefile ^_^.No need to specify dependencies or linkers^_^.Simple.
Write everything in setup(), update() and draw().Can draw meshes, play music, make animation.According to the official page, can make iPhone apps.
![Page 19: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/19.jpg)
openFrameworks’s week points (my personal opinion)Have to write “pause” by yourself. Doesn’t seem to
provide this function.Have to edit meshes by yourself.
![Page 20: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/20.jpg)
Usage of openFrameworks
Make your own project.Edit ofApp.cpp (and ofApp.h).Done.
![Page 21: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/21.jpg)
openFrameworks’s ofApp.h
In minimum,
class ofApp : public ofBaseApp{ public: void setup();//Called once when it starts. void update(); //Called every time-step to update the state. void draw(); //Called every time-step after update() to draw.
};
![Page 22: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/22.jpg)
Flow of openFrameworks
ofApp::setup()
ofApp::update()
ofApp::draw()
Repeats on every time-step.
![Page 23: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/23.jpg)
How to change the viewpoint with openFrameworksIn minimum,
class ofApp : public ofBaseApp{ public: void setup();//Called once when it starts. void update(); //Called every time-step to update the state. void draw(); //Called every time-step after update() to draw.
ofEasyCam cam; //Camera(something that controls the viewpoint) };
![Page 24: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/24.jpg)
How to change the viewpoint with openFrameworks
In minimum,
void ofApp::draw(){
////Camera starts. cam.begin(); //Write something for drawing. //e.g. Draw a line between (0,0,0) and (1,1,1) int x1=0, y1=0, z1=0, x2=1, y2=1, z2=1; ofLine(x1,y1,z1,x2,y2,z2) //Drawing done.
//Camera ends. cam.end(); }
Then, it gives
Left drag: RotationMouse wheel, right drag:Zoom-in/outWheel-drag: Transition
Touch-pad operation is similar.
![Page 25: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/25.jpg)
Summary of openFrameworksBeginner-friendly.Easy to render.Simple to write everything in setup(),update() or
draw().Plenty of Example. Can make something good by
editing examples.Various applications.
![Page 26: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/26.jpg)
Objectives of this slide.Introduction of openFrameworks.
Find people who read papers/books on computer graphics/OpenGL and implement them together. For a beginner, it is painful to understand and implement a paper.
Can’t follow equations. Can’t understand what are said.How to design classes.Code gets messy.Code-reading is painful too.
I look for people who can struggle with me.Contact me if you are interested.Correction of my poor English is also welcome.
Name:Sadashige ISHIDAE-mail address:sdsgisd[at]gmail.com
![Page 27: Unofficial Introduction of openFrameworks](https://reader036.vdocument.in/reader036/viewer/2022070520/58f0a9691a28ab805d8b4639/html5/thumbnails/27.jpg)
End