Install Steam
login
|
language
简体中文 (Simplified Chinese)
繁體中文 (Traditional Chinese)
日本語 (Japanese)
한국어 (Korean)
ไทย (Thai)
Български (Bulgarian)
Čeština (Czech)
Dansk (Danish)
Deutsch (German)
Español - España (Spanish - Spain)
Español - Latinoamérica (Spanish - Latin America)
Ελληνικά (Greek)
Français (French)
Italiano (Italian)
Bahasa Indonesia (Indonesian)
Magyar (Hungarian)
Nederlands (Dutch)
Norsk (Norwegian)
Polski (Polish)
Português (Portuguese - Portugal)
Português - Brasil (Portuguese - Brazil)
Română (Romanian)
Русский (Russian)
Suomi (Finnish)
Svenska (Swedish)
Türkçe (Turkish)
Tiếng Việt (Vietnamese)
Українська (Ukrainian)
Report a translation problem
It's a bit tricky to use though, the tools don't show the actual lightmap scale anywhere, and I think some of the entities used to contol them are still missing. Also it won't bake them onto dev textures.
From the looks of it, lightmap scales work a bit differently from Source 1. The compile options control the overall lightmap resolution for the entire map, and the per-face lightmap resolution bias acts as a multiplier for that resolution.
Some other observations:
- It doesn't seem to be possible to view the lightmaps in Hammer, but maybe I'm overlooking something.
- VRAD seems to run on the CPU only, no GPU acceleration. Better rev up those Threadrippers.
- VRAD expects a lightmap_resolution_volume that doesn't exist in the FGD yet. I wonder if it has a similar effect as the lightmap resolution bias, and/or if it's meant to restrict pieces of geometry to a single lightmap.
Some of my notes:
VRAD compiles directional lightmaps, everything gets saved into two texture atlases. One with a normal color value and one with a normal vector in RGB and what looks like an AO map in the alpha channel. It looks a lot like how Unitys directional lightmaps are setup. I'm not sure if that alpha channel is for an actual AO or a directionality factor (it could be the normal vector length).
The directional lightmaps seem to be broken and don't take normal maps in account, and the input normal texture VRAD uses seems to be broken with artifacting.
There are new shader settings for controlling directional lightmaps, but they have very little effect without the normal maps working.
Apart from lightmap_resolution_volume, there is an auto vis group called Lightmap Space. It's populated in the HL:A Hammer screenshot. I'm guessing it's something that lets you set volumes for separate lightmap atlases.
Baking cubemaps from the ligthmapped environment is broken. The only way to get them working currently is to bake the vertex lighting and then compile the map wihout lightmaps. Then compile the map with lightmaps.
That causes the area inside the mesh to have a high resolution, and causes the resolution to slowly decrease as you get further from the enclosed area.
Thanks. That actaully sounds like a neat way of quickly setting resolutions.
One more issue that I remember. Some of the shader features don't seem to work together with the lightmapping. Having the Morph Enabled material option set will make it not bake lightmaps on that material, and having a blend material on a prop (works properly with meshes) will make it only show the first texture layer in-game when lightmaps are baked.
The morph thing is maybe not an issue in itself, but it makes troubleshooting harder. The blend issue would break the pine trees on my island map though.
The lightmapper takes a ton of resources, so make sure you have at least 32 GB of RAM. Does it print any error messages in the compile log?
The compile error is this part:
Bake Lighting
Build: pc64 Jun 12 2020 17:43:59
Light Importance Tree... [0....1....2....3....4....5....6....7....8....9....] Done (7.71 seconds)
WARNING! No lightmap resolution volumes set for this geometry!
Whilst we still can process lightmaps for this map, texel resolution of the lightmap will be sub-optimal.
Please add a mesh enclosing the player navigable space with toolslightmapres.vmat applied to it.
Preprocessing 151 meshes and computing charts [0....1....2....3....4....5....6....7....8....9....] Done (1.66 seconds)
Packing 38815 UV charts onto atlas...
Pass 1 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (0.38 seconds) - (0.081733)
Pass 2 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (0.95 seconds) + (0.040866)
Pass 3 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (0.45 seconds) - (0.061300)
Pass 4 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (0.55 seconds) - (0.051083)
Pass 5 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (1.05 seconds) + (0.045975)
Pass 6 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (0.53 seconds) - (0.048529)
Pass 7 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (0.94 seconds) - (0.047252)
Pass 8 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (1.00 seconds) + (0.046613)
Pass 9 of 9 ->[0....1....2....3....4....5....6....7....8....9....] Done (1.03 seconds) + (0.046932)
Mesh with material materials/dev/reflectivity_30.vmat is extremely large in lightmap (0.1%), 980x1
World Bounds 836.107727,-4841.328125,576.282043 -> 4506.947754,238.769379,1563.085205
Mesh with material materials/dev/reflectivity_40.vmat is extremely large in lightmap (0.1%), 980x1
World Bounds -1440.500000,-426.031250,870.625000 -> -1165.000000,-293.406250,1062.125000
10119 / 212933 (04%) of triangles are outside lightmap importance volumes
LIGHTMAP QUERY SIMPLIFY: indices 606999->303444
LIGHTMAP QUERY MEM: verts 242071->211507, indices 638799->303444 (6mb -> 4mb)
Added lightmap query data to VPK: maps\beach_skybox\lightmaps\lightmap_query_data.kv3
Vertex Data Uncompressed: 3384112 bytes
Index Data Uncompressed: 1213776 bytes
==== Baking 1024 x 1024 lightmap ====
SetupTexels [0....1....2....3....4....5....6....7....8....9....] Done (0.05 seconds)
VRAD3 (local) [VRAD3 - Distributed Lighting Tool
Copyright (c) Valve Corporation, All rights reserved.
Build: pc64 May 27 2020 13:14:38
WD: E:\SteamLibrary\steamapps\common\Half-Life Alyx\game\hlvr_addons\hazard\_vrad3
Command: vrad3 -map maps/beach_skybox.vmap -script script.vrad3 -entrypoint lm_compute -blockfile=lm_block_00000000.dat -blocknum=0 -threads 4 -outdir results/outputs
Num Threads: 4
Loading scene_info.dat... Done (0.01 seconds)
Unserializing scene_info.dat... Done (0.05 seconds)
Loading lightmap_packing_geometry.dat... Done (0.01 seconds)
Lightmap: 1024x1024 in 16 256x256 blocks
Loading lightmap_info.dat block 0 (256x256)... Done (0.00 seconds)
Generate Samples (3x3 spl) - Rasterize Small Charts... Done (0.00 seconds)
Generate Samples (3x3 spl) - Rasterize Large Charts... Done (0.02 seconds)
Generate Samples (3x3 spl) - Re-project... Done (0.00 seconds)
Generate Samples (3x3 spl) - Reject Invalid... Done (0.71 seconds)
Generate Samples (3x3 spl) - Calculate Normals... Done (0.07 seconds)
Generate Samples (3x3 spl) - Map Samples to Texels... Done (0.06 seconds)
Generate Samples (3x3 spl) - Sort Sample to Texel Mapping... Done (0.15 seconds)
Generate Samples (3x3 spl) - Build Sample to Texel Lookup... Done (0.03 seconds)
Generate Samples (3x3 spl) - Calculate Confidence Values... Done (0.01 seconds)
Path Trace (128spp - 256spp - 5.00% errtol)... [0....1....
---------------------------------------------------------
Encountered accessviolation.
Wrote minidump to vrad3_2021_0108_222340_0_accessviolation.mdmp
---------------------------------------------------------
Unable to run Vrad3.
Light mapper didn't return valid triangles: failing.
+- hlvr_addons\hazard\maps\beach_skybox\world.vrman
--> Map build FAILED.
[FAIL]
0/ 1 (elapsed 27.845): e:\steamlibrary\steamapps\common\half-life alyx\content\hlvr_addons\hazard\maps\beach_skybox.vmap
Compile of 1 file(s) matching nonrecursive specification "e:/steamlibrary/steamapps/common/half-life alyx/content/hlvr_addons/hazard/maps/beach_skybox.vmap" took 27.845 seconds
-----------------------------------------------------------------
ERROR: 2 compiled, 1 failed, 0 skipped, 0m:28s
-----------------------------------------------------------------
Using breakpad crash handler Setting breakpad minidump AppID = 546560 Forcing breakpad minidump interfaces to load Looking up breakpad interfaces from steamclient Calling BreakpadMiniDumpSystemInit Looking up breakpad interfaces from steamclient Calling BreakpadMiniDumpSystemInit Steam_SetMinidumpSteamID: Caching Steam ID: 76561197975130070 [API loaded yes] Steam_SetMinidumpSteamID: Setting Steam ID: 76561197975130070 End build: 2021-01-08T22:23:42, elapsed time 0h:00m:30s.084ms