Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsDiscussion Forum → Anything games
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
Anything games
2019-03-11, 1:55 PM #921
Jesus christ. The transparencies. The actual mipmaps. I can't believe what I'm seeing.


So, tested JKGR with the interceptor in Linux, running through Wine. JK2018 (QM's patch) wouldn't start at all when running through the interceptor. As FGR said, JK2013 ran smoothly but without the alpha blending stuff (which makes most effects in JKGR quite ugly, but still). Framerate was A LOT smoother than if I was running normal JK, especially considering it was in 32 bit mode. Seeing things rendering correctly behind transparent surfaces for the first time in JK was... delightful.


I know this is nowhere near a priority but if you could make JK2013 alpha blending work while materials aren't around yet you'd make me a happy man
JKGR
2019-03-11, 1:57 PM #922
I tried it out under linux/wine (wine 3.0/ubuntu). It started a completely blank/black screen and then appeared to freeze. When I was able to force-quite it it left an error message in the terminal:

Quote:
brian@oree:~/.wine/drive_c/JK$ wine inject.exe
wine: Unhandled page fault on read access to 0x00000000 at address (nil) (thread 002f), starting debugger...
^[


The debugger it referred to must be some windows thing but it never started. It tried popping up a "send error report to microsoft" thing but the content of said error report was blank.

Is the goal of this so you can get those updated textures in-game?
2019-03-11, 2:01 PM #923
I tried again without changing the resolution (left it at 1024x768) and it had same symptoms, but output some more information when it exited. Attached.
Attachment: 28302/dump.txt (3,630 bytes)
2019-03-11, 2:04 PM #924


OOOOHHH YEAAAHH
JKGR
2019-03-11, 2:12 PM #925
I realized I was using the patched version (jk unofficial patch from jkhub) so I restored the cd version and tried again; same symptom, similar but not exactly the same dump, but posting it here in case you care to take a look at it.
Attachment: 28304/backtrace.txt (3,390 bytes)
2019-03-11, 2:16 PM #926
Apparently the issue isn't with QM's JK2018 but rather with "-windowgui", which jk2018 enables by default. JK2018 must be run with "-fullscreen"

Brian, try registering "renderer.dll" as a native library in winecfg. When I tried running without doing this the game crashed as soon as I started a level.
[edit] Nevermind, said crash was being caused by JK2018. The game (with JK2013 patch applied) appeared to run perfectly regardless of whether the DLL was registered or not.

Do you have ddraw.dll as a registered library? If so, try removing that.
JKGR
2019-03-11, 2:48 PM #927
I got it to work; I had to switch to the nvidia discrete graphics card & drivers instead of the built-in intel stuff. The problem with those drivers (discussed previously in this thread or another) is that I get weird glitches where the game skips for a second or two every minute or so. It also seems to be clamped at a maximum of 30fps whereas the intel card runs at a steady 60fps. So weird. But anyway it's working. I'm going to try to futz with things and see if I can figure out why the nvidia card sucks so much.
2019-03-11, 3:11 PM #928
Which means detours works in wine. Holy ****.


@brian can you follow the issue reporting section in the readme, enable logging, and let me know if it logs any error messages from compiling the shaders? GLSL is finicky.
2019-03-11, 3:28 PM #929

Apparently the rendering order for surfaces with transparent mats is terribly inconsistent. Still, they're all being rendered, which is great to see.
JKGR
2019-03-11, 3:53 PM #930
Originally posted by Brian:
Is the goal of this so you can get those updated textures in-game?
yes, plus some low hanging fruit

Originally posted by SMLiberator:

Apparently the rendering order for surfaces with transparent mats is terribly inconsistent. Still, they're all being rendered, which is great to see.
I can’t tell what’s going on here. Can you post an example with better lighting? Is the body of the car all transparent mats too?
2019-03-11, 3:54 PM #931
The transparent surface sorting is a pretty clumsy heuristic, so it’s not surprising if it fails under extreme situations. I can do better. Not perfectly (that’s an np hard optimization problem). But I’d like to know more about how it’s failing before I do that.
2019-03-11, 4:07 PM #932
I tried to take a screenshot of the regular vs new on wine/linux but the new one always comes out totally purple.

I spent some time trying to figure out why my nvidia graphics are skipping and why I can't go over 30fps. I updated the drivers to the latest 418.xx. The stock ubuntu ones are 390.xx. This let me go over 30fps (now in the 80s) with the stock JK, and I don't think it's skipping anymore. However, when I use the new inject.exe it still seems capped at 30 fps, or maybe it's just my computer that can't render fast enough? It seems pretty steady at 29.x fps, even if I'm just looking at a wall. I used nvidia-settings to set everything to max performance, turned vsync off, etc.

Jon`C are you asking me to try to gather error info from the intel card when it crashes, or error info that might be happening when it's running with the nvidia card?
2019-03-11, 4:19 PM #933
Originally posted by Jon`C:
Is the body of the car all transparent mats too?


exactly.

On this one, all cars, guard rails and the player model's hair use transparent mats. The car's license plate however does not.


Originally posted by Brian:
I tried to take a screenshot of the regular vs new on wine/linux but the new one always comes out totally purple.

Try using Ubuntu's print screen instead of JK's.
JKGR
2019-03-11, 4:36 PM #934
Here's the log from a session with the nvidia card w/updated drivers. Still seemingly clamped at 30fps. No errors/issues though. I'll try to get one with the intel drivers crashing tomorrow.
Attachment: 28307/jkgm.txt (4,338 bytes)
2019-03-11, 5:37 PM #935
Originally posted by Brian:
Jon`C are you asking me to try to gather error info from the intel card when it crashes, or error info that might be happening when it's running with the nvidia card?
Intel please. I think it’s failing to compile the shaders.

Originally posted by SMLiberator:
exactly.

On this one, all cars, guard rails and the player model's hair use transparent mats. The car's license plate however does not.
Are you willing to make me a simple reproducer? It would be a lot of help. I think there’s something more JK specific edge case going on there.

Quote:
Try using Ubuntu's print screen instead of JK's.
yeah, in-game screenshot functionality won’t work. I’m intentionally blocking JK from reading the framebuffer back off the GPU because if it can, it does it every frame. Bleh. You’ll need to use some other capture method.

Originally posted by Brian:
Here's the log from a session with the nvidia card w/updated drivers. Still seemingly clamped at 30fps. No errors/issues though. I'll try to get one with the intel drivers crashing tomorrow.
thanks!
2019-03-11, 5:56 PM #936
Originally posted by Jon`C:
Are you willing to make me a simple reproducer? It would be a lot of help. I think there’s something more JK specific edge case going on there.


Here. Literally just load any level, select fists, punch the air and there you go.
JKGR
2019-03-11, 7:07 PM #937
Sorry to distract from Jon'C's awesome work, but I stumbled across this a bit ago.

https://drakelings.bluedrake42.com/index.php?/files/file/15-star-wars-dark-forces-remastered/

My blawgh.
2019-03-11, 7:33 PM #938
dude spends most of his day scourging the internet
2019-03-11, 8:02 PM #939
Weird. The download is gigantic, like the Unreal Mos Eisley level, and it is called ME_Level.zip, like the Unreal Mos Eisley level.
"I would rather claim to be an uneducated man than be mal-educated and claim to be otherwise." - Wookie 03:16

2019-03-11, 8:08 PM #940
Nevermind, watching the video that's exactly what he's showing while "pretending" it's the DF Remake.
"I would rather claim to be an uneducated man than be mal-educated and claim to be otherwise." - Wookie 03:16

2019-03-11, 8:38 PM #941
how about this one
JKGR
2019-03-11, 10:30 PM #942
I was thinking about a cyberpunk setting for a JK level, and thought about what's the most 80's evil megacorp thing I can think of. And I decided that having an automated voice speak propaganda over the speakers would be pretty cyberpunk, so I made a few possible lines for what it might sound like:

https://www.dropbox.com/s/zqea8kondqs5ksx/unions-2.wav?dl=0

https://www.dropbox.com/s/dnpa6uaagbmx5j3/owaku-2.wav?dl=0

https://www.dropbox.com/s/39lnb2tq30qs86e/contractor-2.wav?dl=0

Also it's probably too layered to work as soundtrack, but to fit the theme of cyberpunk nothing works but 80's synth sounds, so:

https://www.dropbox.com/s/2fzr7vygiq6a18k/nice.mp3?dl=0

This is a rough idea of the kind of music which would fit.

I know I'm not actually going to do this but the thought is great.
2019-03-11, 10:31 PM #943
Originally posted by SMLiberator:
how about this one


Get out of my bar, you always cause trouble.
2019-03-11, 10:34 PM #944
Originally posted by Reid:
Get out of my bar, you always cause trouble.


https://www.youtube.com/watch?v=D2B6InK5PKY#t=4m19s
Star Wars: TODOA | DXN - Deus Ex: Nihilum
2019-03-11, 10:35 PM #945
Originally posted by SMLiberator:
Here. Literally just load any level, select fists, punch the air and there you go.


The main problem is the fact that the car models are all inside out. Apparently JK disables backface culling. I've fixed that.

The second problem is the overall complexity of the models. I'm going to see what I can do. As a general comment, it's best to avoid making models [mostly out of transparent textures].

edit: I think what I’m gonna do is this. Some kind of simple depth peeling or other OIT technique, since that’s the only way to get this right and there’s more than enough GPU power in a modern computer to throw at it. Then for the materials, I’m going to add an alpha test mode. The idea being hopefully models like this one can in the future just use alpha testing and skip all of this transparency order nonsense.

Alpha testing creates hard edges, instead of blurry edges. They also work with z-buffering. Basically alpha blending is something to avoid unless you specifically need it for something.
2019-03-11, 10:46 PM #946
Originally posted by Jon`C:
The second problem is the overall complexity of the models. I'm going to see what I can do. As a general comment, it's best to avoid making models this way.


I did quickly test the original version of TODOA 2 yesterday and indeed some areas started looking like they did in the T-O: DOA 2 glitch video (https://www.dropbox.com/s/osqdqq9j2caghup/rubenpot.mp4?dl=0). No idea if it was because of the 1024x1024/2048x2048 textures or the 3DO skybox in the original version, but I'd reckon stuff like that will probably occur in other hi-def JK mods.

More bugportantly, TODOA 2 Enhanced Edition also crashed to desktop after the jkEndLevel; of the very last level.
Star Wars: TODOA | DXN - Deus Ex: Nihilum
2019-03-11, 10:55 PM #947


Nice
2019-03-12, 3:24 AM #948
While trying to get the Steam-version of the game to run with Jon's injector (hint: didn't work, more later) I stumbled upon Jedi Knight and MotS on archive.org:
https://archive.org/details/StarWars-JediKnight-CD
https://archive.org/details/StarWarsJediKnightMysteriesOfTheSith
Sorry for the lousy German
2019-03-12, 6:38 AM #949
So, with the Steam-version of Jedi Knight I couldn't get the injector running. At least not under Ubuntu 18.04 with wine and an nVidia card.

Wine output:
Code:
$ JKGM_LOG_FILE=jkgm.log wine inject.exe 
000b:fixme:winediag:start_process Wine Staging 4.0-rc2 is a testing version containing experimental patches.
000b:fixme:winediag:start_process Please mention your exact version when filing bug reports on winehq.org.
000b:fixme:ntdll:EtwRegisterTraceGuidsA (0x6307379f, 0x630b1cf8, {0cfe0455-93ba-440d-a3fe-553973d0b723}, 1, 0x34eaa8, (null), (null), 0x630b1d00): stub
000b:fixme:ntdll:EtwRegisterTraceGuidsA (0x6307379f, 0x630b1d18, {797fabac-7b58-4796-b924-d51178a59ce4}, 1, 0x34eaa8, (null), (null), 0x630b1d20): stub
000b:fixme:ntdll:EtwEventRegister ({43d1a55c-76d6-4f7e-995c-64c711e5cafe}, 0x6309ce28, (nil), 0x630b1500) stub.
000b:fixme:ntdll:EtwEventRegister ({9e3b3947-ca5d-4614-91a2-7b624e0e7244}, 0x63073c41, 0x630b3258, 0x630b3180) stub.
000b:fixme:ntdll:EtwEventEnabled (deadbeef, 0x6302b3c0): stub
000b:fixme:ntdll:EtwEventEnabled (deadbeef, 0x63020688): stub
000b:fixme:ntdll:EtwEventUnregister (deadbeef) stub.
0009:fixme:ntdll:EtwEventRegister ({5eec90ab-c022-44b2-a5dd-fd716a222a15}, 0x3427f0, 0x350030, 0x350048) stub.
0009:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x342560, 43) stub
0009:fixme:msvcrt:_configure_wide_argv (1) stub
0009:fixme:msvcrt:_initialize_wide_environment stub
0009:fixme:ver:GetCurrentPackageId (0x33faa4 (nil)): stub
002a:fixme:ntdll:EtwEventRegister ({5eec90ab-c022-44b2-a5dd-fd716a222a15}, 0x3c27f0, 0x3d0030, 0x3d0048) stub.
002a:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x3c2560, 43) stub
002a:fixme:ver:GetCurrentPackageId (0x33e6f0 (nil)): stub
0009:fixme:ntdll:EtwEventUnregister (deadbeef) stub.


The Steam-version lacks a jk.exe so I set "JediKnight.EXE" as the command in jkgm.json. It seemed to be the equivalent.

I guess it's due to Steam's copyprotection. When I renamed the JediKnight.EXE to JediKnight.orig.EXE and inject.exe to JediKnight.EXE I could run it through Steam (couldn't get proton to work on the command line). But Steam forces the windowGUI command line argument and it messes up the menus and videos by displaying them in what I guess is the original resolution in the upper left corner and showing them below that in fullscreen. But it does so as well without inject.exe where it doesn't even show the full menu in fullscreen.


But, when I used the original jk.exe from the CD I got it running perfectly with wine. Only when I tried to run it windowed did I get the weird double-menus like in the screenshot above.
Attachment: 28308/jkgm.notworking.steam.log.txt (197 bytes)
Sorry for the lousy German
2019-03-12, 6:44 AM #950
Ever since the JK version of Steam was released 10 years ago, I've never seen a reason to run it as such "off the box". Regardless of the unofficial patch used (I, of course, will "always" recommend JK13 over the others), you've always needed the original JK exe (retrievable via JKVersions) in some form or the other - and these days dgvoodoo is pretty much required as well.

Then again, supposedly nowadays Steam's version of JK is supplied with dgvoodoo? No idea. But it still doesn't seem to work "off the box" even with that, so my methods with dgvoodoo still seem to work pretty well (I'm only aware of a few stray cases of it not working).

Anyhow, with the interceptor dgvoodoo doesn't appear to be needed but the interceptor works pretty well with JK2013+dgvoodoo - aside from the additive blending stuff.
Star Wars: TODOA | DXN - Deus Ex: Nihilum
2019-03-12, 7:34 AM #951
Removed the videos, here's a general example of the graphical glitches one might get with the interceptor:

[Unable to find specified attachment]

The thing is that right after taking that screenshot (with FRAPS, since JK's own screenshot method only results in a blank pink file and IrfanView only shows a grey screen with the cursor in the middle)... that glitch disappeared. I tried to recreate it, managed it, but instead of having killed the stormtroopers in the area with a blaster rifle like the first time, launching a rail det at them resulted in the glitch getting fixed. Interesting.

More glitching:

[Unable to find specified attachment]
Star Wars: TODOA | DXN - Deus Ex: Nihilum
2019-03-12, 8:30 AM #952
Originally posted by Jon`C:
The main problem is the fact that the car models are all inside out. Apparently JK disables backface culling. I've fixed that.


If by inside out you mean like the outer layer on glowsabers, then no they're not. Now that I think about it, some (or most) faces are certainly (and incorrectly) marked as two sided.

Originally posted by Jon`C:
The second problem is the overall complexity of the models. I'm going to see what I can do. As a general comment, it's best to avoid making models [mostly out of transparent textures].


From what I've seen the same problem happens with general level surfaces too, so it's not just models. I haven't tried it yet, but I assume putting several transparent grates in front of each other will look just as screwy (and again, I haven't tried it but considering it's JK I assume the same probably also happens to general translucent surfaces, but it's much less noticeable)

Originally posted by Jon`C:
Alpha testing creates hard edges, instead of blurry edges. They also work with z-buffering. Basically alpha blending is something to avoid unless you specifically need it for something.


This might be interesting. Grates and the such will certainly look better.
JKGR
2019-03-12, 8:39 AM #953
Just tested the interceptor on an Ubuntu machine running with Intel graphics, had the same problem as Brian was having where JK wouldn't start at all.

Originally posted by Nikumubeki:
glitch etc


That actually looks mild compared to some stuff I got. I have no way of recording it at the moment but on my WWII level, depending on how crowded was the view, I'd sometimes see some surfaces randomly turning red or black, plus some black patches/squares and even some glowing blue/yellow dots flashing across the screen. This only happened on very extreme scenarios however that I don't think any other JK level gets close to. On the other hand, even on said extreme scenarios, FPS was miles ahead of that which I'd get on base JK.

Which reminds me, it appears that you'll experience some pretty bad input lag if your FPS drops too much with the interceptor.
JKGR
2019-03-12, 9:54 AM #954
I like how some glitchy areas can get unglitched all of a sudden.

I also realized that with the injector, the original clunky GlowSaberX from the original TODOA actually looks better (though not as good as the TODOA TC sabers):

https://media.moddb.com/images/mods/1/14/13826/T2.jpg

[Unable to find specified attachment]

Some more opaque textures set as transparent ones are really opaque with the injector.
Star Wars: TODOA | DXN - Deus Ex: Nihilum
2019-03-12, 12:39 PM #955
I did some research on order-independent transparency techniques. From what I could find, they seem to handle mostly-opaque faces poorly. That includes stuff like, er..., grates and exploded walls. So that makes them somewhat unsuitable for JK.

I ended up going with the following approach. The triangles are sorted back-to-front using a simple heuristic. First partitioned using axis-aligned depth planes, then partitioned using an arbitrary triangle plane, then partitioned by whether they're overlapping or overlapped by a triangle.

The worst case for this is O(n2logn) so I can't promise it will work well in all extreme scenarios, but I'm not sure what those are realistically. It works fine for everything in the base game.

This sorting algorithm gets ~80% of the way, but it still has some distracting artifacts for faces that are close together/overlapping or at sharp angles to the viewer. In order to mitigate those artifacts, I've paired the alpha blended pass with an alpha tested pass that has depth enabled. This is the result:



Artifacts are now relatively minimal. Occasionally the blurred fringe around sprites or grates can get skipped, leaving a hard edge. This seems quite rare in testing, and isn't too noticeable when it does happen.

I'm probably going to make everything alpha tested in the neural upscale texture pack, unless it looks goofy.
2019-03-12, 12:41 PM #956
By the way, as someone who doesn't really follow JK modding, it's very cool that you were able to get cars to work so well in the game.

The best driving mod available when I was still involved in modding was YARM, and all that did was change the player model to a swoop and made you run through levels without floor flags.
2019-03-12, 12:50 PM #957
Originally posted by Impi:
But Steam forces the windowGUI command line argument and it messes up the menus and videos by displaying them in what I guess is the original resolution in the upper left corner and showing them below that in fullscreen. But it does so as well without inject.exe where it doesn't even show the full menu in fullscreen.


But, when I used the original jk.exe from the CD I got it running perfectly with wine. Only when I tried to run it windowed did I get the weird double-menus like in the screenshot above.


The double-menus happen because JK draws the cutscenes and UI using CreateDIBSection. I didn't want to poke the bear and return a totally fake DIB, so right now I'm letting it draw. You'll get occasional flickering on Windows, but it's not as noticeable.

This can probably be fixed.


Re: the steam launcher. One option is to strip the -windowgui command line option if fullscreen mode is set in the config file. Does that sound reasonable?
2019-03-12, 2:00 PM #958
Originally posted by SMLiberator:
how about this one


God damn it
2019-03-12, 2:27 PM #959
Yours looks better ;)
2019-03-12, 2:28 PM #960
Originally posted by Jon`C:
By the way, as someone who doesn't really follow JK modding, it's very cool that you were able to get cars to work so well in the game.

The best driving mod available when I was still involved in modding was YARM, and all that did was change the player model to a swoop and made you run through levels without floor flags.


Ah yes, I remember downloading this and then getting frustrated for how it didn't make JK play exactly like Need for Speed. Sadly my cars probably won't work in MP as the physics code is... quite complex.


By the way, I got pictures of the very odd glitches (with orbs and the such) I mentioned. I like how the orbs almost look perfectly glowy.

Again, as I mentioned these are pretty extreme scenarios, for as you can see there's A LOT of triangles on the screen (count four for each raindrop), many of which are transparent/translucent. The oddest of the three is probably the middle one, as an unexplainable "X" appeared in the distance for that single frame. Also, the HUD opacity appears to change between each picture.
JKGR
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748

↑ Up to the top!