From e2b4d9b317104ff3c56a9bf108aa79084d49eba5 Mon Sep 17 00:00:00 2001 From: Stephane Marchesin Date: Sun, 5 Nov 2006 13:46:48 +0000 Subject: Architect the DRI : - make use of the autogenerated nouveau_reg.h file - add object creation to the DRI - some work on screen and context creation --- src/mesa/drivers/dri/nouveau/nouveau_context.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'src/mesa/drivers/dri/nouveau/nouveau_context.c') diff --git a/src/mesa/drivers/dri/nouveau/nouveau_context.c b/src/mesa/drivers/dri/nouveau/nouveau_context.c index 4bb4116026..00f0646b1b 100644 --- a/src/mesa/drivers/dri/nouveau/nouveau_context.c +++ b/src/mesa/drivers/dri/nouveau/nouveau_context.c @@ -39,10 +39,11 @@ USE OR OTHER DEALINGS IN THE SOFTWARE. #include "drivers/common/driverfuncs.h" #include "nouveau_context.h" -#include "nouveau_ioctl.h" #include "nouveau_driver.h" //#include "nouveau_state.h" #include "nouveau_span.h" +#include "nouveau_object.h" +#include "nouveau_fifo.h" #include "nouveau_tex.h" #include "nv10_swtcl.h" @@ -77,12 +78,15 @@ GLboolean nouveauCreateContext( const __GLcontextModes *glVisual, if ( !nmesa ) return GL_FALSE; - /* Init default driver functions then plug in our Radeon-specific functions + /* Create the hardware context */ + nouveauFifoInit(nmesa); + nouveauObjectInit(nmesa); + + /* Init default driver functions then plug in our nouveau-specific functions * (the texture functions are especially important) */ _mesa_init_driver_functions( &functions ); nouveauDriverInitFunctions( &functions ); - nouveauIoctlInitFunctions( &functions ); nouveauTexInitFunctions( &functions ); /* Allocate the Mesa context */ @@ -125,7 +129,7 @@ GLboolean nouveauCreateContext( const __GLcontextModes *glVisual, _tnl_CreateContext( ctx ); _swsetup_CreateContext( ctx ); - switch(nmesa->screen->card_type) + switch(nmesa->screen->card->type) { case NV_03: //nv03TriInitFunctions( ctx ); -- cgit v1.2.3