Commit Graph

21 Commits

Author SHA1 Message Date
Ivan Avdeev
eceb52cee0 add support for studio chrome meshes, fix #149
no support for glow chrome yet.
2021-10-31 17:27:22 -07:00
Ivan 'provod' Avdeev
3f12a42432 rtx: fix translucent things casting shadows (they shouldn't for now) 2021-10-31 17:27:22 -07:00
Ivan 'provod' Avdeev
24f11bccc7 rtx: add material mode enum, precursor for proper translucency handling
#173
2021-10-29 12:48:36 -07:00
Ivan 'provod' Avdeev
5e50bdfcf2 rtx: add conveyor scrolling texture, fix #158 2021-10-27 22:48:26 -07:00
Ivan 'provod' Avdeev
452ca9de45 rtx: collect static light sources only once on map load, #122
this also breaks static surface lights
2021-10-25 10:17:49 -07:00
Ivan Avdeev
9006d679ec rtx: associate msurfaces with mleafs 2021-10-13 12:27:24 -07:00
Ivan Avdeev
ae12b4505d remove material flags 2021-09-06 14:24:36 -07:00
Ivan Avdeev
b9f5f87c76 bring back ray traced transparency
1. Probabilistically let ray through material or reflect it based on
   transparency probability (which is essentially just alpha for now).
2. Introduce opaque flag to be able to treat transparent objects as not
   casting shadows. This is not very realistic, but oh well.
2021-09-06 11:57:23 -07:00
Ivan 'provod' Avdeev
c90187f57f rtx: use a common definition for Kusok; pass color
Also pass alpha (not used yet)
2021-09-04 13:50:05 -07:00
Ivan 'provod' Avdeev
36cfe22e8d rtx: add sbt hit entry w/o any hit
Majority of materials are without alphamask, so no need to have any hit shader
2021-09-04 13:50:05 -07:00
Ivan Avdeev
d8ebf5ac33 rtx: add emissive color, remove emissive flag 2021-08-31 11:19:44 -07:00
Ivan Avdeev
8d06058aa4 rtx: add first iteration of material flags support
it's clearly suboptimal, but no worries, we'll iterate
2021-08-31 11:19:44 -07:00
Ivan Avdeev
3b605a19b5 fix depth test for glow render mode; comments
also add a lot of observations to ref_vk/TODO.md related to materials
2021-08-31 11:19:44 -07:00
Ivan Avdeev
76b82ac884 rtx: calculate maxVertex correctly
after we've updated how brush index buffer references vertices to allow
for draw call coalescing ray tracing broke on amd.
this is because amd cards expect a correct value in
VkAccelerationStructureGeometryTrianglesDataKHR::maxVertex. make sure we
fill a correct value there.
2021-08-18 09:39:33 -07:00
Ivan Avdeev
5208219b44 join alloc+lock operations on buffer init
this simplifies the api and implementation
2021-08-11 11:43:33 -07:00
Ivan Avdeev
fc2c7185df rtx: add basic transparency and reflections
this is very proof-of-concept quality. it should be definitely done some other way

e.g. we should control reflectivity and transparency differently (and not together)
and they should be based on texture ids, not on render_mode

it's also unfortunate that transparency required a lot of bounces. we should probably control transparency bounces separately from light bounces.
alternatively, transparency effects (beams, sprites) should be done with custom intersection shaders and not based on transparent geometry
2021-07-31 12:35:59 -07:00
Ivan Avdeev
316e77df78 rtx: add alpha mask transparency 2021-07-14 11:54:21 -07:00
Ivan Avdeev
d66ee6b3ce rtx: fix hit/miss shader order
also move geometries offsets to ranges struct instead of adding offsets to buffers addresses
2021-07-10 11:06:55 -07:00
Ivan Avdeev
2ca2e2058e fix compile warnings for CI, part 2 2021-07-06 12:54:45 -07:00
Ivan Avdeev
cdefb7a50a fix compiler warnings for CI 2021-07-06 09:41:48 -07:00
Ivan Avdeev
34359e2f75 rtx: start splitting ray tracing into functional modules
move model management into vk_ray_model
2021-07-05 10:59:14 -07:00