aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/llvmpipe/lp_setup.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-12-04 12:54:37 -0700
committerBrian Paul <[email protected]>2009-12-04 12:54:37 -0700
commitd9dc3d59760a28d54013d3d164f61d85ec807651 (patch)
treef38160fdc5d3b231d767c1798c91b5f9c2e565b0 /src/gallium/drivers/llvmpipe/lp_setup.c
parent5c7d1b592ad9ce9e7ee36610f17d41e5c2881d54 (diff)
llvmpipe: move bin-related structures and functions into new lp_bin.[ch]
And put lp_ prefixes on some functions.
Diffstat (limited to 'src/gallium/drivers/llvmpipe/lp_setup.c')
-rw-r--r--src/gallium/drivers/llvmpipe/lp_setup.c27
1 files changed, 5 insertions, 22 deletions
diff --git a/src/gallium/drivers/llvmpipe/lp_setup.c b/src/gallium/drivers/llvmpipe/lp_setup.c
index 11a9fd2637c..6136d1b57e3 100644
--- a/src/gallium/drivers/llvmpipe/lp_setup.c
+++ b/src/gallium/drivers/llvmpipe/lp_setup.c
@@ -46,23 +46,6 @@
static void set_state( struct setup_context *, unsigned );
-void lp_setup_new_cmd_block( struct cmd_block_list *list )
-{
- struct cmd_block *block = MALLOC_STRUCT(cmd_block);
- list->tail->next = block;
- list->tail = block;
- block->next = NULL;
- block->count = 0;
-}
-
-void lp_setup_new_data_block( struct data_block_list *list )
-{
- struct data_block *block = MALLOC_STRUCT(data_block);
- list->tail->next = block;
- list->tail = block;
- block->next = NULL;
- block->used = 0;
-}
static void
@@ -194,7 +177,7 @@ static void bin_everywhere( struct setup_context *setup,
unsigned i, j;
for (i = 0; i < setup->tiles_x; i++)
for (j = 0; j < setup->tiles_y; j++)
- bin_command( &setup->tile[i][j], cmd, arg );
+ lp_bin_command( &setup->tile[i][j], cmd, arg );
}
@@ -217,7 +200,7 @@ bin_state_command( struct setup_context *setup,
lp_replace_last_command_arg(bin, arg);
}
else {
- bin_command( bin, cmd, arg );
+ lp_bin_command( bin, cmd, arg );
}
}
}
@@ -594,7 +577,7 @@ lp_setup_update_shader_state( struct setup_context *setup )
uint8_t *stored;
unsigned i, j;
- stored = get_data_aligned(&setup->data, 4 * 16, 16);
+ stored = lp_bin_alloc_aligned(&setup->data, 4 * 16, 16);
/* smear each blend color component across 16 ubyte elements */
for (i = 0; i < 4; ++i) {
@@ -626,7 +609,7 @@ lp_setup_update_shader_state( struct setup_context *setup )
current_size) != 0) {
void *stored;
- stored = get_data(&setup->data, current_size);
+ stored = lp_bin_alloc(&setup->data, current_size);
if(stored) {
memcpy(stored,
current_data,
@@ -656,7 +639,7 @@ lp_setup_update_shader_state( struct setup_context *setup )
* and append it to the bin's setup data buffer.
*/
struct lp_rast_state *stored =
- (struct lp_rast_state *) get_data(&setup->data, sizeof *stored);
+ (struct lp_rast_state *) lp_bin_alloc(&setup->data, sizeof *stored);
if(stored) {
memcpy(stored,
&setup->fs.current,