Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Goombert

Proposals / Re: GL3 changes from immediate to retained mode
« on: July 31, 2013, 05:41:18 PM »
Code: [Select]
draw_sprite(spr_wall, 0, 0);


That is possible in Game Maker and using the DX batching class. DX can also outperform this with different textured sprites, I presume because of batching, and it must be mixing it with a shader. If we add all that to the OpenGL one Harri committed, we could make it a LOT faster than what he has right now.

General ENIGMA / Re: Scalar Types
« on: July 31, 2013, 05:36:49 PM »
Do you mean why didn't I? I thought I avoided making alpha gs_scalar like the plague.

I am using the zip installer which comes with MinGW64 Harri, if that is the case, first try to install the DX runtime, then try to install the DX SDK and see which of those fixes it, but do it in that order, as I'd rather have people download the runtime than the SDK.

d3d9.h contains most of the rendering headers
d3dx9.h contains math functions, vector classes, and matrix transformation stuffs

There is also a lib for both of those which is linked, -ld3d9 and -ld3dx9

And why can't you do this now in OGL? Do you mean just using d3d_transform functions to rotate sprites?
No I was just ensuring everyone that the behavior has not been lost with this new sprite batching class.

Proposals / Re: GL3 changes from immediate to retained mode
« on: July 31, 2013, 09:21:42 AM »
Harri, yup, exactly what I was thinking.

Proposals / Re: GL3 changes from immediate to retained mode
« on: July 31, 2013, 07:34:13 AM »
Yes, these were all the things I was originally planning to do with OpenGL 3. But Harri, for that I was thinking of a common interface for vertex formats of all the basic shapes like a plane and what not, and include them from a common header, thats what those GLshapes.cpp and GL3shapes.cpp files are about. I just didn't have the energy to do it. Also, that is why there's a shaders folder, we need to rewrote all the behavior expected into GPU programs as well. Especially for particle effects.

Me and Josh did a few test cases and the sprite batch does properly organize depths, and in fact transformations can be applied to the sprites/backgrounds/text to turn them into 3D billboards like many people do in Game Maker.

Proposals / Re: Vertex color
« on: July 31, 2013, 04:42:49 AM »
We use VBO's instead of lists as it is just better usually. But even lists cannot be changed. So if you turn this into a list:
It was in response to that :P I was not sure if you were aware that OpenGL 1 still uses call lists.

Sadly we don't. I would really want an android port, but the framework it requires (together with a shit ton of configuration for SDK/NDK) makes it all hard to do. Maybe I'll just try making GLES run on Windows (if that is even possible) and then try to make it work on another device.
Nonsense Harri, I have faith in you  :)

Edit: We can also add the display_reset for AA it's just a flag in the D3D present parameters. And now I get my full 8 levels of MSAA and Morphological anti-aliasing provided by my ATI Radeon graphics card, so I still say the fuck with OpenGL. The Direct3D code is much more abstract but yet so much more compact and easier to read and write.

Edit 2:

Text rendering and fonts on the way!!!

Guys, hey I got the #1 reason we are going to use DX now, look at the updated screen shot, that is 50,000 draw_sprite calls at 30fps, OpenGL can't handle 15,000 on my pc at more than 12fps. That is utilizing DX's internal sprite batching class, please proceed with the DirectX vs. OpenGL debates. :P

Please merge pull request....

Also to prove my point, this is the d3d blend modes and their OpenGL and Direct3D equivalents.
Code: [Select]
  bm_zero             =  1,  // GL_ZERO                  D3DBLEND_ZERO
  bm_one              =  2,  // GL_ONE                   D3DBLEND_ONE
  bm_src_color        =  3,  // GL_SRC_COLOR             D3DBLEND_SRCCOLOR    //only for dest
  bm_inv_src_color    =  4,  // GL_ONE_MINUS_SRC_COLOR   D3DBLEND_INVSRCCOLOR //only for dest
  bm_src_alpha        =  5,  // GL_SRC_ALPHA             D3DBLEND_SRCALPHA
  bm_inv_src_alpha    =  6,  // GL_ONE_MINUS_SRC_ALPHA   D3DBLEND_INVSRCALPHA
  bm_dest_alpha       =  7,  // GL_DST_ALPHA             D3DBLEND_DESTALPHA
  bm_inv_dest_alpha   =  8,  // GL_ONE_MINUS_DST_ALPHA   D3DBLEND_INVDESTALPHA
  bm_dest_color       =  9,  // GL_DST_COLOR             D3DBLEND_DESTCOLOR     //only for src
  bm_inv_dest_color   = 10,  // GL_ONE_MINUS_DST_COLOR   D3DBLEND_INVDESTCOLOR  //only for src
  bm_src_alpha_sat    = 11   // GL_SRC_ALPHA_SATURATE    D3DBLEND_SRCALPHASAT   //only for src

So like I said the graphics portion of Game Maker was designed around D3D, obviously because of the function naming as well, so this definitely will cut down on visual anomalies in games. I've also noticed the transform functions have the same behavior as one would expect in Game Maker.

Proposals / Re: Vertex color
« on: July 30, 2013, 04:14:46 PM »
Harri, OpenGL3 uses VBO's, OpenGL 1 still uses call lists, and it is likely to remain that way.

General ENIGMA / Re: DirectX Image formats and Fonts
« on: July 30, 2013, 04:13:48 PM »
No, Josh, DirectX does not have the format available for RGBA only ARGB or RGB, please see the Microsoft documentation...

And I was not suggesting throwing out fonts altogether, I was just wondering if we wanted to abstract it to make use of some of these nice features of the API. Now what I meant with sprites and backgrounds is that DX provides a sprite drawing class, which I could just as easily use for the background functions, that is what the last link was about...

I don't care about all that, I care about the people who come here and don't have OGL support, that's great if it works good for all of us, but it doesn't help us if we just ignore those people, and DX9 is just a stepping stone in DX10 and DX11 for me, I am going to write them all. We already have GLES for other embedded systems, it's dumb that we ignore the operating system that controls 90% of the market, which is not going to favor in our interest.

Anyway, I disagree that its not going to be used either, look Game Maker's 3D functions were designed around Direct3D, we've had to do screwy shit to get things to work exactly like they do in Game Maker because of the differences in OGL vs DX, not that we shouldn't get our OGL system as close as possible, I am just saying using a D3D graphics system would make those anomalies a lot less possible. Not to mention the code is much easier to work with, the code I've written so far has been a lot less bloated than OGL, and its not as convoluted with all the extensions and querying. Because you are targeting a specific version, you already know what and what you can not work with, not to mention there is no "immediate mode" so you can switch between hardware/software vertex processing at runtime, this has always been an important thing with DirectX when new technology comes out because it allows people to choose to try and emulate it if they don't have proper graphics hardware.

Personally, though, I think DX9 Is a step in the wrong direction.
Completely disagree, one good thing about ENIGMA is its compatibility, we can run in virtual machines where Stupido is not capable of doing so. Microsoft likes to be bastards with OpenGL support, and once I get the hang of DX it won't take long and I'll be working on DX10 and 11.

General ENIGMA / DirectX Image formats and Fonts
« on: July 29, 2013, 09:15:06 PM »
Ok well this something we need to discuss.  ENIGMA has its own code for loading various image formats, but Direct3D has a S*** TON of built in formats supported...

".. the following file formats: .bmp, .dds, .dib, .hdr, .jpg, .pfm, .png, .ppm, and .tga"

DirectX also has internal classes for dealing with fonts, you can simply request them by name and tell it to render, it takes like 5 lines of code...
You can also ask it to build a mesh from font numerics and it will do so.

So this begs the question as to what to do about our fontstruct as it obviously needs moved so that its not included in our DX system when it doesn't need to be.

DirectX also provides internal classes for drawing sprites and batching them...

Now this also leads to another thing as to whether or not we want to use those sprite functions for backgrounds as well. Not to mention in GameMaker sometimes people will apply transformations to text and sprite drawing functions to use them as 3D billboards. I would like some input from you guys Harri, forthevin, Josh.


I have managed to get texture loading and draw_sprite implemented...

As you can see there is a tad bit of a problem, DX uses ARGB, ENIGMA loads textures into RGBA :( You can tell by the sprites pixel color being off.

Off-Topic / Re: YoYoGames Compiler for 300$
« on: July 29, 2013, 07:06:04 PM »
Yes, agreed senior forthevin, I have been saying this for some time, it also appears to go like a pyramid scheme with them. Remember way back in the day when the Sandbox got flooded with new users buying game maker? There were games everywhere, by the thousands, and then all of the sudden its userbase started drastically declining, that's when they decided to start with Studio going in a whole new direction, to convince customers to come back. Nobody wants to pay 800$ for buggy software that teaches them bad programming habits, my god most of what YYG added was just open source stuff like Box2D duct tapped into Game Maker, and they can't even do that well.