Skip to content

Painkiller Black Edition (the original, not the HD remaster) doesn't size it's game window properlyΒ #3762

Closed

Description

@Deus-nsf

This is fixable with PROTON_USE_WINED3D=1 %command% but the problem is that it uses direct3d to opengl, it doesn't use dxvk anymore this way, so all the dxvk.conf options are inaccessible. OpenGL is "fine" but can have severe frame pacing and input latency issues with Vsync on (even when there's no action, GPU and CPU underutilized), and SteamOS forces Vsync ON even when "allow tearing" is enabled (it does nothing).

Would be great to have good support for this game, as it's one of the best shooters ever made :)

Activity

  1. Blisto91 commented on Dec 22, 2023

    @Blisto91
    Collaborator

    You should post more details like a screenshot since it isn't very clear what is meant. Also remember logs.

    The issue presents itself like below when you start the game

    Screenshot

    image

    It can be worked around by forcing a aspect ratio e.g. d3d9.forceAspectRatio = 16:9 for my monitor. not anyway for all resolutions. See below

    Log without config (quite spammy)
    Painkiller_d3d9-no-config.log
    Log with config
    Painkiller_d3d9-yes-config.log

    Edit: extra notes.
    The window covers the screen proper back in d9vk 0.11 and starts small with 0.12 but neither actually render anything but a black window.
    Apitraces captured with dxvk on Linux didn't seem replayable.

  2. Deus-nsf commented on Dec 23, 2023

    @Deus-nsf
    Author

    Thank you for the answer! I should have precised that I'm on the Steam Deck, but I was able to reproduce this issue in desktop mode as well.
    Switching back to DXVK (WINED3D=0), unfortunately force aspect ratio 16:9 doens't help, both in desktop an deck ui, unless the lowest resolution is selected. it's working because only 16:9 resolutions are available

  3. waspennator commented on Mar 18, 2024

    @waspennator

    I can also confirm the same issue on my oled deck too where it just resizes itself to a small box on the top left of the screen, plus it's not just Painkiller Black Edition that's effected, but the majority of the Painkiller games save for hell and damnation, found the same issue with the game's below.

    Painkiller overdose
    Painkiller Reoccurring evil
    Painkiller Redemption
    Painkiller resurrection

  4. waspennator commented on Apr 13, 2024

    @waspennator

    Tried out Black Edition on my windows laptop to see what would happen on there, game wouldn't boot up with DXVK, sharing a link of my Trace file with it incase it helps.

    https://www.mediafire.com/file/uc2pwrf5k5fzg5r/Painkiller.zip/file

  5. Deus-nsf commented on Apr 13, 2024

    @Deus-nsf
    Author

    Weird, just tried on my end on Windows with DXVK 2.3 and 2.3.1 and it works, Nvidia GTX 1080 Ti.
    I had to force aspect ratio with the dxvk option to have access to my native resolution for some reason though.

  6. DarkSwan86 commented on Oct 7, 2024

    @DarkSwan86

    I can confirm that the behaviour of Painkiller Black edition is still the same as the one shown by the screenshot from @Blisto91.

    I'm using the latest Proton-GE with dxvk commit e6f89062f5a5af96c4ae28d2ac441e54fbe94068.

    System:
      Host: fedora Kernel: 6.10.12-200.fc40.x86_64 arch: x86_64 bits: 64
        compiler: gcc v: 2.41-37.fc40
      Desktop: KDE Plasma v: 6.1.5 tk: Qt v: N/A wm: kwin_wayland dm: SDDM
        Distro: Fedora Linux 40 (KDE Plasma)
    CPU:
      Info: 16-core model: AMD Ryzen 9 5950X bits: 64 type: MT MCP arch: Zen 3+
        rev: 0 cache: L1: 1024 KiB L2: 8 MiB L3: 64 MiB
      Speed (MHz): avg: 1418 high: 4116 min/max: 550/5084 cores: 1: 550 2: 3599
        3: 3599 4: 550 5: 550 6: 550 7: 550 8: 550 9: 4116 10: 550 11: 3600 12: 3453
        13: 550 14: 550 15: 550 16: 3602 17: 3600 18: 550 19: 550 20: 550 21: 3596
        22: 550 23: 550 24: 550 25: 550 26: 550 27: 550 28: 550 29: 550 30: 550
        31: 550 32: 3586 bogomips: 217614
      Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3
    Graphics:
      Device-1: AMD Navi 22 [Radeon RX 6700/6700 XT/6750 XT / 6800M/6850M XT]
        vendor: XFX driver: amdgpu v: kernel arch: RDNA-2 pcie: speed: 16 GT/s
        lanes: 16 ports: active: DP-1 empty: DP-2, DP-3, HDMI-A-1, Writeback-1
        bus-ID: 0a:00.0 chip-ID: 1002:73df
      Display: wayland server: X.org v: 1.20.14 with: Xwayland v: 24.1.3
        compositor: kwin_wayland driver: X: loaded: amdgpu
        unloaded: fbdev,modesetting,radeon,vesa dri: radeonsi gpu: amdgpu
        display-ID: 0
      Monitor-1: DP-1 res: 2560x1440 size: N/A
      API: EGL v: 1.5 platforms: device: 0 drv: radeonsi device: 1 drv: swrast
        gbm: drv: kms_swrast surfaceless: drv: radeonsi wayland: drv: radeonsi x11:
        drv: radeonsi
      API: OpenGL v: 4.6 compat-v: 4.5 vendor: amd mesa v: 24.1.7 glx-v: 1.4
        direct-render: yes renderer: AMD Radeon RX 6750 XT (radeonsi navi22 LLVM
        18.1.6 DRM 3.57 6.10.12-200.fc40.x86_64) device-ID: 1002:73df
        display-ID: :0.0
      API: Vulkan v: 1.3.290 surfaces: xcb,xlib,wayland device: 0
        type: discrete-gpu driver: N/A device-ID: 1002:73df device: 1 type: cpu
        driver: N/A device-ID: 10005:0000
    
  7. WinterSnowfall commented on Oct 31, 2024

    @WinterSnowfall
    Contributor

    Both Painkiller games seem fine here on latest master.

    Painkiller: Black Edition

    PK

    Painkiller: Overdose

    Overdose

    I am on X11 however, so maybe it's an issue with Gamescope?

  8. waspennator commented on Oct 31, 2024

    @waspennator

    Both Painkiller games seem fine here on latest master.

    Painkiller: Black Edition
    PK

    Painkiller: Overdose
    Overdose

    I am on X11 however, so maybe it's an issue with Gamescope?

    I tried it out lately on deck desktop mode (which I believe uses X11) on proton Experimental and i still run into the issue, unless a newer version of dxvk fixed it and isn't in proton yet.
    Screenshot_20241031_081241

    Edit: Same result with bleeding-edge proton Experimental, game launches weirdly in a small window, if I use wined3d in desktop mode, it properly full screens and looks normal sized.

  9. DarkSwan86 commented on Nov 1, 2024

    @DarkSwan86

    @WinterSnowfall on Fedora 41 KDE Plasma (Wayland session - Mesa 24.2.5) with the latest release of Proton-GE 9.18 (today), the game loads on a small windows with only a quarter of the menu visible.
    Schermata_20241101_223024

  10. DarkSwan86 commented on Jan 21, 2025

    @DarkSwan86

    @WinterSnowfall No luck with KDE Plasma 6.2.5 (Wayland session), Mesa 24.3.3 and Proton-GE 9.23 (latest as the time of writing), still only a quarter of a windows is visible (as my latest reply).

  11. WinterSnowfall commented on Jan 21, 2025

    @WinterSnowfall
    Contributor

    I've been able to reproduce it in the meantime as well. It's a bug for sure, but a tough nut to crack at that.

  12. BinqAdams commented on May 5, 2025

    @BinqAdams

    Experiencing this issue on Windows 10, latest nvidia drivers. DXVK 2.6.1.

    Quite interested in investigating this as it affects the Painkiller RTX Remix project.

    We have some insight into the game functionality, if the dxvk folks would like additional information to assist with debugging, please do not hesitate to ask.

  13. Deus-nsf commented on May 5, 2025

    @Deus-nsf
    Author

    Ah good to know some people care, having DXVK work for this would allow Lillium's DXVK HDR mod to perform brightness and possibly channels remastering/upgrades, which would look amazing for such a vibrant game like Painkiller 2004 :)
    After that and FEAR 1, there will be no more DX9 outliers at least for me :D

  14. BinqAdams commented on May 6, 2025

    @BinqAdams

    The issue does not seem to occur with DXVK version 1.9.4

    I did not test any other versions, but it might be possible to narrow down the commit.

    for extra information, painkiller seems to hardcode 640x480 somewhere;

    info:  D3D9DeviceEx::ResetSwapChain:
    info:    Requested Presentation Parameters
    info:      - Width:              2560
    info:      - Height:             1440
    info:      - Format:             D3D9Format::A8R8G8B8
    info:      - Auto Depth Stencil: true
    info:                  ^ Format: D3D9Format::D24S8
    info:      - Windowed:           true
    info:      - Swap effect:        1
    info:  DXVK: Using 16 compiler threads
    info:  Device reset
    info:  D3D9DeviceEx::ResetSwapChain:
    info:    Requested Presentation Parameters
    info:      - Width:              1280
    info:      - Height:             720
    info:      - Format:             D3D9Format::A8R8G8B8
    info:      - Auto Depth Stencil: true
    info:                  ^ Format: D3D9Format::D24S8
    info:      - Windowed:           false
    info:      - Swap effect:        1
    info:  Setting display mode: 1280x720@0
    info:  Setting display mode: 1280x720@0
    info:  Presenter: Actual swapchain properties:
    info:    Format:       VK_FORMAT_B8G8R8A8_UNORM
    info:    Color space:  VK_COLOR_SPACE_SRGB_NONLINEAR_KHR
    info:    Present mode: VK_PRESENT_MODE_IMMEDIATE_KHR (dynamic: yes)
    
    
    
    info:    Buffer size:  640x480 <---------------------------------------------------------------------------------------------------------
    
    
    
    info:    Image count:  3
    info:  Device reset
    info:  D3D9DeviceEx::ResetSwapChain:
    info:    Requested Presentation Parameters
    info:      - Width:              1280
    info:      - Height:             720
    info:      - Format:             D3D9Format::A8R8G8B8
    info:      - Auto Depth Stencil: true
    info:                  ^ Format: D3D9Format::D24S8
    info:      - Windowed:           false
    info:      - Swap effect:        1
    warn:  Multiple fullscreen windows detected.
    

    This is with desktop resolution 2560x1440,
    game resolution options set to 1280x720.

  15. DarkSwan86 commented on May 15, 2025

    @DarkSwan86

    @WinterSnowfall I'm reporting some improvements here! Now the game launch not cut in half but it's VEEEERY tiny inside a black square in the middle of my screen. If i try to change the resolution from 640x480 to 1980x1080 it simply crashes.

    Proton-GE 10.1 + Mesa 25.0.4

  16. 5 remaining items

  17. Gobi-one commented on Nov 28, 2025

    @Gobi-one

    Well, I tried the fixes proposed here and played with versions but nothing works. I have a tiny game window inside a small black window. Any ideas?

  18. Blisto91 commented on Nov 28, 2025

    @Blisto91
    Collaborator

    No. Just need to be looked at by the devs at some point

    Edit: If dxvk doesn't but wined3d works then you'll have to use that for now

  19. Gobi-one commented on Nov 28, 2025

    @Gobi-one

    wine3d gives me a grey window, full screen; nothing is displayed but at least it launches (sound works) and it looks like the resolution might be correct -_-
    Thx anyway, I'll try again in a few months...

  20. DarkSwan86 commented on Nov 28, 2025

    @DarkSwan86

    I'm waiting for this MR to be released with the next KDE 6.5 plasma stable update (by their schedule, should be on Tue 2025-12-09) because it fixes a problem very similar to this (cc @WinterSnowfall, maybe it's this the needed fix?).

  21. WinterSnowfall commented on Nov 28, 2025

    @WinterSnowfall
    Contributor

    No. Just need to be looked at by the devs at some point

    Not much to look at, since this is a full-screen WSI issue. What I've done for it to work reliably is used
    d3d9-wrapper as a first link in the chain, and set ForceWindowedMode = 1 to get a poor man's borderless full-screen, which then always scales/displays properly with dxvk.

  22. DarkSwan86 commented on Dec 8, 2025

    @DarkSwan86

    ...aaaaaaaaanddd works again GE-Proton 10.26 ^^"

  23. rrPKrr commented on Dec 8, 2025

    @rrPKrr

    No. Just need to be looked at by the devs at some point

    Not much to look at, since this is a full-screen WSI issue. What I've done for it to work reliably is used d3d9-wrapper as a first link in the chain, and set ForceWindowedMode = 1 to get a poor man's borderless full-screen, which then always scales/displays properly with dxvk.

    Here is another possible workaround for that issue. It seems like calling SetWindowPos() after loading the game also fixes that problem.

    For example here is what I do:

    #include <Windows.h>

    int main() {
    HWND handle = nullptr;

    while (true) {
    if (GetAsyncKeyState(VK_MULTIPLY) & 0x8000) {
    do {
    handle = FindWindow(NULL, L"PainKiller");
    } while (handle == nullptr);
    SetWindowPos(handle, NULL, 0, 0, GetSystemMetrics(SM_CXSCREEN), GetSystemMetrics(SM_CYSCREEN), SWP_FRAMECHANGED);
    return 0;
    }
    Sleep(50);
    }
    return 0;
    }

    Just in case if somebody needs that...

  24. XDavidXtreme commented on Apr 17, 2026

    @XDavidXtreme

    This problem was solved about 1 year ago, if you install the 4GB RAM Patch and the Windowed Patch then the game opens normally: https://www.moddb.com/downloads/painkiller-4gb-patch.

    You do not need to play in Windowed, you just need to have those 2 patches installed.

  25. Gragt commented on May 26, 2026

    @Gragt

    This problem was solved about 1 year ago, if you install the 4GB RAM Patch and the Windowed Patch then the game opens normally: https://www.moddb.com/downloads/painkiller-4gb-patch.

    You do not need to play in Windowed, you just need to have those 2 patches installed.

    By Jove, you’re right! With your patch, no other fixes needed. Thank you so much for this!

  26. DarkSwan86 commented on Jun 29, 2026

    @DarkSwan86

    Sigh...broken again on wayland on Proton-GE 11-1, the tiny window on black background is back. This game is sure from hell :/

    Ticket on ProtonGE tracker: GloriousEggroll/proton-ge-custom#579

  27. GloriousEggroll commented on Jun 29, 2026

    @GloriousEggroll
    Contributor

    It happens without wine-wayland, I noted that already in GloriousEggroll/proton-ge-custom#579

  28. DarkSwan86 commented on Sep 17, 2026

    @DarkSwan86

    @WinterSnowfall @GloriousEggroll Confirmed fixed work with and without Wayland with Proton Wayland (on ProtonGE 11-7). The only downside is that you can't use the Unofficial Patch that fixes many problem with the game. I think maybe it's the DxWrapper cited on the patch note that interfere. If you apply the patch and launch the game it simply show a white square on the top left then close, both with and without Wayland. But now the original game is playable, thanks! :D

  29. waspennator commented on Sep 18, 2026

    @waspennator

    Works fine now on my oled steam deck out of the box. Thanks for fixing

  30. WinterSnowfall commented on Oct 20, 2026

    @WinterSnowfall
    Contributor

    @DarkSwan86 You might want to retry on latest master, since it turns out the fix was somewhat incomplete and actually caused crashing in a Wine test. Not sure if it's related to what you're seeing with the Unofficial Patch, but probably worth rechecking.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions