Commit Graph

39 Commits

Author SHA1 Message Date
Glenn Maynard ce518b6bb2 Allow any image format when creating a texture. 2003-06-30 02:39:56 +00:00
Glenn Maynard 229045627b guh 2003-06-29 08:15:35 +00:00
Glenn Maynard 7951b5f3e7 Add helpers: RageDisplay::CreateSurfaceFromPixfmt, RageDisplay::FindPixelFormat.
UpdateTexture can now take any image format; it doesn't have to match the
original format, or even be a standard pixel format.  This is because we
can often do the conversion much more efficiently within UpdateTexture
than we can in the caller.  With D3D, we can convert any source format
as we copy, preventing an extra blit. OpenGL can do it on the fly if
it happens to be a known texture format.

We can figure out the pixel format from the image itself, so there's
no need to pass pixfmt to UpdateTexture.

Add BGR8, for movies with OpenGL.
2003-06-29 08:13:18 +00:00
Glenn Maynard 55705d34d7 don't mess with texture parameters when updating 2003-06-28 02:27:04 +00:00
Glenn Maynard 4f2d551e90 bring RageDisplay_OGL::CreateTexture and UpdateTexture closer
together
2003-06-28 02:23:35 +00:00
Glenn Maynard 7f5b42cc9d cleanup 2003-06-28 02:19:31 +00:00
Glenn Maynard 3a9205e1d2 move prototype 2003-06-28 02:03:26 +00:00
Glenn Maynard 06207a0171 Clean up endianness mess. 2003-06-28 01:45:44 +00:00
Glenn Maynard 537ae7e991 fix index 2003-06-27 02:11:13 +00:00
Glenn Maynard 2206e32cef Simplify exception handling. Improve fallback if we can't set up an
OpenGL window.
2003-06-25 20:44:49 +00:00
Glenn Maynard c8e02ec0ae cosmetic 2003-06-22 01:53:04 +00:00
Glenn Maynard 2d97a1daa0 add GetTextureDiagnostics (not used yet) 2003-06-22 01:20:58 +00:00
Glenn Maynard 2eef2635b0 also unneeded 2003-06-21 22:39:03 +00:00
Glenn Maynard ca039d1aae unneeded 2003-06-21 22:37:59 +00:00
Steve Checkoway 77cfa7b87a Use local-endian screenshots. (This didn't just switch it for everybody screwing up little-endian machines did it?) 2003-06-18 09:56:46 +00:00
Glenn Maynard 2937cc73c7 fix more GL_NO_ERROR problems 2003-06-12 19:40:44 +00:00
Glenn Maynard bfcb68fd2b fix/simplify 2003-06-11 01:22:14 +00:00
Glenn Maynard b7eebb5df5 Add some code to try to fix texture masks on big endian machines. 2003-06-11 01:19:02 +00:00
Chris Danford bf77ee902f fix DrawIndexedTriangles bug that caused uninited verticies to be drawn 2003-06-07 11:54:44 +00:00
Chris Danford 428d560a6b Clean up resolution fallback logic
Add video settings for G400
Working on composited text
2003-06-05 19:29:27 +00:00
Glenn Maynard 4486bd1754 Oops. Fix a silly bug on systems without paletted textures.
Fix assert failure.
2003-05-31 09:10:18 +00:00
Chris Danford d0b9a755cd fix logging crash (only showed up in release builds run under Win98) 2003-05-30 23:15:53 +00:00
Glenn Maynard 9354eb8e5b Move tables to the top.
Add a paletted texture test; hopefully this will prevent it from happening
later, where it's inconvenient.
2003-05-30 20:16:30 +00:00
Glenn Maynard c3c96f390c grumble 2003-05-27 08:39:36 +00:00
Glenn Maynard 2c06e0b8d6 no, really, normals are normals 2003-05-27 08:39:35 +00:00
Glenn Maynard 726d79ecf8 (l+r)/(l-r) == -(r+l)/(r-l) 2003-05-27 08:39:34 +00:00
Chris Danford 9b82e59ad2 fix wrong glNormalPointer 2003-05-27 07:05:32 +00:00
Glenn Maynard ea330f17ad fix normals 2003-05-27 05:26:53 +00:00
Glenn Maynard 2e96c4785e log current renderer 2003-05-27 00:48:40 +00:00
Glenn Maynard a9fa113a0f Link to OpenGL in the OGL renderer. We don't use glu anymore. 2003-05-27 00:25:46 +00:00
Glenn Maynard 3e1707e641 Consolidate poly line code, so it can be used with both renderers. Use it
with D3D instead of hardware lines.
2003-05-27 00:20:54 +00:00
Glenn Maynard c6dcd8c489 GLDirect hacks should become irrelevant now 2003-05-26 21:02:49 +00:00
Glenn Maynard 2ddc78909a Combine binaries, so we can choose the renderer. No actual selection
yet; change CreateDisplay if you want to do that for the next few hours.
2003-05-26 19:42:04 +00:00
Glenn Maynard 56b79a197d Make pixel format querying a member (massaging for merge).
Remove a function from the header.
2003-05-26 03:12:12 +00:00
Chris Danford 6b63ef50f9 support theme-specific program icon and window title (useful for non-SM products) 2003-05-25 20:19:01 +00:00
Chris Danford a75cd6e7b1 Fix D3D z-buffer problem by having separate GetOrthoMatrix functions for OGL and D3D.
I don't understand why the two APIs create an ortho matrix so differently, but I'm tried of messing with it for now.
2003-05-25 00:43:44 +00:00
Chris Danford 7f3b7b9162 reacquire D3D device when lost in full screen (user alt+tabs out) 2003-05-24 05:44:31 +00:00
Glenn Maynard 84bcc3146a fix latent viewport bug 2003-05-22 08:37:15 +00:00
Chris Danford 02016ae442 Reorganize RageDisplay
Add Direct3D renderer (separate project configuration)
Add Xbox project config (doesn't yet compile)
2003-05-22 05:28:37 +00:00