00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00035 #ifndef P_SCREEN_H
00036 #define P_SCREEN_H
00037
00038
00039 #include "pipe/p_compiler.h"
00040 #include "pipe/p_state.h"
00041
00042
00043
00044 #ifdef __cplusplus
00045 extern "C" {
00046 #endif
00047
00048
00049
00055 struct pipe_screen {
00056 struct pipe_winsys *winsys;
00057
00058 void (*destroy)( struct pipe_screen * );
00059
00060
00061 const char *(*get_name)( struct pipe_screen * );
00062
00063 const char *(*get_vendor)( struct pipe_screen * );
00064
00069 int (*get_param)( struct pipe_screen *, int param );
00070
00075 float (*get_paramf)( struct pipe_screen *, int param );
00076
00083 boolean (*is_format_supported)( struct pipe_screen *,
00084 enum pipe_format format,
00085 enum pipe_texture_target target,
00086 unsigned tex_usage,
00087 unsigned geom_flags );
00088
00092 struct pipe_texture * (*texture_create)(struct pipe_screen *,
00093 const struct pipe_texture *templat);
00094
00102 struct pipe_texture * (*texture_blanket)(struct pipe_screen *,
00103 const struct pipe_texture *templat,
00104 const unsigned *pitch,
00105 struct pipe_buffer *buffer);
00106
00107 void (*texture_release)(struct pipe_screen *,
00108 struct pipe_texture **pt);
00109
00111 struct pipe_surface *(*get_tex_surface)(struct pipe_screen *,
00112 struct pipe_texture *texture,
00113 unsigned face, unsigned level,
00114 unsigned zslice,
00115 unsigned usage );
00116
00117
00118
00119 void (*tex_surface_release)( struct pipe_screen *,
00120 struct pipe_surface ** );
00121
00122
00123 void *(*surface_map)( struct pipe_screen *,
00124 struct pipe_surface *surface,
00125 unsigned flags );
00126
00127 void (*surface_unmap)( struct pipe_screen *,
00128 struct pipe_surface *surface );
00129
00130 };
00131
00132
00133 #ifdef __cplusplus
00134 }
00135 #endif
00136
00137 #endif