Menu

Battlefield 1942 windowed mode with DxWnd messes up resolution.

Skull Kid
2019-01-28
2019-01-30
1 2 > >> (Page 1 of 2)
  • Skull Kid

    Skull Kid - 2019-01-28

    Hello.

    I may be new here, but I have been using DxWnd for quite some time and I have enjoyed using it very much. I have recently run into a problem when I set the in-game resolution to 1280x960x32 @ 60hz

    When opening one of the game's config files and change the game to it's official windowed mode, it looks really bad in-game when emulating windowed mode with DxWnd. I do not experience this however when running the game in fullscreen but emulating it as a window with DxWnd.

    The problem is I need to get the debugger of Battlefield 1942 to run in windowed mode, as that is the only way to bypass the error messages when loading a level.

    So I am pretty much stuck att 800x600 when trying to run the game in DxWnd with windowed mode enabled in the game's config file. Why, I don't know.

    Any help is greatly appreciated!

    Kind Regards,

    Skull Kid

     

    Last edit: Skull Kid 2019-01-28
  • gho

    gho - 2019-01-28

    Weird. I was about to suggest that 1280x960x32 is not a DxWnd supported resolution, but that's not true, it is!
    It is possible, though, that DxWnd shows emulated characteristics different from the real ones. You may go in the Video tab and set the "Screen resolution" selector from "SVGA" to "Native".
    I'm not sure it may fix, but honestly I can't think anything else right now ...

     
    • Skull Kid

      Skull Kid - 2019-01-28

      That's odd. When I check the other options, like SVGA, I get this:

      EDIT: I'm sorry, I misread you you wrote. I can use "Native". It's the other's I cannot use.

       

      Last edit: Skull Kid 2019-01-28
  • Skull Kid

    Skull Kid - 2019-01-28

    I reinstalled the graphics driver, and now "SVGA" and all the other modes works now except HDMI. But the issue is still there.

    I don't want to ask too much from you gho, but if you want to, you could always install Battlefield 1942, and also get the debugger and see what the problem with the resolution could be.

    Kind regards,

    Skull Kid

     

    Last edit: Skull Kid 2019-01-28
    • gho

      gho - 2019-01-28

      Uhm, I will. It's about 900MB of abandonware game, it shouldn't take too long. Let's hope the problem doesn't depend on a specific video card.

       
      • Skull Kid

        Skull Kid - 2019-01-28

        Thanks for giving it a shot. I know the game has built-in windowed mode, with some config file tweaking.

        You need to go into the "VideoDefault.con" file and change the line "renderer.setFullscreen" from 1 to 0. Then the game will run in it's windowed mode.

        This is a must for the debugger. Otherwise once it finds a possible bug in a level, it'll close itself. When running the game in windowed mode, and turning of "Run in window" in DxWnd, it looks alright.

        But when I enable "Run in window" again, it messes up the resolution, as I said earlier. It is 1280x960 alright, but it looks extremely pixelated.

        EDIT: I tried on my second computer, a laptop, and same thing happens. Pixelation.

        Regards,

        Skull Kid

         

        Last edit: Skull Kid 2019-01-28
  • Skull Kid

    Skull Kid - 2019-01-29

    When selecting the "Desktop center", and the 800x600 resolution in window size and position, it does look ok. But I would want 800x600 inside of a 1280x960 window frame.

    The thing is that the main menu of Battlefield 1942 is always in 800x600, no matter what. The gameplay can be higher, but I basically need the main menu to be 800x600, then make the window scale up to 1280x960.

     
  • gho

    gho - 2019-01-29

    Sorry for the delay, I finally got the game up & running and your problem is replicated here.
    This is good because this way I can work on the problem also alone, without asking questions and waiting for your answers.
    Stay tuned.

     
    • Skull Kid

      Skull Kid - 2019-01-29

      No problem Ghotik! :)

       
  • gho

    gho - 2019-01-30

    Maybe I found something.
    I tried several time to modify the game resolution and run a mission, always with the badly scaled font problem, but I didn't get the impression that the game ware really listening to me when asking a higher resolution. Maybe DxWnd somehow interferes with the resolution change?
    So I tried to define a custom game profile that I named "1920x1080" chosing this resolution and then I run a quick mission with this profile.
    The result appeared much better (see the screenshot). Have you tried to do the same?

    P.s. revert the game configuration to fullscreen mode and DxWnd defaults, then pick "Hide background", "Keep aspect ratio" and "Desktop work area" for optimal rendering.

     

    Last edit: gho 2019-01-30
    • Skull Kid

      Skull Kid - 2019-01-30

      Good morning Ghotik!

      I have set, under the "Main" tab, 1920x1080. Although I want the game window in "Desktop work area" and also "Anchored", will your possible fix still work then?

      Best regards,

      Skull Kid

      EDIT: I see, well the debug version would need windowed mode. That's the problem for me. Native fullscreen works fine with the rendering, but the windowed mode is necessary for the debug messages to show up during loading a level and gameplay, so that they can be ignored. Try using this .exe instead.

      EDIT2: I understand if I was a bit unclear, I apologise for that. This issue was kind of annoying to say the least, with the resolution. It's like the game won't run in full resolution, even if 1280x960 is selected...

       

      Last edit: Skull Kid 2019-01-30
  • gho

    gho - 2019-01-30

    I'm not sure I got your problem. Anyway ...

    • your exe complains for a missing dll mod_r.dll
    • if you set fake fullscreen modes (desktop and Desktop work area) the coordinates and sizes fields are ignored
    • if you want DxWnd to manage a windowed program, you hve to pretend it is fullscreen. You can do this in two ways: checking "Fullscreen only" of setting "Video / Initial resolution" to small values.

    does this help?

     
    • Skull Kid

      Skull Kid - 2019-01-30

      I forgot to attach this. My bad. But I will try what you said right away.

       
      • gho

        gho - 2019-01-30

        Running it with default DxWnd configuration and custom profile, ok (see screenshot), there's a debug io assertion at startup but you can ignore it and the game works.
        Picking my "1920x1080" probile the game istantly crashes, though I can see to faulty operations on the DxWnd log (probably something unhooked failed).

         
        • Skull Kid

          Skull Kid - 2019-01-30

          Quick question: Did you have "renderer.setFullscreen" to 0 or 1 when you bypassed the debug assertion?

          EDIT: It needs to be set to 0 for the debugger to function properly. Although as you said, the logs might have created something.

          I'm quite exhausted to say the least, but I thank you for your patience. This was a rather lengthy and exhaustive troubleshooting process if you ask me.

          If you are willing to continue the troubleshooting, I'm ok with it though.

           

          Last edit: Skull Kid 2019-01-30
          • gho

            gho - 2019-01-30

            I don't know what time is it there, but I got the impression you may need some good sleep.
            Take it easy, no hurry. See you later.

             
            • Skull Kid

              Skull Kid - 2019-01-30

              I live in Sweden. I suppose the time is the same as yours, if you live in Italy. I just need a little break. If you feel you got the time, then please don't let me discourage you.

              Good luck and take care, and as you said, see you later :)

               
  • gho

    gho - 2019-01-30

    Just one note: setting renderer.setFullScreen to 0 the game works with 1920x1080 profile (there's a second assertion about loading text, but you can ignore that one as well) but you may get a reduced battlefield screen (see screenshot). You can recover the battlescreen by setting the "Direct3D / Suppress Direct3D8/9 reset" flag, though this way you'll get some scaled splash screen.

     
    • Skull Kid

      Skull Kid - 2019-01-30

      I see. Do you meant 1920x1080 in-game, or in DxWnd's settings?

      EDIT: I'm getting this strange "bug" when setting the "Suppress D3D8/9 reset".

       

      Last edit: Skull Kid 2019-01-30
      • gho

        gho - 2019-01-30

        I mean 1920x1080, the DxWnd setting for the screenshot was 800x600.
        Oh,my! A flying tree!! Ok, suppressing the Reset is not always a good idea.

         
        • Skull Kid

          Skull Kid - 2019-01-30

          Actually, I think it was quite a good idea. Except I'm not running an HD version of the game, but the vanilla game. Which only supports 4:3 resolutions.

           
  • gho

    gho - 2019-01-30

    So, is there anything more I could do for you?

     
    • Skull Kid

      Skull Kid - 2019-01-30

      I'm not sure. Maybe try playing the game in 1280x960. I would want it to look like I'm playing fullscreen in 1280x960, and also get a nice scaling, wit the bf1942_r.exe.

      EDIT: Hmm... very strange indeed! Now I can play in windowed mode, with good pixel scaling in 1280x960! Why not before? What on earth did I change? No idea whatsoever... nevermind, it seems to be working now!

      EDIT2: Now it bugs again... the entire interface seems to move sideways from time to time... I wish it only stayed the same all the time... damn it... back on square one.

      EDIT3: Could it be that I've turned on FXAA in the Nvidia Control Panel that does this? If so, maybe DxWnd has a similar option?

      EDIT4: Nope, not that either.

       

      Last edit: Skull Kid 2019-01-30
  • Skull Kid

    Skull Kid - 2019-01-30

    In the first image (1280x960) I got "renderer.setFullscreen" to 1.

    In the second image (also 1280x960) I got "renderer.setFullscreen" to 0.

    What causes this, I have no idea. Although what you suggested with "Suppress D3D8/9 reset" worked for a little while, it sent everything in-game "sideways" somehow...

     

    Last edit: Skull Kid 2019-01-30
    • gho

      gho - 2019-01-30

      Uhm, I don't know either, I just can say that sideway effect is not to unexpected: the DirectD3DDevice::Reset method is usually used to change screen resolution to the same Direct3DDevice object, so if you suppress that call the game (or part of it ...) believe the resolution is different from the real one, so either the rendered area is smaller that the window (my first screenshot) or bigger (so part of the rendered area is cut out from the window visible area).
      In any case there's nothing in the log that make you think you're handling small textures like font's characters, so DxWnd is not at all aware or directly responsible of what's going on.
      Hopefully, if we can find some discussion about a similar effect and a possible fix, then I'll have a chance to implement it in DxWnd.

       
1 2 > >> (Page 1 of 2)

Log in to post a comment.

MongoDB Logo MongoDB