Christoph Oelckers
d654e02dea
- rewrote dynamic lights to not use actors for the internal representation and made DynamicLight a purely scripted class.
...
This should be less of a drag on the playsim than having each light a separate actor. A quick check with ZDCMP2 showed that the light processing time was reduced to 1/3rd from 0.5 ms to 0.17 ms per tic.
It's also one native actor class less.
2019-01-01 19:35:55 +01:00
Magnus Norddahl
ebfa61514e
- remove InitSoftwareSky
2018-12-19 04:44:25 +01:00
Magnus Norddahl
efb8e39aa9
- move more of the light calculation code to the drawerargs
2018-12-18 00:37:50 +01:00
Magnus Norddahl
2ce91ea62f
- delay converting sprite lightlevels to a shade until we hit ColormapLight
2018-12-17 07:54:46 +01:00
Magnus Norddahl
946f657a37
- fix heretic light torch in software renderer and remove some code duplication
2018-12-17 06:13:00 +01:00
Magnus Norddahl
f35aeec6c3
- move visibility calculation to LightVisibility
2018-12-17 05:10:26 +01:00
Magnus Norddahl
eaf1c4f1e2
- implement the physical texture scaling at the drawer transition level as the frontend of the software renderers do not even need to know the textures are scaled
2018-12-16 14:34:44 +01:00
Christoph Oelckers
79a0f76801
- replaced TexMan.operator() with two functions.
...
This was done to make reviewing easier, again because it is virtually impossible to search for the operators in the code.
Going through this revealed quite a few places where texture animations were on but shouldn't and even more places that did not check PASLVERS, although they were preparing some paletted rendering.
2018-12-07 02:53:18 +01:00
Christoph Oelckers
32e245f2b9
- moved the software rendering specific parts of the sky setup to r_skyplane.cpp.
2018-12-06 20:52:03 +01:00
Christoph Oelckers
a4d61e6fb1
- everything compiles again.
...
As a bonus this already fixes several bugs caused by the botched texture scaling implementation the original texture manager came with.
System cursors are currently disabled because they rely on functionality that needs to be moved to different classes.
2018-12-06 20:12:15 +01:00
Magnus Norddahl
85f5f897d7
- enable model rendering in the software renderer
2018-06-09 12:29:33 +02:00
Magnus Norddahl
f5386a706f
- fix software renderer dynamic lights not working properly in mirrors
2018-06-05 20:09:02 +02:00
Magnus Norddahl
1a5f679d43
- Fix depth values when screenblocks less than 11
2018-04-08 13:45:23 +02:00
Magnus Norddahl
7f25913b2d
- Fix depth values written by sloped planes
2018-04-08 02:22:01 +02:00
Magnus Norddahl
2d51fa5b43
- Clean up PolyTriangleDrawer API so that it can better support both softpoly and the swrenderer
...
- Slightly improve how softpoly processes portals
- Pass the vertex transform matrix via a command rather than being part of the drawer args
- Improve zbuffer drawers in the software renderer
- Misc model rendering fixes
2018-04-07 15:48:48 +02:00
Christoph Oelckers
e89a598b31
- renamed FTexture's UseType flags and gave them a dedicated type.
...
This was done mainly to reduce the amount of occurences of the word FTexture but it immediately helped detect two small and mostly harmless bugs that were found due to the stricter type checks.
2018-03-25 20:26:16 +02:00
Christoph Oelckers
f4d9ad1123
- extended FTexture::GetPixels and FTexture::GetColumn by a RenderStyle parameter.
...
Now it is no longer necessary to provide specially set up textures for rendering shaded decals, they can use any PNG texture now that contains a proper red channel.
Handling of the alPh chunk has been removed as a result as it in no longer needed.
2018-03-18 21:33:44 +01:00
Magnus Norddahl
71623198d2
- remove fake3D with structs and localize their usage instead of sharing global state
2018-03-08 04:05:35 +01:00
Magnus Norddahl
a8b79a28c8
- Disable model rendering in the software renderer
2017-11-29 22:18:21 +01:00
Magnus Norddahl
d43ac8b9ae
- Add model rendering to the software renderer
2017-11-27 23:47:26 +01:00
Rachael Alexanderson
eb425f206a
- In software rendering, lights now check if they are too far above or below a certain plane before rendering. An example of this is in unloved.pk3 where in map02, some lights are above the ceiling.
2017-08-18 18:14:43 -04:00
Magnus Norddahl
8311a18282
- Fix plane pixel center sampling bug
2017-07-22 12:29:46 +02:00
Rachael Alexanderson
25ab31e92c
- corrected transferred sky offsets using ZDoom 2.8.1 source - the sky needed to be offset by 28 units.
2017-07-11 05:53:21 -04:00
Magnus Norddahl
9c3361dfe2
- Fix stat fps to write something slightly more useful
2017-06-27 21:15:26 +02:00
Magnus Norddahl
fa36677bdb
- Removed power-of-two limitation from span drawers, except for slopes
2017-06-21 03:08:11 +02:00
Christoph Oelckers
3b024c347b
- use a dedicated flag word for the dynamic light flags instead of piggybacking on some flags4 bits.
2017-06-18 10:15:31 +02:00
Christoph Oelckers
96d328de9b
- removed all Doom Source license and all default Raven copyright headers and replaced them with GPLv3. Also fixed the license in a few other files.
...
For some files that had the Doom Source license attached but saw heavy external contributions over the years I added a special note to license all original ZDoom code under BSD.
2017-04-17 13:33:19 +02:00
Christoph Oelckers
57d703236b
- changed Doom source license to GPL in all subdirectories and fixed missing licenses in a few other files.
2017-04-17 12:27:19 +02:00
Rachael Alexanderson
09c3060728
- fixed: skybug on ARM was caused by undefined conversion from float to unsigned int. adding intermediary signed int cast fixes this problem.
2017-03-22 05:51:12 -04:00
Christoph Oelckers
39b329e3f7
- this was accidentally left in.
2017-03-17 10:12:47 +01:00
Christoph Oelckers
f201dab534
- moved the subsectors into FLevelLocals.
2017-03-17 00:22:52 +01:00
Christoph Oelckers
b529b1e3a7
- removed several unneeded GL headers from the software renderer's sources.
...
- consolidated the code to calculate a sprite's display angle for all 3 renderers.
As it turned out, they all differed in their feature support because they had always been updated independently by different people.
2017-03-16 13:49:34 +01:00
Magnus Norddahl
80f9c81e36
- move PrepareTexture out of the inner drawer loops
2017-03-15 02:59:33 +01:00
Magnus Norddahl
a663f71a9f
- Added thread safety to texture loading in the software renderer
2017-03-12 22:53:20 +01:00
Magnus Norddahl
00f6ed45a2
Make LightVisibility thread local
2017-03-12 20:40:00 +01:00
Magnus Norddahl
6788b19e89
- stop using PORTSF_INSKYBOX flag in software renderer as it is not thread safe
2017-03-12 19:43:40 +01:00
Magnus Norddahl
5fdbbc4f9e
Remove usage of r_viewpoint and r_viewwindow globals from software renderer and poly renderer
2017-03-12 18:54:39 +01:00
Magnus Norddahl
0c9014b984
- move r_utility globals into r_viewpoint and r_viewwindow
...
- change r_utility functions to only work on FRenderViewpoint and FViewWindow
2017-03-11 23:28:07 +01:00
Magnus Norddahl
d75e09f545
Fix span dynamic light rendering glitch
2017-03-10 12:25:18 -05:00
Rachael Alexanderson
9d5f8ba250
- fixed: P_AlignFlat's y-offset data was ignored when calculating plane offsets for the final render
2017-03-10 12:04:43 +01:00
Magnus Norddahl
65f8d65858
Minor code clean up
2017-03-06 23:27:02 +01:00
Rachael Alexanderson
28abc96aef
- fully implemented "nolightfade" to turn off diminishing lights in the software renderer.
...
- unfortunately, LIGHT2SHADE had to be transformed into a namespaced function.
2017-03-06 16:14:54 -05:00
Rachael Alexanderson
bd61e9f3f4
- Disabled dynlights during invulnerability/lightamp (or any FixedColormap or FixedLightLevel)
2017-02-27 08:20:26 -05:00
Magnus Norddahl
56045c1293
Remove r_drawers.h and move softpoly drawer related stuff out of the swrenderer
2017-02-23 09:02:13 +01:00
Magnus Norddahl
58495ea714
Renamed Clip3DFloors to Clip3D to fix gcc compile error
2017-02-06 16:04:27 +01:00
Magnus Norddahl
7e6c91d73c
Remove yslope loopup table and StepColumn
2017-02-06 15:15:09 +01:00
Magnus Norddahl
cfe4c55973
Remove software renderer internals from F3DFloor
2017-02-04 19:13:56 +01:00
Magnus Norddahl
6f5e720576
Split drawer command queue from drawer threads
2017-02-04 12:38:05 +01:00
Magnus Norddahl
45f623faf4
Move frame memory allocator into RenderThread
2017-02-04 02:50:52 +01:00
Magnus Norddahl
627a388d57
Move renderer singletons into a RenderThread class
2017-02-04 00:25:37 +01:00