Author: dukeeeey | Date: 5 listopada 2017 14:25:33
- Update step 1.5 luminous logic with Harry's findings. Fixes various shading issues.
Author: dukeeeey | Date: 19 października 2017 22:48:53
- Finish the hash function (Harry Tuttle)
Author: dukeeeey | Date: 7 października 2017 14:39:30
- Remove fixed shading check from specular.
Author: trzy | Date: 6 października 2017 03:04:49
- Makefile fixes: Moved Windows-specific source files out of Makefile.inc, using 'bin' and 'obj' when bits are not explicitly set, and changed output file to Supermodel rather than Supermodel.exe, which works on all platforms.
Author: dukeeeey | Date: 5 października 2017 21:15:00
- Star wars is the only game to pass unsigned fixed shaded values (per vertex brightness) to the renderer. Originally we thought that the specular flag would turn on unsigned values since it's the only game to set specular with these polys, but this logic turned out to be incorrect. The JTAG interface seems to config the GPU to turn on this functionality. (Harry Tuttle)
Author: dukeeeey | Date: 5 października 2017 20:54:36
- update visual studio project
Author: dukeeeey | Date: 5 października 2017 20:49:08
- update spotlight code (Harry Tuttle)
Author: trzy | Date: 5 października 2017 04:17:48
- Harry's patch: add dirtdvlsj and change "Star Wars Trilogy" to "Star Wars Trilogy Arcade"
Author: trzy | Date: 5 października 2017 04:14:02
- New, saner Makefiles. They still require some customization but share a core Makefile include with auto-generation of dependencies. Multi-threaded building (e.g., make -j6) is supported now.
Author: dukeeeey | Date: 30 września 2017 21:05:04
Author: trzy | Date: 27 września 2017 15:20:09
- Get rid of unused variable warning
Author: dukeeeey | Date: 26 września 2017 02:30:08
- Fix the sky in one of the levels in virtua on. The problem was caused by the fact we didn't split the mesh by the fog % burn through, so all the polys had the same value. We could use a vertex attrib, but % burn through fog is so rarely used and when it is, normally every poly in the mesh has the same value.
Author: trzy | Date: 25 września 2017 02:05:10
Author: dukeeeey | Date: 25 września 2017 00:49:20
Author: dukeeeey | Date: 25 września 2017 00:39:53
Author: dukeeeey | Date: 25 września 2017 00:36:12
- work around for visual studio bug
Author: dukeeeey | Date: 25 września 2017 00:14:39
Author: dukeeeey | Date: 25 września 2017 00:03:31
- cannot specify explicit initializer for arrays - fix for visual studio
Author: trzy | Date: 24 września 2017 22:52:48
- New work-in-progress frame timing code (disabled by default, compile with NEW_FRAME_TIMING defined to activate it)
- New JTAG emulation, moved into its own class, CJTAG
- Removed game-specific sun clamp hacks from CNew3D (JTAG and Real3D emulation will call the appropriate method to configure this at run-time)
- Removed JTAG from Real3D save state data and reused some of that space for new state variables having to do with the internal JTAG-based config as well as new frame timing state variables
Author: trzy | Date: 24 września 2017 22:49:31
- Added functions to safely read and write bools
Author: trzy | Date: 24 września 2017 20:40:58
- Added functions to extract bits as integer values and updated comment about bit vector layout
Author: trzy | Date: 23 września 2017 18:08:27
- Added SetOnes() and SetZeros()
Author: trzy | Date: 23 września 2017 17:40:20
- Safe guard against shifting empty register.
Author: trzy | Date: 23 września 2017 17:33:26
- Hex formatting support extended to 64 bits.
Author: trzy | Date: 23 września 2017 17:03:06
- Added ShiftOutLeft() and ShiftOutRight()
Author: trzy | Date: 23 września 2017 16:42:05
- Renamed shift in/out functions to add/remove to be less ambiguous about their functionality
Author: trzy | Date: 19 września 2017 21:43:06
- Added ToHexString() and made ostream serialization use this
Author: trzy | Date: 18 września 2017 06:24:23
- Fix for VS2015 and newer by MetalliC
Author: trzy | Date: 7 września 2017 21:33:25
- Added BitRegister class (for use in upcoming JTAG refactor): an inefficient but flexible container for manipulating a dynamic bit stream.
Author: dukeeeey | Date: 6 września 2017 15:07:39
- Calculating the length of the vertex results in quite broken values for fogging when the vertices are traversing the view frustum. The hardware also wouldn't have been doing a square root per vertex for fogging. Simply using the z values is enough. Todo check clamping of values for the near/far planes.
Author: dukeeeey | Date: 2 września 2017 16:54:16
- add interface for sun clamp
Author: dukeeeey | Date: 30 sierpnia 2017 23:45:25
- Optimise vertex data to cut down on unnecessary copying
Author: dukeeeey | Date: 29 sierpnia 2017 12:27:29
- Modern hardware does backface culling in window space by calculating the face normal for the polygon, then doing a dot product against the view vector. The real3d pro-1000 on the other hand passes a pre-calculated face normal for each polygon which is used for culling. We were using this face normal to rewind the polygons so that regular backface culling would work. This worked 99.9% of the time. However this was failing on some models in Virtua Striker. The reason was because the pre-calculated face normals being passed were actually completely different to the actual face normals for the poly (not just inverted like you would expect). This broke our code. The solution was to emulate face culling directly in the vertex shader using the pre-calculated face normals directly. Only minimally tested this but hopefully there are no obvious regressions.
Author: trzy | Date: 29 sierpnia 2017 03:28:21
- DMA and register space access for Real3D have been unified and CReal3D::ReadRegister() returns little endian data now that the PowerPC handler byte-swaps back, to be consistent with how DMA registers work.
Author: dukeeeey | Date: 26 sierpnia 2017 00:40:39
- Changed fixed shaded logic for step 1.5 hw based upon Harry's findings
Author: dukeeeey | Date: 22 sierpnia 2017 01:00:29
Author: dukeeeey | Date: 19 sierpnia 2017 22:06:31
- Harry made some important discoveries with regards to fixed shading on the model 3 (per vertex poly brightness values). Firstly values are allowed to be negative, and they are used as a drop in replacement in the standard lighting equation for the normal dot light vector. This quite radically changes the brightness in LA Machine guns, but now correctly matches the arcade.
Author: trzy | Date: 19 sierpnia 2017 21:29:05
- Patched Sega Rally 2 DX to boot up. Enjoy Sega Rall 2 without MPEG music at 50% speed ;)
Author: trzy | Date: 19 sierpnia 2017 21:27:58
- Fixed up memory region dumping code to use the new Util::FlipEndian functions
Author: trzy | Date: 16 sierpnia 2017 02:58:39
- Fixed a bug in MCRFS instruction related to the VXSOFT, VXSQRT, and VXCVI bits. Thanks to Spindizzi.
Author: dukeeeey | Date: 16 sierpnia 2017 01:21:57
- Finish fixed shading for 2.0 hardware. I'm pretty sure it actually works identically to step 1.5 hardware. The oddball is LA machine guns where the viewport ambient doesn't seem to effect the brightness. But the ambient works differently in this game because it uses the unclamped light model. Still need to investigate if the diffuse factor effects fixed shading.
Author: dukeeeey | Date: 15 sierpnia 2017 22:50:36
- With fixed shading, when lighting is disabled, fixed shading appears to be a flat shaded version based upon the poly colour, instead of per vertex attributes.
Author: dukeeeey | Date: 15 sierpnia 2017 22:45:08
- Pad struct and align on 4 byte boundary.
Author: dukeeeey | Date: 15 sierpnia 2017 01:30:34
Author: dukeeeey | Date: 14 sierpnia 2017 18:10:26
- fixed shading doesn't effect the alpha channel
Author: dukeeeey | Date: 14 sierpnia 2017 11:14:06
- Fixed shading (per vertex poly colours) on step 1.5 hardware have the viewport ambient value added to them. This fixes various shading on scud. To do this had to switch the maths to the vertex shader.
Author: dukeeeey | Date: 11 sierpnia 2017 13:59:41
- Fix attribute locations. glBindAttribLocation must be called linking
Author: trzy | Date: 11 sierpnia 2017 02:41:10
- Added support for loading shaders from files for new engine and tile renderer. Changed help text to reflect new engine being default.
Author: dukeeeey | Date: 10 sierpnia 2017 17:59:16
- make the new3d engine default :] Legacy engine can still be selected using -legacy3d in the command line
Author: dukeeeey | Date: 10 sierpnia 2017 17:43:03
- use generic vertex attributes
Author: dukeeeey | Date: 10 sierpnia 2017 01:25:01
- Technically matrix casts are only allowed in glsl 1.2 and later
Author: dukeeeey | Date: 9 sierpnia 2017 23:40:48
Author: dukeeeey | Date: 9 sierpnia 2017 18:56:56
- Sometime ago I managed to work out that specular on the model3 is not real specular, and really is just an extension of diffuse lighting. But attempts were derailed by corner cases and the fact we were not handling the normals correctly. Anyway Harry managed to successfully come up with an algorithm, and coefficients that give an almost perfect match to specular on the model3, based soley on observations from video footage! He also worked out that the lighting on hardware 1.5 onwards appears to be unclamped (ie greater than 1). This quite radically changes the brightness of some of the games, but much better matches the original hardware.
Author: dukeeeey | Date: 3 sierpnia 2017 13:05:04
Author: dukeeeey | Date: 3 sierpnia 2017 12:41:18
- Add the unclamped light model we know exists to the shaders.
Author: dukeeeey | Date: 2 sierpnia 2017 01:48:53
- Ski champ for some reason is passing denormalised numbers for the modelscale. This is causing a NaN in our shader killing the lighting for these models, so we simply skip these, since they are essentially zero anyway. Thanks to Harry for finding this bug :)
Author: dukeeeey | Date: 29 lipca 2017 18:30:30
- We were force normalising the result of matrix * normal, which looked correct in most cases. But this didn't preserve the scaling of the matrix, or the scaling of the model normals which resulted in many over bright areas. On it's own this generally worked, but games like Star Wars looked quite broken. Harry correctly figured out if you scale these normals by the scaling value that is sometimes present in the culling nodes the lighting looks correct. Still more work to do to correctly figure out the model3's lighting model.
Author: dukeeeey | Date: 22 lipca 2017 19:15:14
- Implement unclamped light model based upon Harry's findings. Unknown how this is turned on/off.
Author: dukeeeey | Date: 8 lipca 2017 12:55:14
- Use c++11 raw string literals