magcius / noclip.website

A digital museum of video game levels
https://noclip.website/
Other
3.27k stars 258 forks source link

Source Engine maps load a white screen on Chromebooks #512

Closed slambo311 closed 2 years ago

slambo311 commented 2 years ago

It acts like it's loading (the loading bar moves, the render hacks tab opens up, etc.), but it never actually loads any part of the map, just white. I've been mainly using just regular Chrome. Here's a picture of it, taken from Half-Life 2's background01: image In some games, like Portal 1, Portal 2, and Team Fortress 2, bloom makes the white screen a bit brighter, if it helps. My theory is that it only affects games that were made in later versions of the Source Engine, since Portal and TF2 both use a newer Source Engine. Half-Life 2 was literally the first Source Engine game, so bloom doesn't do crap. Half-Life 2: Deathmatch and Counter-Strike: Source were literally released the same month as Half-Life 2, so they're also unaffected.

Also, Half-Life 1 renders just fine, most of the time (c1a0 and t0a0 work fine, crossfire's a black screen, that's all I've really tested so far).

magcius commented 2 years ago

My main guess is that you're on a Chrome version before 99. Source Engine requires CORS w/ Range without preflight, which is a relatively new feature https://chromestatus.com/feature/5652396366626816

slambo311 commented 2 years ago

Yeah, I'm on 92. No clue why my Chromebook won't update it.

notfrying1pans commented 2 years ago

Firefox does this for me too

magcius commented 2 years ago

Yes, Firefox hasn't implemented CORS Range without Preflight yet -- there's an open bug here: https://bugzilla.mozilla.org/show_bug.cgi?id=1733981 . I'll see if I can get the server reconfigured to support preflight requests.

magcius commented 2 years ago

The backend file server has been reconfigured. This should be fixed in both older Chrome and Firefox now.

slambo311 commented 2 years ago

Alright, it's working pretty well now, other than the lighting. image

magcius commented 2 years ago

Weird -- it looks like the lightmaps aren't properly being updated? I would guess that's a GPU / driver bug, but I don't know enough to be sure. Do you know what GPU the hardware is using?

slambo311 commented 2 years ago

My Chromebook doesn't let me check the GPU for some reason, but here's my CPU: Intel(R) Celeron(R) CPU N3060 @ 1.60GHz (2 threads, 2.48GHz).

slambo311 commented 2 years ago

image Apparently, a lot of Portal 2 works fine. Certain parts are still dark, such as sp_a1_intro1's test subject storage cart thing, but other than that, it works pretty well. Might be because Portal 2 uses a different style of lighting than the earlier Source Engine games, more resembling Source 2's lighting.

slambo311 commented 2 years ago

Also, the map I screenshotted here, sp_a2_fizzler_intro, has the lights flicker for a few seconds, so that might be another reason. Plus, those lights might use light_dynamic or env_flashlight entities, instead of light, light_spot, or light_environment.

slambo311 commented 2 years ago

Just realized, the lightmap updating probably isn't the reason, since the flickering trigger works just fine in sp_a2_fizzler_intro.

magcius commented 2 years ago

Portal 2 uses dynamic lights (env_projectedtexture) instead of lightmaps for those lights. I believe the lightmaps are broken -- I'm using kind of an esoteric setup for them (NPOT, UN16, texture array) so I'm not surprised some drivers break.

Can you go to https://webglreport.com/?v=2 and tell me what the Renderer and Unmasked Renderer strings say, and whether you see EXT_texture_norm16 in the Supported Extensions list?

slambo311 commented 2 years ago

Renderer: WebKit WebGL Unmasked Renderer: Mesa DRI Intel(R) HD Graphics 400 (BSW) And yeah, EXT_texture_norm16 is there.

slambo311 commented 2 years ago

Just realized, you should probably reopen this.

magcius commented 2 years ago

The lighting issue is separate; the maps aren't loading as a white screen anymore.

slambo311 commented 2 years ago

Fair point.