forked from nickzman/skyrocket
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flare.h
executable file
·61 lines (44 loc) · 1.6 KB
/
flare.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
/*
* Copyright (C) 1999-2005 Terence M. Welsh
*
* This file is part of Skyrocket.
*
* Skyrocket is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* Skyrocket is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef FLARE_H
#define FLARE_H
/*#include <windows.h>
#include <gl/gl.h>
#include <gl/glu.h>*/
#include <OpenGL/gl.h>
#include <OpenGL/glu.h>
#define FLARESIZE 128
/*extern unsigned int flarelist[4];
extern int xsize, ysize;
extern float aspectRatio;
extern double modelMat[16], projMat[16];
//extern int viewport[4];
extern GLint viewport[4];*/
typedef struct SkyrocketSaverSettings;
// Generate textures for lens flares
// then applies textures to geometry in display lists
void initFlares(SkyrocketSaverSettings *inSettings);
struct flareData{
float x, y, r, g, b, a;
};
// Draw a flare at a specified (x,y) location on the screen
// Screen corners are at (0,0) and (1,1)
// alpha = 0.0 for lowest intensity; alpha = 1.0 for highest intensity
void flare(float x, float y, float red, float green, float blue, float alpha, SkyrocketSaverSettings *inSettings);
#endif // FLARE_H