Home  
Login
Username:

Password:

Remember me



Lost Password?

Register now!
Sections
Who's Online
71 user(s) are online (62 user(s) are browsing Forums)

Members: 0
Guests: 71

more...
Support us!
Recent OS4 Files
OS4Depot.net



« 1 ... 10 11 12 (13)


Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Just popping in
Joined:
2012/12/21 10:55
Posts: 27
@kas1e

You have got pointers in this index array!

fpe_glDrawElements(GL_TRIANGLES54GL_UNSIGNED_SHORT0x69378e50), program=0
creating FPE shader 
264(0x68f1bd18)
Use 
FPE program 264
glVertexAttribPointer
(04GL_FLOAT000x6a3258f0)
glVertexAttribPointer(14GL_FLOAT000x6a3254e8)
Indices=26935 36424,26935,36424,0,0,6,7,8,8,7,9,8,9,10,10,9,11,10,11,12,12,11,13,12,13,14,14,13,15,14,15,16,16,15,17,16,17,18,18,17,19,18,19,20,20,19,21,20,21,22,22,21,23,
There are 54 indicesmax value is 36424


26935 == hex 0x6937
36424 == hex 0x8e48

-> 0x69378e48

kinda close to pointer passed to glDrawElements(), isn't it?


   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Just popping in
Joined:
2012/12/21 10:55
Posts: 27
In neverball log:

indeces 43949,51966 -> 0xABADCAFE


   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
@Georg
Probably 0xabadcafe flying there as i on debug kernel + munge enabled in. Anyway that all looks quite strange, like some stack-data--pointer overflow

In meantime will try to print out indicies in lettersfall game (which works, but have trashing), maybe its all about one problem in end.

edit: lettersfall use glDrawArrays only, and there no indicies to print. Anyway probably only roots of problems in neverball will be found, will be clear how to deal with all others problems (probably).

_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Just popping in
Joined:
2012/12/21 10:55
Posts: 27
@kas1e

In gl.c/glDrawElementsCommon() try to change the two places which use gl4es_scratch() to instead alloc tmp memory in another way:

static void glDrawElementsCommon
{
   
void *tmp_scratch NULL;

[..]
   
//gl4es_scratch(..)
   // GLuint *tmp = ...

   
GLuint *tmp malloc(ilen*sizeof(GLuint);
[..]
   
//gl4es_scratch()
   // GLushort *tmp = ...
   
GLushort *tmp malloc(ilen*sizeof(GLushort);
[..]
   if (
tmp_scratchfree(tmp_scratch)
}


Maybe the code later on somewhere by mistake uses gl4es_scratch() in a nested way (reuse scratch, while scratch is already in use by this place here).

   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
@Georg
Tried: didn't make differences.

But what we also tried, its to add to gl.c , at line 1065 the line if(indices && indices[0]>0x2000) printf("Too late...\n");
And, before crash we have that "too late" thing, which dunno, somehow point on race condition maybe ?

_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
@All
Issue with neverball/neverputt was because of gl4es: it crashes even on other platforms (damn). So gl4es guy fix it:
"Fixed a nasty bug when merging drawlist inside a glList and no indices were present".

https://github.com/ptitSeb/gl4es/commi ... bfdb60d4d649e3964708c6455

Now neverball and neverputt both runs fine. And, by FPS it is faster in 2-3 times than minigl version. For example first stage in neverball, in minigl version give 58 fps, in gl4es one give 150fps. In some other hardcore by details level, minigl version give 9fps, gl4es one - 22fps. Dunno why there is faster (in compare with let's say, quake3), as both games use glBegin/glEnd route. But code different anyway, so eveyrthing possible.

Also in MiniGL version in both neverball and neverputt , there is sometime visuall glitchs and "blinks", while in gl4es version on the same places , all renders correctly.


He also for sake of remove from list.c arrays on stack:
https://github.com/ptitSeb/gl4es/commi ... 32eff82b6310f95018b242251

But in end, not fix for neverball, not removing arrays from stack make no fixes for cadog test case and letter's fall textures trashing in menu, sadly :(



Edited by kas1e on 2018/3/27 10:04:35
_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Just popping in
Joined:
2015/6/11 8:51
From Cologne
Posts: 112
@Georg
Quote:
In neverball log: indeces 43949,51966 -> 0xABADCAFE

LOL

@kas1e
Quote:
Issue with neverball/neverputt was because of gl4es: it crashes even on other platforms (damn). So gl4es guy fix it

Great! But why "damn"?

Quote:
Now neverball and neverputt both runs fine. And, by FPS it is faster in 2-3 times than minigl version.

Aha!

Quote:
Dunno why there is faster (in compare with let's say, quake3), as both games use glBegin/glEnd route.

Maybe neverXXXX uses display-lists which probably results in a less inefficient render-path inside gl4es (or maybe he even uses VBOs then?).
Did it also fix Q3?

Quote:
He also for sake of remove from list.c arrays on stack:

I don't think this is wise. The stack-allocated index array shouldn't be an issue by itself (unless the stack is too small of course, but I suppose we can rule that out) and it's much faster than the fastest malloc.
This is the typical "a crash symptom appeared at XYZ, so let's change XYZ"-tactic he should definitely avoid!
So unless he found a true bug there, he should better revert it.


Edited by Daytona675x on 2018/3/27 10:55:47
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
@Daniel
Quote:

Great! But why "damn"?


I was in hope that its all about probems and with cadog test case, and with letters fall trashing, and with quake3 / irrlicht, but as it didn't help anywhere, but only in neverball/neverputt, then damn, as it mean again we on the same point as 2 weeks ago called "we do not know where to find roots".

Quote:

Did it also fix Q3?


He say this issue was very specific: you need to have glList for it to trigger. Other games doesn't used them probably, so it will not fix our issues.

But i anyway do test it of course, and nope, all the same as we have before. But with neverball/neverputt he reproduce it on his side, so it was easy, while other issues he can't reproduce.

In other words we again on the same place called random-unknown-shit :)



_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
@Daniel
Btw, did you checked irrlicht example ? There is also 2 verions hacked and non hacked, and issues are the same as in quake3. Maybe it will give some more info in compare with just q3 ?

_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Just popping in
Joined:
2016/3/10 14:15
From Poland
Posts: 20
@kas1e
Next test GL4ES ... SuperTuxKart ?

http://www.supertuxkart-amiga.de/amigaos.html

   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Just popping in
Joined:
2012/12/21 10:55
Posts: 27
@kas1e

Quote:

Probably 0xabadcafe flying there as i on debug kernel + munge enabled in.


Btw, in case the clib uses it's own special routines for malloc + co. (instead of just Exec memory/pool functions) then mungwall like memory tool may not be able to track each and every single malloc'ed memory.

This may hide errors which such tools can detect, so sometimes for debugging things it helps to temporarily have in your code your own very simple implementation for malloc/calloc/realloc/free which simply map to AllocVec,FreeVec(),CopyMem(). Just put your replacement function somewhere in the source and that should be enough to cause the clib ones to be overriden (at least with static clib).




   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2006/11/20 16:26
From Norway
Posts: 2685
@kas1e

Can you just write Validator, that check if the content of the table is correct, and report where it gets broken with printf() and pause it with getchar();

gl_...(...)
validate(__FUNCTION__,__LINE__,...)
gl_...(...)
validate(__FUNCTION__,__LINE__,...)
gl_...(...)
validate(__FUNCTION__,__LINE__,...)

etc.

_________________
(NutsAboutAmiga)

Basilisk II for AmigaOS4
AmigaInputAnywhere
Excalibur
and other tools and apps.
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
@Georg
I build all with newlib, but yes, you are right that not all mungwall tools works the same. For example munge functionality of debug kernel do not catch everything, not from clib2, not from newlib. While when you add memguard at top, it can catch much more and not only from clib2 ones, but from newlib ones as well (which is strange, as menguard kind of dated). Through currently cant use memguard on x5k, as it hits a lot to some system component, so until that fixed cant use it.


_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top

Re: GL4ES: another OpenGL over OpenGLES2 emulation - some tech. info and porting progress
Home away from home
Joined:
2007/9/11 11:31
From Russia
Posts: 4498
Some report so to show it not forgotten:

1). We found some issue in the shader related code in NOVA (false assign of some alpha components to wrong values): http://amigadeveloper.com/bugreports/view.php?id=318
But, even if it will be fixed, that probably not related to the trashing issues in letters fall, that strange issues in cadog-cutoff-test, and with issues with quake3 & irrlich engine.

2). Now as i can do nothing more about, i will setup some ppc linux on my x5k, compile some glES emulator (software mesa one probabaly), and will check gl4es on linux. By that we can (or can't) rule out issues with big endianes. If any of issues we have on os4 now will be on linux too: then gl4es need more ppc fixes , if not, then it will mean our side (nova, ogles, sdl, my dirty hands or whatever else).

3). We also can wait till nova will have support of arrays in the shaders, then, i may try to use Regal too, to see, if it will possibe to compile the same games , and if they will or will not behave the same as gl4es in term of bugs. But that of course "if", as it needs nova-with-arrays , and no one can be sure that Regal is matured enough to run those games we run over gl4es.

At this moment that all about what i can think of.

_________________
Join us to improve dopus5!
zerohero's mirror of os4/os3 crosscompiler suites
   Report Go to top


« 1 ... 10 11 12 (13)



[Advanced Search]


Powered by XOOPS 2.0 © 2001-2016 The XOOPS Project