Commit Graph

1018 Commits

Author SHA1 Message Date
Eric Wasylishen 199cba7349 light: few optimizations to bounce code 2016-05-13 23:16:36 -06:00
Eric Wasylishen f73b9de0b3 common: make VectorLength, VectorNormalize static inline 2016-05-13 21:10:00 -06:00
Eric Wasylishen f967b89cea light: remove broken hitpoint feature of TraceLine 2016-05-11 16:46:51 -06:00
Eric Wasylishen d0480049e8 light: move TRACE_HIT_ constants to trace.c 2016-05-11 16:30:26 -06:00
Eric Wasylishen 7bd93cce37 light: move private BSP tracing stuff from light.h to trace.c 2016-05-11 16:23:02 -06:00
Eric Wasylishen 1ed000cbde light: move DirtTrace to trace.c 2016-05-11 16:16:49 -06:00
Eric Wasylishen b1691cf10a light: don't do bounce lighting when dirtdebug/phongdebug are in use 2016-04-30 01:04:53 -06:00
Eric Wasylishen 5e7e409966 light: bounce: remove some dead code 2016-04-30 01:00:57 -06:00
Eric Wasylishen bd5a15fc82 Revert "light: bounce: handle 0 dist between bounce light and surface point"
This reverts commit d3b6adb955.
2016-04-30 00:59:51 -06:00
Eric Wasylishen d3b6adb955 light: bounce: handle 0 dist between bounce light and surface point 2016-04-30 00:44:01 -06:00
Eric Wasylishen f446ba1ddf light: bounce: use both bounce light normal angle, and receiving surface normal angle to scale bounced light 2016-04-30 00:26:08 -06:00
Eric Wasylishen a283a623ae light: bounce: refactoring 2016-04-30 00:24:50 -06:00
Eric Wasylishen 3fb8b7d1e5 light: delete -lightturb and related flags for generating lightmaps for TEX_SPECIAL textures.
mankrip's lit water implementation relies on qbsp splitting water, so this code is not needed.
2016-04-29 23:23:28 -06:00
Eric Wasylishen 6ba2d99782 light: bounce: add some debug code 2016-04-29 22:52:33 -06:00
Eric Wasylishen bd68abad32 light: add LightWorld log header 2016-04-29 22:51:32 -06:00
Eric Wasylishen 99f6451741 light: bounce: don't generate bounce lights for "skip" texture 2016-04-29 22:43:42 -06:00
Eric Wasylishen ae082fccdb light: never generate lightmaps for "skip" texture 2016-04-29 22:43:12 -06:00
Eric Wasylishen b6fb5ecca2 light: fix bouncedebug 2016-04-29 21:21:47 -06:00
Eric Wasylishen afc43b0c55 light: make some functions non-static so they show up in profiling 2016-04-29 20:33:15 -06:00
Eric Wasylishen 83a5ef303d light: bounce: refactor light culling for speed 2016-04-29 18:43:57 -06:00
Eric Wasylishen 72c47c1b56 light: bounce: refactor a bit 2016-04-29 18:11:14 -06:00
Eric Wasylishen 6fe504760c light: don't compute regular lighting if we are doing -bouncedebug 2016-04-29 13:27:57 -06:00
Eric Wasylishen 9271a405d1 light: bounce: fix scaling of sunlight brightness 2016-04-29 13:06:40 -06:00
Eric Wasylishen 67a64f9be4 vis: support PRT1-AM portals generated by txqbsp-xt 2016-04-29 12:20:35 -06:00
Eric Wasylishen ebf04ceb24 light: bounce: multithread MakeBounceLights 2016-04-29 11:40:10 -06:00
Eric Wasylishen 2bca34265c light: use vis acceleration for bounce lights 2016-04-29 11:27:02 -06:00
Eric Wasylishen 7f31e6d4fd qbsp: don't warn about \b escape sequence 2016-04-29 10:36:26 -06:00
Eric Wasylishen 6459e53316 light: bounce: force a "gate" like cutoff for bounce lights 2016-04-28 23:18:49 -06:00
Eric Wasylishen 430c4b39b7 light: bounce: only scale by sending surface normal, not receiving.. seems to look better 2016-04-27 21:16:48 -06:00
Eric Wasylishen 713b92dcb5 light: preliminary bounce implementation 2016-04-27 19:19:29 -06:00
Eric Wasylishen 007696a734 light: fix face normal smoothing condition 2016-04-27 16:44:40 -06:00
Eric Wasylishen d426c8d9da light: some setup for bounced lighting 2016-04-26 15:14:22 -06:00
Eric Wasylishen e77c10d31d light: build polylib 2016-04-26 15:11:43 -06:00
Eric Wasylishen f65565ba62 light: don't do light behind plane test for curved surfaces. I broke lighting on pipes by changing this recently 2016-04-26 01:47:46 -06:00
Eric Wasylishen 11d7c4c44c light: fix build on travis 2016-04-26 01:13:42 -06:00
Eric Wasylishen a9ea9891bf light: calculate normals before correcting points, better results in concave areas 2016-04-26 01:10:15 -06:00
Eric Wasylishen c58528499d light: when interpolating a normal that lies outside of a face, recursively look it up on adjacent faces 2016-04-26 00:29:50 -06:00
Eric Wasylishen 8c28413a31 light: obj export: only export model 0 2016-04-26 00:22:26 -06:00
Eric Wasylishen 239d9c14f2 light: fix vis acceleration on bmodels 2016-04-24 19:17:27 -06:00
Eric Wasylishen f3132f342c light: Mod_LeafPvs: return whether we found a real pvs 2016-04-24 18:24:41 -06:00
Eric Wasylishen 318fc23481 light: implement "_bleed" light key.
"_bleed" "1" on a light entity skips the test that a light is on the front side of a face. useful for special effects.
2016-04-23 22:21:59 -06:00
Eric Wasylishen b6116ff42a light: don't skip light-behind-plane test for phong shaded faces anymore 2016-04-23 00:26:07 -06:00
Eric Wasylishen 824c1b613c light: fix memory leak 2016-04-22 21:21:02 -06:00
Eric Wasylishen 5ac18e5c6f light: index some PVS info at startup 2016-04-22 20:11:59 -06:00
Eric Wasylishen 5000f9d352 light: only do sunlight raytracing in leafs that can see sky 2016-04-22 19:27:17 -06:00
Eric Wasylishen d309aa02b0 light: refactor CalcPvs to calculate the face pvs in a cleaner way 2016-04-22 19:15:49 -06:00
Eric Wasylishen 3b7dbe42b0 light: fix broken vis optimization 2016-04-22 01:00:10 -06:00
Eric Wasylishen 169c89120a light: quick hack of 2nd sun. keys are "_sun2" "_sun2_mangle" "_sun2_color" 2016-04-21 01:05:48 -06:00
Eric Wasylishen 0a8965bae0 light: fix lighting with vis data 2016-04-21 00:22:35 -06:00
Eric Wasylishen 338ceae8c8 light: add face to lightsurf struct 2016-04-21 00:13:31 -06:00