Closed kevodwyer closed 4 years ago
Oh yes, you are right, the signature of the "v" variant is wrong. Your fix looks good to me.
I'll push it to the repo.
Nice! I also found I needed to add the following defines to GL/gl.h in my case.
typedef GLint GLfixed;
You can see the use of gl4es and emscripten/WASM here: https://kevodwyer.github.io/boxedwine-gles/boxedwine.html I haven't got textures to work yet. More debugging to do...
I see: WebGL: INVALID_OPERATION: texParameter: no texture bound to target _emscripten_glTexParameteri @ boxedwine.js:1 15WebGL: INVALID_OPERATION: texImage2D: no texture bound to target 240[.WebGL-0x7fd533e7b800]RENDER WARNING: there is no texture bound to the unit 0
Looks good, but, that "boxedwine", what it is? Is it wine for WASM architecture or is it running with an x86 emulator?
enough fo a x86 emulator to run WINE. I help where i can, but it is mostly james' work (he wrote jdosbox, i did a js port of it as jsdosbox many years ago) https://sourceforge.net/projects/boxedwine/ Getting it to work with opengles has been a dream for a long time. Thanks for gl4es. BTW i have a Pandora from way back so i'm grateful for the work you have done there also.
A good place to follow along James' progress is on vogons: https://www.vogons.org/viewtopic.php?f=9&t=58414
Nice.
I'm currently working on getting "box86" compatible with WINE (and gl4es too). Funy how all project converge to similar objectives. I didn't knew that project, looks interresting.
I am getting a rasberry PI soon so i can play with box86!
From what I see, Boxedwine seems to be working, and probably as advanced, maybe more, as box86. And there is an android version. But again, I never heard of this project, that's a shame.
Android port needs some work. James' has it on his todo list. I think the first commit for boxedwinewas back in 2014 (memory is a bit hazy...). First in java, then C and now C++. The ARMv7 core is very recent. I am able to help out with emscripten, but that is it.
One question if you have a quick answer: When I run Wglinfo from: https://github.com/gkv311/wglinfo/releases
I see the following output: boxedwine-shell.js:957 boxedwine-shell.js:957 [WGL] OpenGL vendor string: ptitSeb boxedwine-shell.js:957 [WGL] OpenGL renderer string: GL4ES wrapper boxedwine-shell.js:957 [WGL] OpenGL version string: 2.1 gl4es wrapper 1.1.4 boxedwine-shell.js:957 [WGL] OpenGL shading language version string: 1.20 via gl4es
WebGL: INVALID_ENUM: getParameter: invalid parameter name Unknown pname for get: 34811 WebGL: INVALID_ENUM: getParameter: invalid parameter name Unknown pname for get: 36935
Does that mean anything to you?
There is a forum and more demos on: http://www.boxedwine.org/
WebGL: INVALID_ENUM: getParameter: invalid parameter name Unknown pname for get: 34811 WebGL: INVALID_ENUM: getParameter: invalid parameter name Unknown pname for get: 36935
Those are param that are not handled by gl4es (because I don't know them), that I just passthrough to gles hardware. First one 34811 seems to be GL_VBO_FREE_MEMORY_ATI 0x87FB
but I don't know what the second is.
On my Pandora, I get a performance result for MDK of 8 using box86+wine. I see on Vogon forum he gets 21 on a PI4. so dynarec seems fine. (I see many cycle spent on my side with emulation of "FS:" segment, I need to optimize that thing).
That's interesting. Feel free to reach out on the above vogon's thread, on the sourceforge repo or via email. It would be great if we can collaborate some way. Keep up the great work!
Ah, I tried MDK on my Pi4, and with a 20.2 (or is it 20.1?) mesa driver, I get "247" as performances indicator (not sure what is slowing it down on the Pandora, as I don't think the performance difference is that big)
I might be on the wrong track here... But while using gl4es with an OpenGL program I was getting an error. I fixed it by changing the param on glRect to match declaration on: https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/glRect.xml
gl4es.h From void gl4es_glRect##suffix##v(const type v); to void gl4es_glRect##suffix##v(const type v1, const type *v2);
gl4eswraps.c From void gl4es_glRect##suffix##v(const type v) { \ gl4es_glRect##suffix(v[0], v[1], v[2], v[3]); \ } to void gl4es_glRect##suffix##v(const type v1, const type *v2) { \ gl4es_glRect##suffix(v1[0], v1[1], v2[0], v2[1]); \ }
And void glRect##suffix##v(const type *v)AliasExport("gl4es_glRect" #suffix "v");
To void glRect##suffix##v(const type v1, const type v2)AliasExport("gl4es_glRect" #suffix "v");
I am not a OpenGL dev, so please close if I'm wrong!