Commit graph

128 commits

Author SHA1 Message Date
Bart Trzynadlowski 453df4f5f5 - Finished cleaning up and optimizing the 2D renderer.
- Fixed up color offset register support for new 2D rendering system. Now maintains 2 computed palettes for layers A/A' and B/B'.
- Fixed a minor bug in InitPalette(); VRAM was not being typecast properly.
- Fixed specular lighting bug that occurred on some OpenGL drivers because integers were not being interpreted as floats in the vertex shader.
- Began to update copyright date in some files.
- Graphics modules now use the C++-style names for C standard library headers (e.g., stdio.h -> cstdio) consistent with the rest of Supermodel.
2012-02-20 03:45:48 +00:00
Bart Trzynadlowski 0257f1f9e8 Contour processing (discarding of pixels when alpha==0) enabled for A4L4 texture formats. Improves smoke and fire in Daytona 2. 2012-02-17 07:45:50 +00:00
Bart Trzynadlowski 79d24d403f - NOTE: In this revision (possibly earlier), I've started to notice some intermittent geometry glitches in Spikeout and slowdown while playing certain characters.
- Added multi-texture fragment shader to repo.
- Added a multiTexture option (enabled by default) to use multi-texturing to decode textures.
- Added some comments regarding timing to the PowerPC execution loop.
2012-02-14 03:28:52 +00:00
Nik Henson 30130f2bd5 Updated fragment shaders' floating point comparisons and also some knock-on changes from SVN revision 246. 2012-02-13 23:51:32 +00:00
Nik Henson 84eb017744 Added support for multiple texture sheets (with up to one per Model 3 texture format) as a rather brute-force way to handle overlapping texture formats in the current 3D engine. This fixes some corrupt textures in Daytona 2 and Virtua Striker 2 (and possibly other games) and also offers a small speed increase when some scenes load multiple overlapping textures.
This feature only enables itself when a compatible shader script is loaded.  Since none have been checked in yet this means it is currently disabled.
2012-02-13 21:54:26 +00:00
Bart Trzynadlowski 1b8740165c Added a wide screen hack that can be enabled with the -'wide-screen' argument or WideScreen in the config file. 2012-02-10 19:53:51 +00:00
Bart Trzynadlowski 6814ef1ed8 Added preliminary specular lighting to shaders. The "no spotlight" shader has not yet been updated. 2012-02-06 02:54:43 +00:00
Bart Trzynadlowski 0fcb9686f9 Documented the tile generator. 2012-01-27 22:27:38 +00:00
Bart Trzynadlowski 8a8609f383 - Added specular highlight support to the 3D engine. A shininess parameter is now be passed to the shaders. Does not work correctly and I will save the shaders themselves for a future commit.
- Added support for layer priorities. Highly unoptimal! This absolutely needs to be polished up before any release (and properly documented). For now, priorities in the popular games seem to be fixed but not all possible priority settings have been figured out yet.
2012-01-27 05:52:59 +00:00
Bart Trzynadlowski c38ec7d5af Removed unused dirty rectangle code. 2012-01-26 02:57:02 +00:00
Bart Trzynadlowski e00a372cef Removed unused dirty rectangle code. 2012-01-26 02:49:07 +00:00
Bart Trzynadlowski b7980aa562 Removed unused dirty rectangle code. 2012-01-26 02:48:16 +00:00
Bart Trzynadlowski 3315fb463b Small correction to lighting model in shaders. Light intensity is no longer clipped. 2012-01-22 01:05:59 +00:00
Bart Trzynadlowski b57ba51e44 Removed unused (and non-functional) 'stack machine' scene graph traversal. 2012-01-18 08:12:23 +00:00
Nik Henson d1d5175548 New multi-threaded rendering changes that parallelise graphics rendering and PPC execution in order to increase performance on multi-core machines.
New gpuMultiThreaded config option to enable/disable multi-threaded rendering (enabled by default, disabling it reverts to previous behaviour).
Other rendering optimisations:
 - texture uploads now only affect appropriate region in the texture sheet, rather than uploading the whole sheet each time
 - performance of clearing the model caches has been improved
New Alt+O key input added to toggle outputting of frame timings for debugging purposes.
2012-01-16 23:21:14 +00:00
Bart Trzynadlowski bdf11c765f Preliminary backface culling fix. Matrices which effectively change the polygon winding without changing the Z component of the polygon normal are tested for when appending items to the display list. If necessary, the polygon winding is changed on the fly to ensure visibility is correct. This code desperately needs to be optimized. Note: Not yet thoroughly tested. 2011-12-26 06:10:55 +00:00
Bart Trzynadlowski 7f97346fc9 - Tweaked some error messages and comments. Hopefully, this is the last update for v0.2a's code.
- Documentation updates.
2011-09-24 01:49:48 +00:00
Bart Trzynadlowski 2f5bf43bda Updated copyright information and added headers to all remaining files except debugger. 2011-09-14 19:08:43 +00:00
Bart Trzynadlowski 11d1d61bc2 - Removed BOOL and replaced it with native C++ type, bool.
- Removed TRUE and FALSE, changed to 'true' and 'false' keywords.
2011-09-08 06:34:18 +00:00
Bart Trzynadlowski d318efe58c - Program settings are now managed by the CConfig class.
- Moved Logger.h to OSD/, cleaned up comments.
- Command line and config file parsing have been rewritten.
- Began replacing C standard library headers with C++ versions (eg. stdio.h -> cstdio). I think I got most of them, but not all.
2011-08-19 20:43:07 +00:00
Bart Trzynadlowski fce3c7ad7c - skichamp now works, but controls are not hooked up and seems to overload the display lists like many non-working Step 2.x games do. To bypass the drive board error, enter the test menu and exit again. It will reboot and run.
- Added some notes on the cause of the "NO DAUGHTER BOARD DETECTED" error in Real3D.cpp.
- Removed some debug code from texture uploader.
2011-08-02 03:33:40 +00:00
Bart Trzynadlowski ddd6fa92ef - Improved 68K interface. Now supports context switching.
- CSoundBoard is not derived from CBus.
- Optimized sound board memory handlers (now using switch statements).
- Added DSB emulation (based on R. Belmont's M1 source code).
- Improved ROM loading: only unique ROMs (those not shared amongst games) are used to identify games. The ROM loader will no longer get confused as easily.
- General cleanup here and there, removed unused Render.h file.
2011-07-31 02:37:31 +00:00
Bart Trzynadlowski 79e8172340 - Textures are no longer decoded for un-textured polygons (not sure if this fixes anything yet). 2011-07-22 19:01:45 +00:00
Bart Trzynadlowski d2ecec7997 - Textures are no longer decoded for un-textured polygons (not sure if this fixes anything yet). 2011-07-22 18:56:35 +00:00
Bart Trzynadlowski a033058deb - Texture offsets: models are now decoded for each individual texture offset state and texture coordinates are adjusted while generating the vertex data.
- Model LUT now capable of differentiating between texture offset states (linked list of different texture offsets for each model address).
- Removed texOffset uniform attribute from vertex shader -- no longer needed.
2011-07-21 08:12:16 +00:00
Bart Trzynadlowski a90075830c Texture offsets. 2011-07-06 05:05:38 +00:00
Bart Trzynadlowski cd2621b2ce Added texture offsets. Vertex shader has been updated in Shaders/Vertex.glsl.
Added palette initialization to 2D renderer. Fixes 2D graphics corruption when loading states (most visible in Scud Race).
2011-07-04 20:53:37 +00:00
Bart Trzynadlowski 783446fca2 Fixing import mistake: moving source code to trunk/Src. 2011-04-24 01:19:40 +00:00