-
Notifications
You must be signed in to change notification settings - Fork 22
/
Copy pathZennyGLView.h
47 lines (36 loc) · 925 Bytes
/
ZennyGLView.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
//
// ZennyGLView.h
// CPU Dasher
//
// Created by zenny_chen on 13-4-17.
//
//
#import <UIKit/UIKit.h>
enum ZENNY_SHADER_CALC
{
ZENNY_SHADER_CALC_COLOR2GRAY,
ZENNY_SHADER_CALC_CONVOLUTION_KERNEL3X3
};
@interface ZennyGLView : UIView
{
@private
EAGLContext *mContext;
GLuint mFrameBuffer, mRenderBuffer;
GLuint mProgram;
GLuint mTextureName;
GLfloat mVertexCorrds[16];
GLfloat mOrthoMatrix[16];
NSTimeInterval mBeginTimes[10], mEndTimes[10];
NSInteger mCurrentFrameIndex;
CADisplayLink *mDisplayLink;
enum ZENNY_SHADER_CALC mCalcForm;
@public
const void *ipTextureData;
NSObject *iTargetObject;
SEL iCompleteSelector; // - (void)completeSelector;
NSTimeInterval iMinTime, iAverageTime, iMaxTime;
}
- (BOOL)isCapableForGLProcessing;
- (void)determineShaders:(enum ZENNY_SHADER_CALC)calcForm;
- (void)startAnimate;
@end