Skip to content

Commit 514d26e

Browse files
committed
glpclview: Fix typing issues
Signed-off-by: Hector Martin <hector@marcansoft.com>
1 parent ca9b389 commit 514d26e

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

examples/glpclview.c

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -59,11 +59,11 @@ void LoadVertexMatrix()
5959
float b = 3.3309495f;
6060
float cx = 340.0f;
6161
float cy = 240.0f;
62-
float mat[4][4] = {
63-
{1/f, 0, 0, 0},
64-
{0, -1/f, 0, 0},
65-
{0, 0, 0, a},
66-
{-cx/f,cy/f, -1, b}
62+
GLfloat mat[16] = {
63+
1/f, 0, 0, 0,
64+
0, -1/f, 0, 0,
65+
0, 0, 0, a,
66+
-cx/f,cy/f, -1, b
6767
};
6868
glMultMatrixf(mat);
6969
}
@@ -73,11 +73,11 @@ void LoadVertexMatrix()
7373
// and some python code I haven't documented yet.
7474
void LoadRGBMatrix()
7575
{
76-
float mat[4][4] = {
77-
{ 5.34866271e+02, 3.89654806e+00, 0.00000000e+00, 1.74704200e-02},
78-
{ -4.70724694e+00, -5.28843603e+02, 0.00000000e+00, -1.22753400e-02},
79-
{ -3.19670762e+02, -2.60999685e+02, 0.00000000e+00, -9.99772000e-01},
80-
{ -6.98445586e+00, 3.31139785e+00, 0.00000000e+00, 1.09167360e-02}
76+
float mat[16] = {
77+
5.34866271e+02, 3.89654806e+00, 0.00000000e+00, 1.74704200e-02,
78+
-4.70724694e+00, -5.28843603e+02, 0.00000000e+00, -1.22753400e-02,
79+
-3.19670762e+02, -2.60999685e+02, 0.00000000e+00, -9.99772000e-01,
80+
-6.98445586e+00, 3.31139785e+00, 0.00000000e+00, 1.09167360e-02
8181
};
8282
glMultMatrixf(mat);
8383
}
@@ -108,9 +108,9 @@ void DrawGLScene()
108108
{
109109
short *depth = 0;
110110
char *rgb = 0;
111-
int ts;
112-
freenect_sync_get_depth(&depth, &ts);
113-
freenect_sync_get_rgb(&rgb, &ts);
111+
uint32_t ts;
112+
freenect_sync_get_depth((void**)&depth, &ts);
113+
freenect_sync_get_rgb((void**)&rgb, &ts);
114114

115115
static unsigned int indices[480][640];
116116
static short xyz[480][640][3];
@@ -221,6 +221,6 @@ int main(int argc, char **argv)
221221

222222
glutMainLoop();
223223

224-
return NULL;
224+
return 0;
225225
}
226226

0 commit comments

Comments
 (0)