to move the discussion of the dosbox glide patch to the right discussion... 😀
When I start Dosbox, with the [glide]glide=true in the config, Dosbox crashes with
Glide:LFB access: read-write
Bus error
I guess I need to change the grport. But to what?
Just for the record, this is under OS X 10.6.1 😀 AND I've been using the CVS of Dosbox.
I'm attaching the error report, maybe this helps...
From a quick look at it, it crashes in Openglide, so it could stay there 😀
When openglide starts, it performs some rdtsc calls to get some timing information. I'll see if it is possible to skip that...
seem like reading /proc/cpuinfo does not work. Clock frequency is used just for some debugging info, so you could safely disable complete ClockFrequency(void) function in clock.cpp
Hmm, I just commented out the the whole thing in clock.cpp and then had to comment out ClockFreq = ClockFrequency( ); in glutil.cpp as well.
Now 3DFX Tomb Raider exits with the message "No PCI bus detected"
At least something, neither Dosbox nor Tomb Raider crashed 😀
console output:
CONFIG:Loading primary settings from config file /users/dominus/library/preferences/DOSBox 0.73 Preferences
CONFIG:Loading addit […] Show full quote
CONFIG:Loading primary settings from config file /users/dominus/library/preferences/DOSBox 0.73 Preferences
CONFIG:Loading additional settings from config file /users/dominus/documents/dosbox/tomb.conf
MIDI:Opened device:coremidi
Glide:LFB access: read-write
Glide:GLIDE_PageHandler installed at 0x60000000 (384 pages)
One joystick reported, initializing with 4axis
Using joystick Adaptoid with 2 axes, 14 buttons and 0 hat(s)
That means it is loading the original 3dfx glide2x.ovl not the dosbox modified one. Put the dosbox glide2x.ovl in the game directory. Make sure it matches the version of the patch (if you got the patch from this thread, take the ovl as well)
I have ONLY the glide2x.ovl from the first post of this thread on my system. I even copied the one from the debug folder in the zip and get the following log:
Then you got the wrong TR patch, the one that has the ovl already built in...you need to get the Voodoo rush patch, tomb3dfx.exe should be 873739 bytes (or similar).
Ok, I found the correct Tomb Raider patch (I didn't know there were two voodoo patches, I got the first one from the eidos pages).
Tomb Raider starts now, but after the videos, when it starts to render it crashes again with a bus error.
Console looks like this:
Glide:Activated
Bus error
Same happens with Lands of Lore 2.
Attached again the apple error log (don't wonder, I named the openglided dosbox, glidebox)
It seems to crash in openglide again. Perhaps you can activate the logging (uncomment #define OGL_ALL in GlOgl.h, recompile and then post the contents of Openglid.log). Maybe add some more logging in grSstWinOpen() to see exactly where it crashes. I'm afraid grSstWinOpen + 181 doesn't tell me too much 😀
Really except for doing simple tasks I'm lost in code.
I have no idea where in that code I should throw in some GlideMsg();
When I try I only make Dosbox crash with a "Glide:grSstWinOpen failed!" before the Bus Error, but not with an entry in Openglide. I'm really sorry for being that slow but I need some holding hands now 😀
Could you give me an example of where and how in grSstWinOpen() I should enter some glidemsg()?
to the top of the function (line 249) so that we can see what parameters get passed. I still don't see where the code could crash with a null pointer dereference if the parameters are sane. So you could just add a simple
GlideMsg("1"); (increment the counter later)
after every line of code (just until before the original GlideMsg( "grSstWinOpen...") we know it doesn't come that far). The code after the last msg will be the problem 😀
If some moderator has some time, perhaps these last few posts could be split into a seperate topic Openglide on OS X in the Openglide development forum 😀
is the output in the log when I just copy the glidemsg from your post there.
I'll see about the other stuff either tonight or tomorrow, now I gotta go 😀
If some moderator has some time, perhaps these last few posts could be split into a seperate topic Openglide on OS X in the Openglide development forum 😀
It crashes after these lines? Then it must be InitWindow. Perhaps you can add some msg lines in InitWindow()? Also just below the InitialiseOpenGLWindow() in Glide.cpp (line 79), you can add:
1 2 if(glGetString( GL_RENDERER ) == NULL) { 3 GlideMsg( "glGetString( GL_RENDERER ) returned NULL!"); 4 return false; 5 } 6 7 if ( !strcmp( (char*)glGetString( GL_RENDERER ), "GDI Generic" ) ) 8 ReportWarning("You are running in a Non-Accelerated OpenGL!!!\nThings can become really slow");
That strcmp might crash if it comes that far and OpenGL wasn't initialized properly.
(the last lines are the glide msg from grSstWinOpen())
Just for making sure, when compiling I get the following warnings:
1grguDepth.cpp: In function ‘void grDepthBufferMode(GrDepthBufferMode_t)’: 2grguDepth.cpp:85: warning: deprecated conversion from string constant to ‘char*’ 3grguDepth.cpp: In function ‘void grDepthMask(FxBool)’: 4grguDepth.cpp:106: warning: deprecated conversion from string constant to ‘char*’ 5grguDepth.cpp: In function ‘void grDepthBufferFunction(GrCmpFnc_t)’: 6grguDepth.cpp:131: warning: deprecated conversion from string constant to ‘char*’ 7grguDepth.cpp: In function ‘void grDepthBiasLevel(FxI16)’: 8grguDepth.cpp:163: warning: deprecated conversion from string constant to ‘char*
...
1grguMisc.cpp: In function ‘void grCullMode(GrCullMode_t)’: 2grguMisc.cpp:78: warning: deprecated conversion from string constant to ‘char*’
...
1grguSstGlide.cpp: In function ‘FxBool grSstWinOpen(FxU, GrScreenResolution_t, GrScreenRefresh_t, GrColorFormat_t, GrOriginLocation_t, int, int)’: 2grguSstGlide.cpp:391: warning: deprecated conversion from string constant to ‘char*’ 3grguSstGlide.cpp: In function ‘void grSstOrigin(GrOriginLocation_t)’: 4grguSstGlide.cpp:571: warning: deprecated conversion from string constant to ‘char*’ 5grguSstGlide.cpp: In function ‘void grSstIdle()’: 6grguSstGlide.cpp:703: warning: deprecated conversion from string constant to ‘char*’
....
1grguTex.cpp: In function ‘void grTexClampMode(GrChipID_t, GrTextureClampMode_t, GrTextureClampMode_t)’: 2grguTex.cpp:207: warning: deprecated conversion from string constant to ‘char*’ 3grguTex.cpp: In function ‘void grTexFilterMode(GrChipID_t, GrTextureFilterMode_t, GrTextureFilterMode_t)’: 4grguTex.cpp:280: warning: deprecated conversion from string constant to ‘char*’ 5grguTex.cpp: In function ‘void grTexMipMapMode(GrChipID_t, GrMipMapMode_t, FxBool)’: 6grguTex.cpp:310: warning: deprecated conversion from string constant to ‘char*’
...
1grguLfb.cpp: In function ‘FxBool grLfbReadRegion(GrBuffer_t, FxU32, FxU32, FxU32, FxU32, FxU32, void*)’: 2grguLfb.cpp:237: warning: deprecated conversion from string constant to ‘char*’ 3grguLfb.cpp: In function ‘FxBool grLfbWriteRegion(GrBuffer_t, FxU32, FxU32, GrLfbSrcFmt_t, FxU32, FxU32, FxI32, void*)’: 4grguLfb.cpp:297: warning: deprecated conversion from string constant to ‘char*’
...
1GLRender.cpp: In function ‘void RenderUpdateArrays()’: 2GLRender.cpp:129: warning: deprecated conversion from string constant to ‘char*’ 3GLRender.cpp: In function ‘void RenderDrawTriangles()’: 4GLRender.cpp:330: warning: deprecated conversion from string constant to ‘char*’ 5GLRender.cpp: In function ‘void RenderAddTriangle(const GrVertex*, const GrVertex*, const GrVertex*, bool)’: 6GLRender.cpp:712: warning: deprecated conversion from string constant to ‘char*’ 7GLRender.cpp: In function ‘void RenderAddLine(const GrVertex*, const GrVertex*, bool)’: 8GLRender.cpp:1197: warning: deprecated conversion from string constant to ‘char*’ 9GLRender.cpp: In function ‘void RenderAddPoint(const GrVertex*, bool)’: 10GLRender.cpp:1567: warning: deprecated conversion from string constant to ‘char*’
1grguBuffer.cpp: In function ‘void grBufferClear(GrColor_t, GrAlpha_t, FxU16)’: 2grguBuffer.cpp:74: warning: deprecated conversion from string constant to ‘char*’ 3grguBuffer.cpp: In function ‘void grBufferSwap(int)’: 4grguBuffer.cpp:112: warning: deprecated conversion from string constant to ‘char*’ 5grguBuffer.cpp: In function ‘void grRenderBuffer(GrBuffer_t)’: 6grguBuffer.cpp:150: warning: deprecated conversion from string constant to ‘char*’
...
1grguColorAlpha.cpp: In function ‘void grDitherMode(GrDitherMode_t)’: 2grguColorAlpha.cpp:49: warning: deprecated conversion from string constant to ‘char*’ 3grguColorAlpha.cpp: In function ‘void grColorMask(FxBool, FxBool)’: 4grguColorAlpha.cpp:109: warning: deprecated conversion from string constant to ‘char*’ 5grguColorAlpha.cpp: In function ‘void grAlphaTestReferenceValue(GrAlpha_t)’: 6grguColorAlpha.cpp:296: warning: deprecated conversion from string constant to ‘char*’ 7grguColorAlpha.cpp: In function ‘void grAlphaTestFunction(GrCmpFnc_t)’: 8grguColorAlpha.cpp:322: warning: deprecated conversion from string constant to ‘char*’ 9grguColorAlpha.cpp: In function ‘void grAlphaBlendFunction(GrAlphaBlendFnc_t, GrAlphaBlendFnc_t, GrAlphaBlendFnc_t, GrAlphaBlendFnc_t)’: 10grguColorAlpha.cpp:424: warning: deprecated conversion from string constant to ‘char*’ 11grguColorAlpha.cpp: In function ‘void grGammaCorrectionValue(float)’: 12grguColorAlpha.cpp:570: warning: deprecated conversion from string constant to ‘char*’