Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
8a9c84f4
Commit
8a9c84f4
authored
May 05, 2020
by
hwware
Committed by
antirez
May 08, 2020
Browse files
add include guard for lolwut.h
parent
cb683a84
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/lolwut.h
View file @
8a9c84f4
...
@@ -34,6 +34,10 @@
...
@@ -34,6 +34,10 @@
/* This represents a very simple generic canvas in order to draw stuff.
/* This represents a very simple generic canvas in order to draw stuff.
* It's up to each LOLWUT versions to translate what they draw to the
* It's up to each LOLWUT versions to translate what they draw to the
* screen, depending on the result to accomplish. */
* screen, depending on the result to accomplish. */
#ifndef __LOLWUT_H
#define __LOLWUT_H
typedef
struct
lwCanvas
{
typedef
struct
lwCanvas
{
int
width
;
int
width
;
int
height
;
int
height
;
...
@@ -47,3 +51,5 @@ void lwDrawPixel(lwCanvas *canvas, int x, int y, int color);
...
@@ -47,3 +51,5 @@ void lwDrawPixel(lwCanvas *canvas, int x, int y, int color);
int
lwGetPixel
(
lwCanvas
*
canvas
,
int
x
,
int
y
);
int
lwGetPixel
(
lwCanvas
*
canvas
,
int
x
,
int
y
);
void
lwDrawLine
(
lwCanvas
*
canvas
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
color
);
void
lwDrawLine
(
lwCanvas
*
canvas
,
int
x1
,
int
y1
,
int
x2
,
int
y2
,
int
color
);
void
lwDrawSquare
(
lwCanvas
*
canvas
,
int
x
,
int
y
,
float
size
,
float
angle
,
int
color
);
void
lwDrawSquare
(
lwCanvas
*
canvas
,
int
x
,
int
y
,
float
size
,
float
angle
,
int
color
);
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment