From 2d09a8501ab3059354eef566090d733be18b28a6 Mon Sep 17 00:00:00 2001 From: Dany LE Date: Sun, 14 Aug 2022 16:52:22 +0200 Subject: [PATCH] Refactory code --- Diya/DiyaBoot.class.st | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/Diya/DiyaBoot.class.st b/Diya/DiyaBoot.class.st index ac06255..367620f 100644 --- a/Diya/DiyaBoot.class.st +++ b/Diya/DiyaBoot.class.st @@ -36,12 +36,6 @@ DiyaBoot class >> startx [ self uniqueInstance run ] -{ #category : #events } -DiyaBoot >> GLinit. [ - OpenGL viewportX: 0 Y:0 W: display w H: display h. - OpenGL enable: GL_TEXTURE_2D. -] - { #category : #events } DiyaBoot >> createGLContext [ context := SDL2 glCreateContext: window. @@ -105,7 +99,9 @@ DiyaBoot >> render [ |launcher| launcher := DiyaApplicationLauncher uniqueInstance. launcher setup. - self GLinit. + "Init the Open GL view port and enable 2D texture" + OpenGL viewportX: 0 Y:0 W: display w H: display h. + OpenGL enable: GL_TEXTURE_2D. [ launcher running ] whileTrue: [ DiyaClock uniqueInstance tick. launcher main.