Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Error loading fonts
01-22-2012, 12:58 AM,
Error loading fonts
Hey all, I'm trying to get VDrift to work on my computer and I've gotten past a lot of errors already. I'm running Slackware 13.37 x86_64. I'm installing everything from source. Bullet, SDL, SDL_image, SDL_gfx, and etc, are all the latest available. So far, I've been able to install it just fine. However, VDrift just doesn't want to load the fonts. Here's my console output:

shonumi@darkstar:~$ vdrift
INFO: Multi-processor system detected.  Run with -multithreaded argument to enable multithreading (EXPERIMENTAL).
INFO: Starting VDrift: development-full, Version: exported, O/S: Unix
INFO: Home directory: /home/shonumi
INFO: Settings file: /home/shonumi/.vdrift/VDrift.config (does not exist, will be created)
INFO: Data directory: /usr/local/share/games/vdrift/data
      DATA_DIR: /usr/local/share/games/vdrift/data
INFO: Temporary directory: /home/shonumi/.vdrift/tmp
INFO: Log file: /home/shonumi/.vdrift/log.txt
ERROR: Failed to load /home/shonumi/.vdrift/VDrift.config
INFO: The last VDrift startup was unsuccessful.
      Settings have been set to failsafe defaults.
      Your original VDrift.config file was backed up to VDrift.config.backup
INFO: SDL initialization successful
INFO: SDL video query was successful
INFO: Disabling antialiasing
INFO: Display change was successful: 800x600x16 16z fullscreen=0
INFO: Video card information:
      Vendor: NVIDIA Corporation
      Renderer: GeForce GTX 550 Ti/PCI/SSE2
      Version: 4.2.0 NVIDIA 290.10
      Maximum texture size: 16384
      Maximum varying floats: 124
      Using GLEW 1.5.7
INFO: Maximum color attachments: 8
INFO: Maximum draw buffers (1 required): 8
INFO: Disabling shaders
ERROR: Error loading texture file: /usr/local/share/games/vdrift/data/textures/weather/cubereflection-nosun.png
ERROR: Error loading texture file: /usr/local/share/games/vdrift/data/textures/weather/cubelighting.png
INFO: Maximum anisotropy: 16
INFO: 1 joystick found:
INFO:     0. Logitech Logitech Dual Action
INFO: Loading car controls from: /home/shonumi/.vdrift/controls.config
INFO: Update status file /home/shonumi/.vdrift/updates.config will be created
INFO: Sound initialization information:
INFO: Obtained audio device:
      Frequency: 44100
      Format: 32784
      Bits per sample: 16
      Channels: 2
      Silence: 0
      Samples: 940
      Size: 3760
      Sound initialization successful
ERROR: Error loading texture file: /home/shonumi/.vdrift//skins/simple/fonts/freesans_noshaders.png
ERROR: Error loading texture file: /usr/local/share/games/vdrift/data//skins/simple/fonts/freesans_noshaders.png
ERROR: Error loading texture file: /usr/local/share/games/vdrift/data/trackparts/freesans_noshaders.png
ERROR: Failed to load freesans_noshaders.png from: /home/shonumi/.vdrift//skins/simple/fonts /usr/local/share/games/vdrift/data//skins/simple/fonts /usr/local/share/games/vdrift/data/carparts /usr/local/share/games/vdrift/data/trackparts
ERROR: Error loading fonts
INFO: Exiting

I've got the vdrift-data in /usr/local/share/games/vdrift/data, and I've verified that files are all there, so I think the data-dir's fine. What's puzzling me are the double forward slashes when it tries to look for the "skins" directory, but I don't know if that's the problem or not. the files "/usr/local/share/games/vdrift/data/textures/weather/cubereflection-nosun.png" and "/usr/local/share/games/vdrift/data/textures/weather/cubelighting.png" also exist but they fail to load just like the fonts. I've been trying to figure this out for a while, but to no avail. Any help would be appreciated, thanks.
01-23-2012, 10:18 PM,
so if you do
ls -l /usr/local/share/games/vdrift/data/textures/weather/cubereflection-nosun.png
the file is there?
01-23-2012, 10:34 PM,
Could it be that your version of SDL_image was compiled without png support?

Something else to try: add IMG_Init() right before the InitCoreSubsystems call in src/game.cpp
01-24-2012, 02:08 AM,
"ls -l" shows the file existing.

-rw-r--r-- 1 shonumi shonumi 1831113 Jan 21 17:28 /usr/local/share/games/vdrift/data/textures/weather/cubereflection-nosun.png

Scons won't build VDrift when I added the IMG_Init() call because the function is out of scope.

src/game.cpp: In member function 'void GAME::Start(std::list<std::basic_string<char> >&)':
src/game.cpp:149:11: error: 'IMG_Init' was not declared in this scope
src/game.cpp: At global scope:
src/game.cpp:2532:6: warning: unused parameter 'dt'
scons: *** [build/game.o] Error 1
scons: building terminated because of errors.

But I believe you were right about SDL_image being compiled without PNG support. I tried to build my own game, Mass Blaster, which uses SDL and SDL_image to load PNGs. All of the images refused to load. I'm not sure how I managed to build it that way; all the other times went just fine.

I'll try rebuilding SDL_image and report on how that goes. At this moment, it's not just about playing VDrift; I need SDL_image to make my games too. :p
01-24-2012, 03:21 PM,
New Problem - High Frame Rate
Alright! SDL_image was the problem after all. Everything looks to be loading just fine. Unfortunately another problem has cropped up. VDrift seems to be running way too fast. At least that's what the FPS tells me; it says it's running at around 1000 FPS for menus and 700-750 for races. Is there anyway to limit the frame rate? This eats up 100% of one of my cores (running on an i5 2500K) so something doesn't seem right about that. This happens even when I use the "-multithreaded" CLI argument

EDIT: Nevermind, silly me. The problem was with the nVidia driver settings. "Sync to VBlank" needed to be checked. Now VDrift runs at 60FPS and barely breaks 30% of one of my CPU cores. The game works like a charm. I'm writing articles about games on Linux right now and VDrift is one of them. Evertything looks and works great at the moment. Now, if only I knew how to drive decently... Anyway, thanks for the help!
01-24-2012, 09:52 PM,
No problem, glad we got it figured out!

Forum Jump:

Users browsing this thread: 1 Guest(s)