Ian Curtis
20a9514aa2
For scroll fog set the viewport to the entire area, allows fog to work in widescreen mode
2016-12-15 19:27:08 +00:00
Ian Curtis
ca7046729e
properly cache un-normalised texture coordinates, fixes a texturing regression in Daytona
2016-12-15 12:10:52 +00:00
Ian Curtis
f355e2d062
fix microtexture colours
2016-12-15 00:45:32 +00:00
Ian Curtis
89e75a9803
Only check scroll fog value from the first viewport from each priority layer. Seems to fix problems with background fogging.
2016-12-14 19:57:05 +00:00
Ian Curtis
707e945db9
delete unused files
2016-12-09 14:15:11 +00:00
Ian Curtis
2c23268d88
Support microtexture relative scale. The exact scaling values are not known, but a 2x difference between each level seems highly likely. We know from visual inspection from scud that the first level is exactly 4. The SDK has a function that accepts a float input for scale and does this. lod = (1/scale) + 0.5. If lod>3 lod = 3. So this is our best guess.
2016-12-09 14:13:46 +00:00
Ian Curtis
da8b63b44b
The model3 shares vertices between polygons. But it also seems to do this for polygons with different textures. This means the texture coordinate for potentially different sizes textures is shared. Currently this was broken leading to some corrupted looking textures. The fix is to simply cache the old texture coordinates, and recalculate the normalised coordinates in the new texture coordinate space.
2016-12-06 14:39:46 +00:00
Ian Curtis
10a5d2c0e1
refactor
2016-12-06 12:25:34 +00:00
Ian Curtis
eece2d75b4
tweak scroll fog logic
2016-12-04 22:37:49 +00:00
Ian Curtis
adbebb0204
clean up
2016-12-04 22:37:22 +00:00
Ian Curtis
a310e8e5cf
minor optimisations
2016-11-28 17:32:25 +00:00
Ian Curtis
abc8c24b69
Only check the geometry for culling with valid node distances. We will need this later.
2016-11-27 19:30:46 +00:00
Ian Curtis
fe60d115d2
Revert changes .. if we clip against the real3d clipping planes, our wide screen hack won't work anymore.
2016-11-26 01:19:51 +00:00
Ian Curtis
665fa90425
Get clipping planes directly from the viewport data. Also no need to clip against a far plane
2016-11-26 01:12:08 +00:00
Ian Curtis
54c405709f
Need to walk back in memory and check the previous texture tiles to see if they overlap with the current textures being invalidated. If they overlap they must be cleared too. Algorithm is a bit brute forcy and more expensive than I'd like but it fixes the bad textures in Spikeout.
2016-11-22 20:30:10 +00:00
Ian Curtis
84ae8f035c
Skip processing the mipmap section of memory. The real3d doesn't create mipmaps down to 1x1 that is needed to do mipmapping properly on modern hardware anyway.
2016-11-21 09:04:56 +00:00
Ian Curtis
2ddc8a30e0
Clear queued texture uploads after processing them. Saves re-uploading the same textures whilst paused
2016-11-20 17:02:59 +00:00
Ian Curtis
10dd530cde
More accurate 2D colours. White should map to 255 not 248
2016-11-15 12:44:47 +00:00
Ian Curtis
483ba2f398
Fix the shading in scud. When lighting is disabled the fixed shading intensities appear to be offset values added to the colour value.
2016-11-11 17:50:27 +00:00
Ian Curtis
0a7c0d0864
change throttle logic for smoother playback, we could get closer to 60fps if SDL timers weren't so lame
2016-10-21 00:04:12 +00:00
Ian Curtis
2f49012786
change scroll fog logic to parse the lower priority viewports first
2016-10-09 18:10:57 +00:00
Ian Curtis
f0a15febd1
implement scroll fog, fixes a tonne of missing fx
2016-10-09 16:34:12 +00:00
Ian Curtis
ef11990d19
Parse out scrollfog value used for blending over the 2d background.
2016-10-08 15:41:16 +00:00
Ian Curtis
33e795de9b
Fix scenes with missing fog in ocean hunter. The game was passing negative fog densities. The sign seems to be ignored by the model 3.
2016-10-08 15:15:25 +00:00
Ian Curtis
9eeb81ac69
same fix for legacy engine
2016-10-08 12:10:47 +00:00
Ian Curtis
33cf6c89d1
our scratch mem must match correct max texture size
2016-10-08 11:59:25 +00:00
Ian Curtis
c472d90fb9
Fix the sky in advanced stage in Dirt Devils. It uses a massive (for 1998 :p) 1024x256 texture.
2016-10-06 20:10:45 +00:00
Ian Curtis
c3581c9fe8
Support multiple microTextures, fixes crazy texturing in sega ski champ. I'm assuming microtextures are always located on the other memory bank to the base texture. This logic seems to work for all our games anyway.
2016-10-06 01:37:29 +00:00
Bart Trzynadlowski
e21ea93319
Added RGBA4 format to BMP file writer
2016-09-07 01:25:27 +00:00
Bart Trzynadlowski
3df3610361
Made parsing of hex values more robust
2016-08-25 04:54:08 +00:00
Bart Trzynadlowski
23435ae4fe
Initial check in of Games.xml (only two games defined so far)
2016-08-25 04:53:38 +00:00
Bart Trzynadlowski
458684eb22
Fixed new 3D engine's fragment shader to work on some older GPUs by reducing the number of discard statements to one
2016-08-24 22:21:18 +00:00
Bart Trzynadlowski
4b184b05dc
Updated game loader to make use of latest changes to config tree: generic value types and eliminated pointers
2016-08-24 04:13:23 +00:00
Bart Trzynadlowski
c2f80cef6b
Support for hex numbers in string to integer conversions (with '0x' prefix) and special keywords in string to bool conversions (true/false/on/off/yes/no)
2016-08-24 04:11:52 +00:00
Bart Trzynadlowski
f08ad1584f
Added Util::Stricmp() and small tweak to serialization of Util::Format
2016-08-24 04:10:20 +00:00
Bart Trzynadlowski
2efe18b525
Added support for multiple value types in config nodes.
...
Removed Ptr_t and ConstPtr_t from public interface, moved config tree builders into their own file, and made them pass by reference and value.
Exceptions can be thrown now on lookup failures.
Removed s_empty_node -- failed lookups in [] operator create a permanent "hidden" child.
Updated comment in NewConfig.cpp.
2016-08-21 22:22:45 +00:00
Bart Trzynadlowski
01a6ad1596
Added copy constructor and assignment operator using C++11 move semantics
2016-08-19 00:01:45 +00:00
Bart Trzynadlowski
a9816467d8
Defined inputs
2016-08-18 04:19:36 +00:00
Bart Trzynadlowski
fbeeb3c922
Support for deep copies via assignment operator. This will pave the way for elimination of Ptr_t and ConstPtr_t.
2016-08-18 04:14:36 +00:00
Bart Trzynadlowski
5652aab91f
Added Write() method to write buffer to an ostream, and added an ostream operator overload
2016-08-18 04:13:50 +00:00
Bart Trzynadlowski
1dc360a8b0
Changes to game loader interface, added 32-bit word swapping utility function
2016-08-11 03:53:19 +00:00
Bart Trzynadlowski
41105c15d7
Added Logger.o to OSX and UNIX Makefiles. Should fix compilation on these platforms.
2016-08-10 03:38:19 +00:00
Bart Trzynadlowski
821243b80f
Removing MSVC Makefile
2016-08-10 03:37:29 +00:00
Bart Trzynadlowski
a2423a8b75
Initial check-in of game loader (not operational yet)
2016-08-10 03:28:40 +00:00
Bart Trzynadlowski
037bfc648d
Byte swapping utility function
2016-08-10 03:27:59 +00:00
Bart Trzynadlowski
718c237063
Added ValueAsBool(), ValueAsBoolWithDefault(), and ValueAsUnsignedWithDefault()
2016-08-10 03:27:01 +00:00
Ian Curtis
f4311a0ab2
update visual studio project
2016-07-10 13:11:51 +00:00
Bart Trzynadlowski
52d6eac7e5
Added Util::Config::Node::ValueAsUnsigned() with support for base 10 and 16 ('0x' prefix)
2016-07-10 04:25:41 +00:00
Bart Trzynadlowski
331d7042f2
Added Util::ToLower()
2016-07-10 04:25:12 +00:00
Bart Trzynadlowski
a84aacf80b
Config::Node::Add() now supports nested keys (e.g., Add("foo/bar/baz", "0") will create three nested config nodes)
2016-07-09 15:19:17 +00:00