-
Notifications
You must be signed in to change notification settings - Fork 1
/
Mode.h
40 lines (32 loc) · 850 Bytes
/
Mode.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
//
// Mode.h
// Cityscape
//
// Created by andrew morton on 6/16/15.
//
//
#pragma once
#include "cinder/gl/GlslProg.h"
#include "cinder/params/Params.h"
#include "Options.h"
#include "Resources.h"
class BaseMode;
typedef std::shared_ptr<BaseMode> ModeRef;
class BaseMode
{
public:
BaseMode() {
mOptions.buildingShader = ci::gl::GlslProg::create(
ci::app::loadResource( RES_VERT ),
ci::app::loadResource( RES_FRAG )
);
}
virtual void addParams( ci::params::InterfaceGlRef params) {}
virtual void setup() {}
virtual void layout() {}
virtual void draw() {}
virtual void addPoint( ci::vec2 point ) {}
virtual bool isOverMovablePoint( ci::vec2 &point, float margin ) { return false; }
virtual void movePoint( ci::vec2 from, ci::vec2 to ) {}
Options mOptions;
};