Lines Matching refs:pt

168    const struct pipe_resource *pt = &mt->base.base;
169 const unsigned blocksize = util_format_get_blocksize(pt->format);
171 assert(pt->last_level == 0);
173 assert(!util_format_is_compressed(pt->format));
175 mt->layout_3d = pt->target == PIPE_TEXTURE_3D;
178 mt->level[0].pitch = align(pt->width0 * blocksize, 64);
179 mt->total_size = align(pt->height0, 16) * mt->level[0].pitch * (mt->layout_3d ? pt->depth0 : 1);
181 if (pt->array_size > 1) {
183 mt->total_size = mt->layer_stride * pt->array_size;
190 struct pipe_resource *pt = &mt->base.base;
192 const unsigned blocksize = util_format_get_blocksize(pt->format);
194 mt->layout_3d = pt->target == PIPE_TEXTURE_3D;
196 w = pt->width0 << mt->ms_x;
197 h = pt->height0 << mt->ms_y;
202 d = mt->layout_3d ? pt->depth0 : 1;
204 assert(!mt->ms_mode || !pt->last_level);
206 for (l = 0; l <= pt->last_level; ++l) {
209 unsigned nbx = util_format_get_nblocksx(pt->format, w);
210 unsigned nby = util_format_get_nblocksy(pt->format, h);
229 if (pt->array_size > 1) {
232 mt->total_size = mt->layer_stride * pt->array_size;
252 struct pipe_resource *pt = &mt->base.base;
262 *pt = *templ;
263 pipe_reference_init(&pt->reference, 1);
264 pt->screen = pscreen;
266 if (pt->usage == PIPE_USAGE_STAGING) {
267 switch (pt->target) {
270 if (pt->last_level == 0 &&
271 !util_format_is_depth_or_stencil(pt->format) &&
272 pt->nr_samples <= 1)
273 pt->flags |= NOUVEAU_RESOURCE_FLAG_LINEAR;
280 if (pt->bind & PIPE_BIND_LINEAR)
281 pt->flags |= NOUVEAU_RESOURCE_FLAG_LINEAR;
290 if (unlikely(pt->flags & NVC0_RESOURCE_FLAG_VIDEO)) {
302 if (!bo_config.nvc0.memtype && (pt->usage == PIPE_USAGE_STAGING || pt->bind & PIPE_BIND_SHARED))
324 return pt;
331 const struct pipe_resource *pt = &mt->base.base;
336 unsigned nby = util_format_get_nblocksy(pt->format,
337 u_minify(pt->height0, l));
353 struct pipe_resource *pt,
356 struct nv50_surface *ns = nv50_surface_from_miptree(nv50_miptree(pt), templ);