04-01-2023, 07:25 PM
Hi @MasterGy. Thank you for the kind words, it's always a pleasure. I've worked with OpenGL a bit in the past, but at the time it wasn't that well tuned in QB64 - and I was inexperienced, so the program often crashed with a white screen. Then I left it for a while, I started working on with Maptriangle3D. It is necessary to admit that Ashish (AshishKingdom) helped me a lot when I was working with OpenGL, he is much further in this area than I am. In some cases, it is necessary to add a helper library in C language to OpenGL, for example for quadrics. I don't know if this is still necessary today, but in QB64 1.3 in 2017 it was necessary. Damn, time flies, it's scary.
I basically gave openGL another chance now, at the time when I started, I bypassed the MEM commands with respect from a long distance, today we are already talking. Sometimes.
To the point. Take a look at the previous program for yourself. How would you like to do this with _MapTriangle? Like this. with _MapTriangle you make transparency, you make sphere, cube, 2D shapes, cone with it... yeah, you do. It is very similar to OpenGL, mainly the coordinate system. Because I know you're very capable, I think it would catapult you into the elite. I would sometimes wave at you from below.
But when working with OpenGL, it is really necessary to be very careful about setting the matrices, it is easy to forget ONE command - the rest is fine - and there is nothing on the monitor. Also note that some QB64PE commands such as SLEEP will cause the program to die immediately. This is because OpenGL simply does not allow for the data stream to suddenly be interrupted in the middle of its work. Next, when working with OpenGL, it is possible to queue parts of the program that are not part of OpenGL into the main loop. For example - look at the complexity of initializing OpenGL. You have to check if what was supposed to happen only the first time, another pass has already taken place to prevent it. If you look at the source codes, there is always something like If INIT then EXIT SUB or something like that. These are the QB64 specs. A huge benefit in QB64PE is the help table that describes which data type in OpenGL corresponds to which data type in C and in QB64. This is a nice help when writing helper dynamic libraries that need to be defined for some Glut functions.
I basically gave openGL another chance now, at the time when I started, I bypassed the MEM commands with respect from a long distance, today we are already talking. Sometimes.
To the point. Take a look at the previous program for yourself. How would you like to do this with _MapTriangle? Like this. with _MapTriangle you make transparency, you make sphere, cube, 2D shapes, cone with it... yeah, you do. It is very similar to OpenGL, mainly the coordinate system. Because I know you're very capable, I think it would catapult you into the elite. I would sometimes wave at you from below.
But when working with OpenGL, it is really necessary to be very careful about setting the matrices, it is easy to forget ONE command - the rest is fine - and there is nothing on the monitor. Also note that some QB64PE commands such as SLEEP will cause the program to die immediately. This is because OpenGL simply does not allow for the data stream to suddenly be interrupted in the middle of its work. Next, when working with OpenGL, it is possible to queue parts of the program that are not part of OpenGL into the main loop. For example - look at the complexity of initializing OpenGL. You have to check if what was supposed to happen only the first time, another pass has already taken place to prevent it. If you look at the source codes, there is always something like If INIT then EXIT SUB or something like that. These are the QB64 specs. A huge benefit in QB64PE is the help table that describes which data type in OpenGL corresponds to which data type in C and in QB64. This is a nice help when writing helper dynamic libraries that need to be defined for some Glut functions.