added shared_info flag to inform 3D add-on to reload it's rendering state, further improving 3D rendering speed: Quake2 is at 105fps (GF4MX440, 640x480x16), Teapot renders at close to 500fps now. Bumped version to 0.52.
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@13169 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
5d914f565f
commit
b7c592306b
@ -4,7 +4,7 @@
|
||||
|
||||
Other authors:
|
||||
Mark Watson,
|
||||
Rudolf Cornelissen 10/2002-5/2005.
|
||||
Rudolf Cornelissen 10/2002-6/2005.
|
||||
*/
|
||||
|
||||
#define MODULE_BIT 0x00800000
|
||||
@ -161,6 +161,8 @@ status_t INIT_ACCELERANT(int the_fd) {
|
||||
|
||||
/* count of issued parameters or commands */
|
||||
si->engine.last_idle = si->engine.count = 0;
|
||||
/* tell a 3D add-on that it should reload it's state */
|
||||
si->engine.reload_state_3D = true;
|
||||
INIT_BEN(si->engine.lock);
|
||||
|
||||
INIT_BEN(si->overlay.lock);
|
||||
@ -170,6 +172,7 @@ status_t INIT_ACCELERANT(int the_fd) {
|
||||
si->overlay.myBuffer[cnt].buffer = NULL;
|
||||
si->overlay.myBuffer[cnt].buffer_dma = NULL;
|
||||
}
|
||||
|
||||
/* make sure overlay unit is 'marked' as being free */
|
||||
si->overlay.myToken = NULL;
|
||||
|
||||
|
@ -1500,13 +1500,6 @@ static void nv_acc_set_ch_dma(uint16 ch, uint32 handle)
|
||||
si->engine.dma.free -= 2;
|
||||
}
|
||||
|
||||
/* fixme? (check this out..)
|
||||
* Looks like this stuff can be very much simplified and speed-up, as it seems it's not
|
||||
* nessesary to wait for the engine to become idle before re-assigning channels.
|
||||
* Because the cmd handles are actually programmed _inside_ the fifo channels, it might
|
||||
* well be that the assignment is buffered along with the commands that still have to
|
||||
* be executed!
|
||||
* (sounds very plausible to me :) */
|
||||
void nv_acc_assert_fifo_dma(void)
|
||||
{
|
||||
/* does every engine cmd this accelerant needs have a FIFO channel? */
|
||||
@ -1520,9 +1513,6 @@ void nv_acc_assert_fifo_dma(void)
|
||||
{
|
||||
uint16 cnt;
|
||||
|
||||
/* no, wait until the engine is idle before re-assigning the FIFO */
|
||||
nv_acc_wait_idle_dma();
|
||||
|
||||
/* free the FIFO channels we want from the currently assigned cmd's */
|
||||
si->engine.fifo.ch_ptr[si->engine.fifo.handle[0]] = 0;
|
||||
si->engine.fifo.ch_ptr[si->engine.fifo.handle[1]] = 0;
|
||||
@ -1568,6 +1558,9 @@ void nv_acc_assert_fifo_dma(void)
|
||||
/* tell the engine to fetch and execute all (new) commands in the DMA buffer */
|
||||
nv_start_dma();
|
||||
}
|
||||
|
||||
/* the 3D add-on needs to reload the rendering state: issuing 2D cmds kills it! */
|
||||
si->engine.reload_state_3D = true;
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -90,7 +90,7 @@ status_t nv_general_powerup()
|
||||
{
|
||||
status_t status;
|
||||
|
||||
LOG(1,("POWERUP: Haiku nVidia Accelerant 0.51 running.\n"));
|
||||
LOG(1,("POWERUP: Haiku nVidia Accelerant 0.52 running.\n"));
|
||||
|
||||
/* preset no laptop */
|
||||
si->ps.laptop = false;
|
||||
|
Loading…
Reference in New Issue
Block a user