Browse Source

Dateien hochladen nach „“

Basti_Master
Fritz Lenssen 5 years ago
parent
commit
12c6ac1cad
5 changed files with 183 additions and 0 deletions
  1. 37
    0
      Emitter.cpp
  2. 55
    0
      attractor.cpp
  3. 35
    0
      attractor.hpp
  4. 41
    0
      greatWhole.hpp
  5. 15
    0
      main.cpp

+ 37
- 0
Emitter.cpp View File

@@ -0,0 +1,37 @@
//
// Emitter.cpp
// emptyExample
//
// Created by Sebastian Holzki on 17.04.19.
//
#pragma once
#include "Emitter.hpp"


Emitter::Emitter()
{
}

// -----------------------------------

Emitter::~Emitter()
{
}

// -----------------------------------



void Emitter::setEmitterPosition(ofVec2f _position){
position = _position;
}

// -----------------------------------------------

+ 55
- 0
attractor.cpp View File

@@ -0,0 +1,55 @@
//
// attractor.cpp
// emptyExample
//
// Created by Sebastian Holzki on 16.04.19.
//
#pragma once

#include "attractor.hpp"



Attractor::Attractor(){
}

// ------------------------------------

Attractor::~Attractor(){
}

// ------------------------------------

float Attractor::getX(){
return x;
}

// ------------------------------------

float Attractor::getY(){
return y;
}

// ------------------------------------

void Attractor::setX(float _x){
x = _x;
}

// ------------------------------------

void Attractor::setY(float _y){
y = _y;
}

+ 35
- 0
attractor.hpp View File

@@ -0,0 +1,35 @@
//
// attractor.hpp
// emptyExample
//
// Created by Sebastian Holzki on 16.04.19.
//


#pragma once

#include <stdio.h>




class Attractor {
public:
Attractor();
~Attractor();
float getX();
float getY();
void setX(float x);
void setY(float y);
void updateCoordinates(float x, float y);
private:
float x;
float y;
};

+ 41
- 0
greatWhole.hpp View File

@@ -0,0 +1,41 @@
//
// greatWhole.hpp
// emptyExample
//
// Created by Sebastian Holzki on 17.04.19.
//

#include <stdio.h>
#include "ofMain.h"
#include "avatar.hpp"

#pragma once


/* Das Große Ganze beinhaltet eine unbestimmte Anzahl an bereits eingecheckten Personen, deren Infos in Avatare gespeichert werden.
Es bedarf eine setup(), update() und draw()-Methode. Dabei soll Platz für den vector<Avatar> geschaffen werden. In update wird eine
gewisse Bewegung der Avatar-"Bubbles" definiert. Draw zeichnet die Avatare auf die Stelen, also die entsprechenden Koordinaten. */


class GreatWhole {
public:
GreatWhole();
~GreatWhole();
void setup();
void update(vector<Avatar*> avatars);
void draw();
void addAvatar(Avatar avatar);
Avatar getAvatarAt(int i);

private:
vector<Avatar*> avatars;
};

+ 15
- 0
main.cpp View File

@@ -0,0 +1,15 @@

#include "ofMain.h"
#include "ofApp.h"

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

ofSetupOpenGL(1000,1000, OF_WINDOW); // <-------- setup the GL context

// this kicks off the running of my app
// can be OF_WINDOW or OF_FULLSCREEN
// pass in width and height too:
ofRunApp( new ofApp());

}

Loading…
Cancel
Save