Eric Wasylishen
7252ba7841
light: hack -soft to give better results on https://github.com/ericwa/tyrutils-ericw/issues/171
2017-09-16 17:47:40 -06:00
Eric Wasylishen
26c5f65f4e
light: for curved surfaces, don't reject hits when the dot product of the surface point normal and surface-point-to-light vector is < 0, since "anglescale" will typically boost the angle factor to 0.5
...
fixes https://github.com/ericwa/tyrutils-ericw/issues/172
2017-09-16 17:10:48 -06:00
MaxED
fe1e040cd1
Added "_falloff" light property. Allows to set light falloff in map units.
2017-08-23 15:00:32 -06:00
Eric Wasylishen
c0b88b7e99
light: fixes for degenerate faces
2017-07-05 20:43:47 -06:00
Eric Wasylishen
4dcfc12f50
light: refactor _shadowself handling
2017-06-26 17:42:50 -06:00
Eric Wasylishen
563307445d
light: fix logic for switching lightmaps for switchable shadows
2017-06-26 14:20:15 -06:00
Eric Wasylishen
b71f769c0a
light: experimental support for switchable bmodel shadows:
...
Current specs/limitations:
- only supported for sunlight and regular lights
- enabled with "_dynamicshadow" "1"
- writes the lightstyle to a "dynshadowstyle" entity key, hardcoded
- only handles one dynamic occluder for a given lightmap sample
- styled lights passing through a dynamic occluder turn non-styled
2017-06-25 20:06:46 -06:00
Eric Wasylishen
ce8ad6c384
light: handle iffy faces
2017-06-15 13:43:42 -06:00
Eric Wasylishen
197697ca73
light: fix black rotators
2017-06-05 14:00:50 -06:00
Eric Wasylishen
66bc8209eb
light: loosen point off plane assertion
2017-06-05 14:00:16 -06:00
Eric Wasylishen
902c45c946
all: make VectorCompare take an explicit epsilon
2017-04-26 14:20:45 -06:00
Eric Wasylishen
5eb4fd8790
common: make Face_Plane_E return a plane3f
2017-04-24 01:54:25 -06:00
Eric Wasylishen
68b084a6c3
replace glm with qvec
2017-04-24 00:26:49 -06:00
Eric Wasylishen
a0a7021707
light: refactor position_t from tuple to class
2017-03-29 16:09:49 -06:00
Eric Wasylishen
10386581a6
light: make bounce of styled lights opt in with "_bouncestyled" worldspawn key
2017-03-27 16:44:04 -06:00
Eric Wasylishen
f957cba775
light: experimental bounce version using final gather
2017-03-21 21:01:09 -06:00
Eric Wasylishen
30d9a53341
light: move FractionOfLine to mathlib
2017-03-18 23:26:16 -06:00
Eric Wasylishen
29884e2b4a
bsputils: add bounds checking to Face_GetNum
2017-03-18 16:17:01 -06:00
Eric Wasylishen
8a83e3d351
light: BounceLightsForFaceNum(): return indices so we have 1 main copy of the bounce lights
2017-03-15 13:22:43 -06:00
Eric Wasylishen
c2c3e915e6
light: fix leak of lightsurf->realfacenums
2017-03-15 13:22:35 -06:00
Eric Wasylishen
18b75ec904
light: rewrite -bouncelightsdebug to handle patches smaller than a face
2017-03-15 10:59:40 -06:00
Eric Wasylishen
154158ddba
light: BounceLightsForFaceNum: avoid an unnecessary std::vector copy
2017-03-15 10:59:16 -06:00
Eric Wasylishen
553f02d582
light: restore performance of bounce lighting
2017-03-06 22:50:20 -07:00
Eric Wasylishen
48a6314dfb
light: bounce styled lights
2017-03-05 20:05:34 -07:00
Eric Wasylishen
461afbc15d
light: remove ltface2.cc/hh
2017-03-01 13:20:09 -07:00
Eric Wasylishen
b163f766bb
light: drop unneeded light2.cc/hh
2017-02-27 19:10:55 -07:00
Eric Wasylishen
69d5669773
light: delete some dead code
2017-02-27 17:43:56 -07:00
Eric Wasylishen
d513f43540
light: remove more tuple initializer lists
2017-02-27 12:40:03 -07:00
Eric Wasylishen
1c80f8c8d8
light: don't use initializer lists to construct tuples (for gcc)
2017-02-27 12:35:05 -07:00
Eric Wasylishen
ea382c50f2
light: don't use constexpr (for vs2013)
2017-02-27 12:33:03 -07:00
Eric Wasylishen
97a00f0f41
light: avoid recomputing things in CalcPointNormal
2017-02-26 22:58:08 -07:00
Eric Wasylishen
410bec9d62
light: wip: make CalcPointNormal also position the point
2017-02-26 00:28:23 -07:00
Eric Wasylishen
6c946038ee
light: move edgeToFaceMap_t stuff to phong.hh/cc
2017-02-25 14:44:59 -07:00
Eric Wasylishen
abf0c13b2d
light: cleaning CalcPointNormal
2017-02-25 13:31:56 -07:00
Eric Wasylishen
22b5684c23
light: save the actual face number of each sample point
2017-02-24 21:05:59 -07:00
Eric Wasylishen
a183be75d7
light: minor tidying of CalcPoints ifdef
2017-02-24 14:11:47 -07:00
Eric Wasylishen
278c5f5b2b
light: LightFace_OccludedDebug: clear occluded flag in this debug mode
2017-02-24 00:24:29 -07:00
Eric Wasylishen
29c7f79a0b
light: misc stuff
2017-02-23 20:53:10 -07:00
Eric Wasylishen
b31ae5d243
light: ltface.cc: use glm namespace
2017-02-20 14:39:56 -07:00
Eric Wasylishen
6c9f9f9727
light: fix minlight handling
2017-02-20 14:37:46 -07:00
Eric Wasylishen
c17c33a71c
light: rewrite blur
2017-02-20 14:37:41 -07:00
Eric Wasylishen
7c0e8f9b24
light: fix -extra4 downsampling to use occlusion values
2017-02-20 14:37:36 -07:00
Eric Wasylishen
418d83cbeb
light: skip raytracing occluded points
2017-02-20 14:36:50 -07:00
Eric Wasylishen
365c143039
light: use mangle_from_vec in CalcPoints_Debug to dump point normal
2017-02-14 23:52:39 -07:00
Eric Wasylishen
7300aacdff
light: Add -debugoccluded
2017-02-11 22:22:26 -07:00
Eric Wasylishen
5fe4f23371
light: add a debug mode for showing contributing faces
2017-02-11 15:45:30 -07:00
Eric Wasylishen
6f72ab5eda
light: CalcPoints_Debug: log 'occluded' state
2017-02-10 15:54:35 -07:00
Eric Wasylishen
57d8ed77ea
light: CalcPoints: call SetupContributingFaces
2017-02-10 15:52:12 -07:00
Eric Wasylishen
87868275de
light: clean CalcPoints
2017-02-10 15:52:12 -07:00
Eric Wasylishen
71a3dd769a
light: clean up LightFace() function
2017-02-10 15:52:12 -07:00