/tutorial/vision/opengl/NeHe/lesson02/square.e
http://github.com/tybor/Liberty · Specman e · 27 lines · 21 code · 5 blank · 1 comment · 0 complexity · db704c1dc914d2f5e61f18b28db0c09b MD5 · raw file
- class SQUARE
- inherit
- GL_OBJECT
- redefine draw
- end
- creation
- make_with_position
- feature{ANY}
- build is
- do
- end
- draw is
- do
- -- Vertices must be given in counter-clockwise order
- smart_gl.begin_quads
- smart_gl.vertex(-1, 1, 0)
- smart_gl.vertex(-1, -1, 0)
- smart_gl.vertex(1, -1, 0)
- smart_gl.vertex(1, 1, 0)
- smart_gl.end_primitive
- end
-
- end