Month: May 2024

  • World of Warcraft WotLK 3.3.5 can do OpenAL audio

    World of Warcraft WotLK 3.3.5 can do OpenAL audio

     

    I recently set-up a private server for WoW, and have to tweak everything and anything, including an old game from back in 2010 that already runs relatively well :p

    WoW by-default uses FMOD, and can’t do hardware-accelerated audio in Vista+. I was digging around some strings in Wow.exe and found references to OpenAL. Some more digging, I found the cvar “Sound_EnableOpenAL”.

    Tossing that cvar into Config.wtf along with enabling Hardware acceleration allows OpenAL to be used in WoW! With the old Creative OpenAL implementation, WoW takes a few seconds longer to load to the log-in screen.

    Turns out, dropping-in OpenAL Soft works no problem! SESound.log reports additional sound channels (126, but client only allows and resets to 64 max), and OpenAL Soft’s AL caps viewer reports a lot more functionality over the Creative implementation.

    Process Explorer shows the dropped-in OpenAL Soft dll being loaded (no OpenAL dll is loaded without the cvar), and audio works in WoW.

     

    With about 5 minutes of playing with old desktop Stereo speakers, I didn’t notice anything sounding different. Stereo sound still worked (tested by rotating near the fire in Goldshire Inn). I don’t know if there’s any advantages going through OpenAL Soft vs dsound, but this sounds like a better option for operating systems Vista+ (including 10 LTSC 21H2).

    Interestingly there’s also strings mentions of ASIO, but I haven’t found a way to tangibly test or enable it. I doubt WoW 3.3.5 reasonably benefits from the lowest of low-latency audio.

  • Old School RuneScape Legacy Java Client vs New Official Client (C++) Brightness

    Old School RuneScape Legacy Java Client vs New Official Client (C++) Brightness

    I was curious on a framerate test in Lumbridge castle between the Java and C++ OSRS clients, and found that there’s a notable difference in the lowest brightness of the game world, with the C++ new client being slightly brighter (screenshots at the bottom; I recommend new Tabs to switch between for comparisons).

    There are other subtle differences too like the camera distance (both are at default), the minimap, and fine details on the grass tiles on the outer-edge around the fences. On the top-left-most Gem rocks, the outer-left rock’s shadow loses some gradient and fine details on the shadow on the that are seemingly “smoothed-out” on the C++ client.

    I prefer the Java client’s more saturated colors and the harder-red. I’ve played from the Java client at 50 FPS for years and I’m used to it (along with needing no extra features from the C++ client), but I got used to that smooth camera movement with GPU acceleration.

    I’m playing from the Java client again currently (Jagex Launcher), and after a few days I haven’t felt the need to switch back to C++. Black colors actually being black and other colors being saturated is nice! You can find my RuneScape hiscores and screenshots here.

    Legacy Java Client:

    Legacy Java Client

    New Official Client (C++):

    New Official Client (C++)

     

  • Different compression formats for initramfs vs uncompressed

    I’ve been working on improving boot times lately. I was doing uncompressed images in dracut.conf on the assumption that loading is faster without involving decompression, but I never tested this theory until now.

     

    First I generated the images, got the final size, and the amount of time it took to create the images. This is handled by:

     

    clear && sudo -e ‘/etc/dracut.conf.d/99-custom.conf’ &&  sudo time dracut –force –regenerate-all && sudo time lsinitrd | grep ‘Image:’ 

    Next, I rebooted and immediately ran systemd-analyze

    In-short, my theory was right with cat (uncompressed) coming in first at 15.112s, but gzip, lzo, and lz4 were still within 15 seconds and are half the file-size!

    Testing done on a Dell Latitude 5591 (BIOS 1.32), openSUSE Tumbleweed (GNOME, 6.8.8-1-default), i5-8400H, SK hynix Gold P31 (1TB), UEFI mode, unencrypted with root on ext4.

    cat
    52M
    3.13user 1.35system 0:04.18elapsed 107%CPU
    0.25user 0.45system 0:00.41elapsed 169%CPU
    Startup finished in 4.491s (firmware) + 603ms (loader) + 452ms (kernel) + 3.874s (initrd) + 5.691s (userspace) = 15.112s
    graphical.target reached after 5.690s in userspace.

    gzip
    26M
    11.61user 1.28system 0:05.05elapsed 255%CPU
    2.18user 0.27system 0:02.08elapsed 118%CPU
    Startup finished in 4.490s (firmware) + 504ms (loader) + 621ms (kernel) + 4.266s (initrd) + 5.602s (userspace) = 15.485s
    graphical.target reached after 5.601s in userspace.

    bzip2
    26M
    6.82user 1.28system 0:07.79elapsed 104%CPU
    9.31user 0.41system 0:09.19elapsed 105%CPU
    Startup finished in 4.477s (firmware) + 503ms (loader) + 2.651s (kernel) + 4.274s (initrd) + 5.572s (userspace) = 17.479s
    graphical.target reached after 5.572s in userspace.

    lzma
    21M
    19.94user 1.32system 0:20.89elapsed 101%CPU
    5.89user 0.34system 0:05.74elapsed 108%CPU
    Startup finished in 4.513s (firmware) + 486ms (loader) + 2.369s (kernel) + 4.151s (initrd) + 5.626s (userspace) = 17.147s
    graphical.target reached after 5.626s in userspace.

    xz
    23M
    23.75user 1.47system 0:07.23elapsed 348%CPU
    4.82user 0.34system 0:04.65elapsed 110%CPU
    Startup finished in 4.592s (firmware) + 496ms (loader) + 1.450s (kernel) + 4.246s (initrd) + 5.904s (userspace) = 16.690s
    graphical.target reached after 5.904s in userspace.

    lzo
    26M
    11.58user 1.35system 0:05.06elapsed 255%CPU
    2.14user 0.31system 0:02.07elapsed 118%CPU
    Startup finished in 4.647s (firmware) + 510ms (loader) + 631ms (kernel) + 4.004s (initrd) + 5.861s (userspace) = 15.655s
    graphical.target reached after 5.861s in userspace.

    lz4
    26M
    11.60user 1.31system 0:05.06elapsed 255%CPU
    2.14user 0.30system 0:02.07elapsed 118%CPU
    Startup finished in 4.507s (firmware) + 507ms (loader) + 631ms (kernel) + 4.165s (initrd) + 5.891s (userspace) = 15.702s
    graphical.target reached after 5.891s in userspace.

    zstd
    25M
    8.24user 1.39system 0:05.94elapsed 162%CPU
    0.60user 0.45system 0:00.47elapsed 224%CPU
    Startup finished in 4.500s (firmware) + 501ms (loader) + 503ms (kernel) + 4.071s (initrd) + 7.000s (userspace) = 16.577s
    graphical.target reached after 7.000s in userspace.