juzzlin / DustRacing2D

Dust Racing 2D is a traditional top-down car racing game including a level editor.
http://juzzlin.github.io/DustRacing2D/index.html
GNU General Public License v3.0
299 stars 67 forks source link

Cars are not rendered on FreeBSD #58

Closed AMDmi3 closed 3 years ago

AMDmi3 commented 5 years ago

FreeBSD amd64, dustrac 2.0.3

    Vendor: Intel Open Source Technology Center (0x8086)
    Device: Mesa DRI Intel(R) HD Graphics 520 (Skylake GT2)  (0x1916)
    Version: 18.3.2
    Accelerated: yes
    Video memory: 3072MB
    Unified memory: yes
    Preferred profile: core (0x1)
    Max core profile version: 4.5
    Max compat profile version: 3.0
    Max GLES1 profile version: 1.1
    Max GLES[23] profile version: 3.2

Cars and some other elements are rendered as black rectangles. I assume some shader problem. No other OpenGL apps show any artifacts.

dustrac

juzzlin commented 5 years ago

Could you paste the console logs when the game starts?

AMDmi3 commented 5 years ago

Oh sorry, I wanted to post these until I completely forgot about this. With --debug:

[Mon Jul 29 23:47:22 2019] <I> Dust Racing 2D version 2.0.3
[Mon Jul 29 23:47:22 2019] <I> Compiled against Qt version 5.12.2
[Mon Jul 29 23:47:22 2019] <W> Failed to load translations for C
[Mon Jul 29 23:47:22 2019] <I> Screen: 0/3
[Mon Jul 29 23:47:22 2019] <I> Screen resolution: 1600 1200
[Mon Jul 29 23:47:22 2019] <I> Virtual resolution: 1600 1200 0
[Mon Jul 29 23:47:22 2019] <D> Creating the renderer..
[Mon Jul 29 23:47:22 2019] <I> OpenGL Version: 3.0 Mesa 18.3.2
[Mon Jul 29 23:47:22 2019] <I> Loading font /usr/local/share/dustrac/fonts/DejaVuSans-Bold.ttf..
[Mon Jul 29 23:47:22 2019] <I> Loaded font DejaVu Sans
[Mon Jul 29 23:47:22 2019] <D> Font slot size: 71x80
[Mon Jul 29 23:47:22 2019] <D> Font texture size (initial): 568x1200
[Mon Jul 29 23:47:22 2019] <I> Sound device: OpenAL Soft
[Mon Jul 29 23:47:23 2019] <I> Loading race tracks from '/usr/local/share/dustrac/levels'..
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/curvastone.trk', index=8
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Desert Storm.trk', index=13
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Diamond.trk', index=14
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Far Lands.trk', index=15
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Figure 8.trk', index=12
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/infinity.trk', index=0
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/monza.trk', index=3
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Radiator.trk', index=17
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/ring.trk', index=9
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/straight.trk', index=7
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/suzuka.trk', index=11
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/triangle.trk', index=5
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Twineburg.trk', index=18
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/twister.trk', index=10
[Mon Jul 29 23:47:23 2019] <I>   Found '/usr/local/share/dustrac/levels/Western Valley.trk', index=16
[Mon Jul 29 23:47:23 2019] <I> Loading race tracks from '/home/marakasov/DustRacingTracks'..
[Mon Jul 29 23:47:23 2019] <I>   No race tracks found.
[Mon Jul 29 23:47:23 2019] <I> Loading race tracks from '/home/marakasov/.local/share/DustRacing2D/tracks'..
[Mon Jul 29 23:47:23 2019] <I>   No race tracks found.
[Mon Jul 29 23:47:23 2019] <I> A total of 15 race track(s) loaded.
[Mon Jul 29 23:47:29 2019] <I> Quit selected from the main menu.
juzzlin commented 5 years ago

That looks very weird. It's like the color keying / alpha tests doesn't work. But then again the startlights work partly..?

juzzlin commented 5 years ago

Would it be possible for you to try to find an earlier version that does work? Preferably a git commit?

AMDmi3 commented 5 years ago

Will try, but not sure how far into the past I can descend - I've discovered this while updating FreeBSD port from 1.11.0 and that I couldn't event test as it segfaults.

juzzlin commented 5 years ago

I'm mostly interested in 2.0.0. It had some shader changes.

juzzlin commented 5 years ago

How is this built for FreeBSD? Any CMake options other than default?

juzzlin commented 5 years ago

On my Intel laptop I have:


[Tue Jul 30 00:15:41 2019] <I> Dust Racing 2D version 2.0.3
[Tue Jul 30 00:15:41 2019] <I> Compiled against Qt version 5.12.2
[Tue Jul 30 00:15:42 2019] <W> Failed to load translations for en_US
[Tue Jul 30 00:15:42 2019] <I> Screen: 0/1
[Tue Jul 30 00:15:42 2019] <I> Screen resolution: 1920 1080
[Tue Jul 30 00:15:42 2019] <I> Virtual resolution: 1920 1080 1
[Tue Jul 30 00:15:42 2019] <D> Creating the renderer..
[Tue Jul 30 00:15:42 2019] <I> OpenGL Version: 3.0 Mesa 19.0.2
[Tue Jul 30 00:15:42 2019] <I> Loading font ./data/fonts/DejaVuSans-Bold.ttf..
[Tue Jul 30 00:15:42 2019] <I> Loaded font DejaVu Sans
[Tue Jul 30 00:15:42 2019] <D> Font slot size: 71x80
[Tue Jul 30 00:15:42 2019] <D> Font texture size (initial): 568x1200
[Tue Jul 30 00:15:42 2019] <I> Sound device: OpenAL Soft
AMDmi3 commented 5 years ago

How is this built for FreeBSD? Any CMake options other than default?

CMAKE_ARGS= -DReleaseBuild=on \
        -DDATA_PATH=${DATADIR} \
        -DDOC_PATH=${DOCSDIR}

and a couple of patches which shouldn't affect the runtime:

(btw, please consider merging at least OpenGL::GL bits)

AMDmi3 commented 5 years ago

2.0.0 does not build:

/usr/bin/ld: error: undefined symbol: qt_qhash_seed
>>> referenced by main.cpp
>>>               src/editor/CMakeFiles/dustrac-editor.dir/main.cpp.o:(main)

2.0.1 shows black screen 2.0.2 looks the same as 2.0.3

juzzlin commented 5 years ago

That qt_qhash_seed issue seems to be fixed in 2.0.1 which basically is the same as 2.0.0.

juzzlin commented 5 years ago

Could you try boot to Ubuntu 18.04 from e.g. a USB stick and try to run 2.0.3 there? I just want to know if this happens due to some particular HW or SW.

AMDmi3 commented 5 years ago

Will do, but I'll only have time for this in a couple of weeks.

AMDmi3 commented 3 years ago

The problem is gone in 2.1.1