Lines Matching refs:base
44 if (unlikely(mt->base.base.flags & NOUVEAU_RESOURCE_FLAG_LINEAR)) in nv50_mt_choose_storage_type()
46 if (unlikely(mt->base.base.bind & PIPE_BIND_CURSOR)) in nv50_mt_choose_storage_type()
49 switch (mt->base.base.format) { in nv50_mt_choose_storage_type()
67 switch (util_format_get_blocksizebits(mt->base.base.format)) { in nv50_mt_choose_storage_type()
82 if (mt->base.base.bind & PIPE_BIND_SCANOUT) { in nv50_mt_choose_storage_type()
102 if (mt->base.base.bind & PIPE_BIND_CURSOR) in nv50_mt_choose_storage_type()
117 nouveau_bo_ref(NULL, &mt->base.bo); in nv50_miptree_destroy()
119 nouveau_fence_ref(NULL, &mt->base.fence); in nv50_miptree_destroy()
120 nouveau_fence_ref(NULL, &mt->base.fence_wr); in nv50_miptree_destroy()
133 if (!mt || !mt->base.bo) in nv50_miptree_get_handle()
139 mt->base.bo, in nv50_miptree_get_handle()
159 switch (mt->base.base.nr_samples) { in nv50_miptree_init_ms_mode()
179 NOUVEAU_ERR("invalid nr_samples: %u\n", mt->base.base.nr_samples); in nv50_miptree_init_ms_mode()
188 struct pipe_resource *pt = &mt->base.base; in nv50_miptree_init_layout_linear()
209 struct pipe_resource *pt = &mt->base.base; in nv50_miptree_init_layout_tiled()
259 struct pipe_resource *pt = &mt->base.base; in nv50_miptree_create()
267 mt->base.vtbl = &nv50_miptree_vtbl; in nv50_miptree_create()
289 if (mt->base.base.bind & (PIPE_BIND_CURSOR | PIPE_BIND_DISPLAY_TARGET)) in nv50_miptree_create()
293 &mt->base.bo); in nv50_miptree_create()
298 mt->base.domain = NOUVEAU_BO_VRAM; in nv50_miptree_create()
299 mt->base.address = mt->base.bo->offset; in nv50_miptree_create()
324 mt->base.bo = nouveau_screen_bo_from_handle(pscreen, whandle, &stride); in nv50_miptree_from_handle()
325 if (mt->base.bo == NULL) { in nv50_miptree_from_handle()
329 mt->base.domain = NOUVEAU_BO_VRAM; in nv50_miptree_from_handle()
330 mt->base.address = mt->base.bo->offset; in nv50_miptree_from_handle()
332 mt->base.base = *templ; in nv50_miptree_from_handle()
333 mt->base.vtbl = &nv50_miptree_vtbl; in nv50_miptree_from_handle()
334 pipe_reference_init(&mt->base.base.reference, 1); in nv50_miptree_from_handle()
335 mt->base.base.screen = pscreen; in nv50_miptree_from_handle()
338 mt->level[0].tile_mode = mt->base.bo->config.nv50.tile_mode; in nv50_miptree_from_handle()
341 return &mt->base.base; in nv50_miptree_from_handle()
349 const struct pipe_resource *pt = &mt->base.base; in nv50_mt_zslice_offset()
377 ps = &ns->base; in nv50_surface_from_miptree()
380 pipe_resource_reference(&ps->texture, &mt->base.base); in nv50_surface_from_miptree()
388 ns->width = u_minify(mt->base.base.width0, ps->u.tex.level); in nv50_surface_from_miptree()
389 ns->height = u_minify(mt->base.base.height0, ps->u.tex.level); in nv50_surface_from_miptree()
412 ns->base.context = pipe; in nv50_miptree_surface_new()
414 if (ns->base.u.tex.first_layer) { in nv50_miptree_surface_new()
415 const unsigned l = ns->base.u.tex.level; in nv50_miptree_surface_new()
416 const unsigned z = ns->base.u.tex.first_layer; in nv50_miptree_surface_new()
430 return &ns->base; in nv50_miptree_surface_new()