Commit Graph

154 Commits

Author SHA1 Message Date
Magnus Norddahl 9ac7a07be6 - Set colormap light info using R_SetColorMapLight and R_SetDSColorMapLight rather than manually calculating it
- Move texture and span management into R_DrawMaskedColumn
2016-12-18 11:58:32 +01:00
Christoph Oelckers c7cddcac0b - removed Build notice from r_segs.cpp because there is no Build code left in this file. 2016-12-09 15:12:16 +01:00
Christoph Oelckers 5da9f71589 - renamed the WallMost functions because again: No more Build code -> no Build names! 2016-12-09 14:46:05 +01:00
Christoph Oelckers 356e55f0a2 - made the general entry point to the wall drawer a single function instead of requiring the caller to check for NPOT textures.
- renamed all functions in r_walldraw.cpp to give them names more in line with Doom's naming conventions. Since this is not Build code anymore it also shouldn't use Build names to avoid giving a false impression.
2016-12-09 14:25:51 +01:00
Christoph Oelckers eab06ef086 - more Build cleanup: Moved clearbufshort out of Build derived headers, removed the inline version for GCC 32 bit which was actually Build derived and renamed the C-version of this function, which does not originate from Build to 'fillshort'.
- cleaned out a lot the SafeDivScale stuff in m_fixed.h. The only SafeDivScale variant still in use was #16 for FixedDiv, so all the SafeDivScale stuff has been removed and the 16 variant renamed to FixedDiv because that's the only form in which it is still being used. (2x in R_DrawVoxel and 1x in ACS's FixedDiv PCode.)
- removed Build notice from m_fixed.h because aside from the inlines includes there is nothing here from Build anymore.
2016-12-09 13:04:53 +01:00
Christoph Oelckers 34d551fe1f - moved wallscan code into its own file so that it can get an appropriate copyright notice and does not inflate an already large source file even more. 2016-12-09 11:49:18 +01:00
Magnus Norddahl 3ff91807b8 Move swrenderer into a namespace, add multithreading framework, and move drawers to commands 2016-12-07 09:34:49 +01:00
Magnus Norddahl 6417c1a7a3 Rewrite PrepWall and PrepLWall, plus make them aware of pixel centers 2016-11-27 00:43:32 +01:00
Magnus Norddahl 547973c8ba Rewrite OWallMost and WallMost to contain no build code 2016-11-26 23:28:21 +01:00
Marisa Heit ae28c9b29c Fix divide by 0 in new wallscan functions with 1-pixel tall textures 2016-11-05 22:09:38 -05:00
Magnus Norddahl 60ae4a8568 Replace build wallscan with a rewritten version that tile and scale correctly 2016-11-05 04:02:30 +01:00
Marisa Heit 5df21fda68 Fixed: Masked midtexture yscale incorrectly used the texture's X scale 2016-11-01 00:18:56 -05:00
Marisa Heit 9388597443 Add 1 pixel tall and wide texture support to the renderer
- These require manual detection and overriding of the scaling factors to
  0, because a right shift of (32-0) bits wraps around to 0 and results in
  no shift at all rather than leaving the register zeroed out.
2016-11-01 00:08:16 -05:00
Magnus Norddahl 837ed7bd80 Fix dancing sprites due to texture coordinate calculations not taking pixel centers into account
Merge R_DrawMaskedColumn and R_DrawMaskedColumnHoriz into one function to remove code duplication
2016-10-29 05:35:41 +02:00
Marisa Heit 31f01d076e Fixed: Decals calculated "lighting" wrong
- Instead of calculating lighting based from the left edge of the wall
  segment the decal was on, it was calculated from the left edge of the
  wall instead.
2016-10-22 20:27:02 -05:00
raa-eruanna df6214b142 - Fixes 2016-10-21 07:21:56 -04:00
raa-eruanna c76431414a - Implemented r_fullbrightignoresectorcolor from QZDoom 2016-10-21 07:06:24 -04:00
Christoph Oelckers e04055dbb2 - added multiple message levels for 'developer' CVAR so that the important stuff won't get drowned in pointless notification spam that's of no use to anyone.
- made 'developer' CVAR persist across launches and added some menu entries for it.
- added checks for 'developer' to ACS's CheckInventory function.
2016-08-28 09:55:04 +02:00
Christoph Oelckers 0726a88ab9 - only return DWORD aligned addresses in openings because the 3D floor code stores floating point values in there which cannot be accessed on platforms with strict alignment rules. 2016-05-11 12:04:41 +02:00
Randy Heit a95c6b9644 Draw upper/lower textures on two-sided portal lines 2016-04-29 21:54:29 -05:00
Randy Heit f3d273c94f Fixed: Tiled midtextures could go up past the ceiling when a 3D floor is in view 2016-04-28 22:06:57 -05:00
Randy Heit 96228ca15f Trying to fix some rounding, not sure it's actually correct yet 2016-04-28 21:14:48 -05:00
Randy Heit ac69ed3361 Minimal wallmost changes
- Add comments
- Fixed: When WallMost() finds a line entirely above the screen, it should
  set the most array to 0, not -1.
2016-04-27 22:17:33 -05:00
Randy Heit d970be48f9 Use floating point xscale in R_RenderFakeWall() 2016-04-26 23:30:16 -05:00
Randy Heit ee43c4ff95 Fixed: Accidentally left in /65536.0 in WallMost() 2016-04-26 23:00:41 -05:00
Christoph Oelckers a26d81e060 - fixed incomplete float conversion in R_RenderFakeWallRange. 2016-04-27 02:28:45 +02:00
Christoph Oelckers 0f99d7d73f - floatified the few remaining linedef and sector properties that still were fixed_t. The only fixed point things left in r_defs.h are the nodes and a fixed point setter function for vertex_t, which is still needed by the node builder. 2016-04-24 12:15:09 +02:00
Christoph Oelckers 31845cd16b - fixed two fixed/float mixups. 2016-04-24 10:24:43 +02:00
Christoph Oelckers 04e614daec - removed some fixed point functions that are no longer needed.
- fixed: Visplane checks should only compare the plane flags that are relevant for rendering and mask out the rest.
- floatified FTransform and made the visplane checks a bit less verbose by moving the comparison as an operator into FTransform.

Note that this operator needs forceinline on Visual Studio so that it won't get called as a function.
2016-04-23 12:42:07 +02:00
Christoph Oelckers 35a6994d0a - remove the 'F' prefix from the floating point access function to the sidedef texture info, now that the fixed point versions are gone. 2016-04-23 10:55:55 +02:00
Christoph Oelckers 4d4f31fd83 - floatified sidedef texture info and fixed two bugs involving this data. 2016-04-23 09:41:59 +02:00
Randy Heit f1b3f59bcc Renderer floatification: Use floating point for wall scale and yrepeat 2016-04-22 23:12:53 -05:00
Randy Heit 1f97488945 Renderer floatification: Use floating point for decals 2016-04-22 23:12:53 -05:00
Randy Heit b2b3e50c5c Renderer floatification: Use floating point for geometry Zs 2016-04-22 23:12:53 -05:00
Randy Heit 3ef5a678d5 Renderer floatification: Use floating point for texturemids and Y scales 2016-04-22 23:12:53 -05:00
Randy Heit ec8d038c99 Renderer floatification: Use floats for lighting values 2016-04-22 23:10:34 -05:00
Randy Heit 4416d88eb2 Renderer floatification: Use floating point for visibility values 2016-04-22 23:10:02 -05:00
Randy Heit ded3f92452 Commence renderer floatification 2016-04-22 23:09:13 -05:00
Edoardo Prezioso 28ac65b25b - Fixed GCC and Clang compilation errors. 2016-04-02 23:01:32 +02:00
Christoph Oelckers 9a07f81269 - renamed all ZatPoint variants that return a fixed point value to ZatPointFixed, to avoid accidental mixup with the floating point variants. 2016-04-02 20:45:32 +02:00
Christoph Oelckers 66929cbaff - floatified p_trace, p_slopes and p_udmf.cpp.
- major cleanup of unused code.
2016-03-30 16:30:22 +02:00
Christoph Oelckers 77f2530236 - floatified the sector plane movers and removed some of the ZatPoint conversion cruft. 2016-03-30 09:41:46 +02:00
Christoph Oelckers 25f5e8449a - replaced all direct access to sector plane coefficients with wrapper functions. 2016-03-29 12:40:41 +02:00
Christoph Oelckers c7ae4688a3 - replaced all direct access to vertex coordinates with wrapper functions.
So that code replacement can be done piece by piece and not all at once.
2016-03-29 10:07:06 +02:00
Christoph Oelckers 0c39bdd04c - floatified texture scale values. 2016-03-26 13:37:44 +01:00
Christoph Oelckers 301f5abadc - floatified the decal code. 2016-03-22 22:07:38 +01:00
Christoph Oelckers 4e60ea0252 - made AActor::alpha a floating point value
- replaced some uses of FRACUNIT with OPAQUE when it was about translucency.
- simplified some overly complicated translucency multiplications in the SBARINFO code.
2016-03-21 12:18:46 +01:00
Randy Heit 48b6b6e057 Clip portals to viewheight, not screen height
- Aside, but is this even neccessary? The arrays being copied from should
  already be clipped properly.
2016-03-08 19:53:37 -06:00
Randy Heit 55142078d8 Normalize line endings 2016-03-01 09:47:10 -06:00
Christoph Oelckers 7242a0ef94 - fixed: Rendering 2-sided walls with 3D floor light effects had the 'is3dfloor' flag of GetLightLevel inverted. 2016-02-29 10:26:07 +01:00