diff options
author | Ben Skeggs <[email protected]> | 2009-06-04 10:19:04 +1000 |
---|---|---|
committer | Ben Skeggs <[email protected]> | 2009-06-05 14:37:01 +1000 |
commit | bc466be695913cd504cefddd857ac1cefda87a04 (patch) | |
tree | ffdf780ad66bd774d80205478131fc60eed13c05 /src/gallium/drivers/nouveau/nouveau_screen.h | |
parent | 072fdc1fd325256d87b182d4f55c8a5838119cf0 (diff) |
nouveau: add pipe_buffer/fence code to pipe drivers, move nv50 over
Diffstat (limited to 'src/gallium/drivers/nouveau/nouveau_screen.h')
-rw-r--r-- | src/gallium/drivers/nouveau/nouveau_screen.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/gallium/drivers/nouveau/nouveau_screen.h b/src/gallium/drivers/nouveau/nouveau_screen.h new file mode 100644 index 00000000000..cffba11762d --- /dev/null +++ b/src/gallium/drivers/nouveau/nouveau_screen.h @@ -0,0 +1,24 @@ +#ifndef __NOUVEAU_SCREEN_H__ +#define __NOUVEAU_SCREEN_H__ + +struct nouveau_screen { + struct pipe_screen base; + struct nouveau_device *device; +}; + +static inline struct nouveau_screen * +nouveau_screen(struct pipe_screen *pscreen) +{ + return (struct nouveau_screen *)pscreen; +} + +static inline struct nouveau_bo * +nouveau_bo(struct pipe_buffer *pb) +{ + return pb ? *(struct nouveau_bo **)(pb + 1) : NULL; +} + +int nouveau_screen_init(struct nouveau_screen *, struct nouveau_device *); +void nouveau_screen_fini(struct nouveau_screen *); + +#endif |