2014-01-06 02:40:24 +00:00
|
|
|
//
|
|
|
|
|
// GUI.h
|
|
|
|
|
// emptyExample
|
|
|
|
|
//
|
|
|
|
|
// Created by James Alliban on 25/06/2013.
|
|
|
|
|
//
|
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "ofMain.h"
|
|
|
|
|
#include "BarGraph.h"
|
2014-01-09 17:07:26 +00:00
|
|
|
#include "BodyGraph.h"
|
2014-01-11 19:50:28 +00:00
|
|
|
#include "SeparateBodyGraph.h"
|
2014-01-10 00:10:06 +00:00
|
|
|
#include "DataManager.h"
|
2014-01-08 17:31:33 +00:00
|
|
|
#include "ofxFTGL.h"
|
2014-01-06 02:40:24 +00:00
|
|
|
|
|
|
|
|
class testApp;
|
|
|
|
|
|
|
|
|
|
class Scene
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
void setup();
|
|
|
|
|
void update();
|
|
|
|
|
void draw();
|
2014-01-07 17:11:46 +00:00
|
|
|
void drawVideo();
|
2014-01-12 04:43:19 +00:00
|
|
|
void drawGraphValues();
|
|
|
|
|
void drawCrosshairs();
|
2014-01-08 17:31:33 +00:00
|
|
|
void drawHUDBG();
|
|
|
|
|
void drawHUDCopy();
|
2014-01-10 03:31:45 +00:00
|
|
|
void drawHUDColourBars();
|
2014-01-08 17:31:33 +00:00
|
|
|
void drawTextBox(string copy, string align);
|
2014-01-10 00:10:06 +00:00
|
|
|
void addNewData(vector<DataObject> newData);
|
2014-01-11 06:13:04 +00:00
|
|
|
void clearGraphData();
|
2014-01-08 17:31:33 +00:00
|
|
|
void keyPressed(int key);
|
2014-01-11 06:13:04 +00:00
|
|
|
|
2014-01-09 17:07:26 +00:00
|
|
|
|
2014-01-06 02:40:24 +00:00
|
|
|
BarGraph barGraph;
|
2014-01-09 17:07:26 +00:00
|
|
|
BodyGraph bodyGraph;
|
2014-01-11 19:50:28 +00:00
|
|
|
SeparateBodyGraph separateBodyGraph;
|
|
|
|
|
|
2014-01-07 00:48:58 +00:00
|
|
|
ofShader rgbShader;
|
2014-01-10 00:33:16 +00:00
|
|
|
ofVideoGrabber vidGrabber;
|
2014-01-07 00:48:58 +00:00
|
|
|
ofImage bgImg;
|
2014-01-08 17:31:33 +00:00
|
|
|
ofxFTGLSimpleLayout text;
|
|
|
|
|
|
2014-01-09 17:07:26 +00:00
|
|
|
AbstractGraph* activeGraph;
|
|
|
|
|
|
2014-01-08 17:31:33 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
// video image vars
|
|
|
|
|
float brightness;
|
|
|
|
|
float contrast;
|
|
|
|
|
float saturation;
|
|
|
|
|
float red;
|
|
|
|
|
float green;
|
|
|
|
|
float blue;
|
|
|
|
|
float alpha;
|
2014-01-11 04:13:22 +00:00
|
|
|
float videoWidthPercentage;
|
|
|
|
|
float videoHeightPercentage;
|
2014-01-10 00:33:16 +00:00
|
|
|
bool isVideoVisible;
|
|
|
|
|
bool isImageVisible;
|
2014-01-12 04:43:19 +00:00
|
|
|
|
|
|
|
|
// graph text
|
|
|
|
|
float graphTextColour[4];
|
|
|
|
|
float graphTextSize;
|
|
|
|
|
|
|
|
|
|
// crosshairs
|
|
|
|
|
float crosshairLineWidth;
|
|
|
|
|
float crosshairAlpha;
|
|
|
|
|
float crosshairCircleSize;
|
2014-01-12 20:08:05 +00:00
|
|
|
float crosshairVertScale;
|
|
|
|
|
float crosshairHorizScale;
|
2014-01-12 04:43:19 +00:00
|
|
|
|
2014-01-08 17:31:33 +00:00
|
|
|
// HUD background vars
|
2014-01-07 17:11:46 +00:00
|
|
|
float hudColour[4];
|
|
|
|
|
float circlePointSize;
|
2014-01-11 03:47:53 +00:00
|
|
|
float hudHoleWidthPercentage;
|
|
|
|
|
float hudHoleHeightPercentage;
|
2014-01-08 17:31:33 +00:00
|
|
|
|
|
|
|
|
// text vars
|
|
|
|
|
float xMargin;
|
|
|
|
|
float yMargin;
|
|
|
|
|
float yMarginBottomOffset;
|
|
|
|
|
float lineLength;
|
|
|
|
|
float lineSpacing;
|
|
|
|
|
float textSize;
|
|
|
|
|
float textColour[4];
|
2014-01-10 03:31:45 +00:00
|
|
|
string tlStr;
|
|
|
|
|
string trStr;
|
|
|
|
|
string blStr;
|
|
|
|
|
string brStr;
|
|
|
|
|
float averageAmount;
|
|
|
|
|
|
|
|
|
|
// text colour boxes
|
|
|
|
|
float topColourBoxXOffset;
|
|
|
|
|
float bottomColourBoxXOffset;
|
|
|
|
|
float colourBoxThickness;
|
2014-01-06 02:40:24 +00:00
|
|
|
};
|