Lines Matching refs:caps

71    if (vscreen->caps.caps.v2.host_feature_check_version >= 5)
72 return vscreen->caps.caps.v2.renderer;
88 return vscreen->caps.caps.v2.max_anisotropy > 1.0;
92 return vscreen->caps.caps.v1.max_render_targets;
94 return vscreen->caps.caps.v1.max_dual_source_render_targets;
96 return vscreen->caps.caps.v1.bset.occlusion_query;
99 return vscreen->caps.caps.v1.bset.mirror_clamp;
103 if (vscreen->caps.caps.v2.max_texture_2d_size)
104 return vscreen->caps.caps.v2.max_texture_2d_size;
107 if (vscreen->caps.caps.v2.max_texture_3d_size)
108 return 1 + util_logbase2(vscreen->caps.caps.v2.max_texture_3d_size);
111 if (vscreen->caps.caps.v2.max_texture_cube_size)
112 return 1 + util_logbase2(vscreen->caps.caps.v2.max_texture_cube_size);
117 return vscreen->caps.caps.v1.bset.indep_blend_enable;
119 return vscreen->caps.caps.v1.bset.indep_blend_func;
125 return vscreen->caps.caps.v1.bset.fragment_coord_conventions;
127 if (vscreen->caps.caps.v1.bset.depth_clip_disable)
131 return vscreen->caps.caps.v1.max_streamout_buffers;
141 return vscreen->caps.caps.v1.bset.primitive_restart;
143 return vscreen->caps.caps.v1.bset.shader_stencil_export;
148 return vscreen->caps.caps.v1.bset.seamless_cube_map;
150 return vscreen->caps.caps.v1.bset.seamless_cube_map_per_texture;
152 return vscreen->caps.caps.v1.max_texture_array_layers;
154 return vscreen->caps.caps.v2.min_texel_offset;
156 return vscreen->caps.caps.v2.min_texture_gather_offset;
158 return vscreen->caps.caps.v2.max_texel_offset;
160 return vscreen->caps.caps.v2.max_texture_gather_offset;
162 return vscreen->caps.caps.v1.bset.conditional_render;
164 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_TEXTURE_BARRIER;
169 return vscreen->caps.caps.v1.bset.color_clamping;
171 return (vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_FBO_MIXED_COLOR_FORMATS) ||
172 (vscreen->caps.caps.v2.host_feature_check_version < 1);
174 if (vscreen->caps.caps.v2.host_feature_check_version < 6)
175 return MIN2(vscreen->caps.caps.v1.glsl_level, 140);
178 return vscreen->caps.caps.v1.glsl_level;
184 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_COMPUTE_SHADER;
188 return vscreen->caps.caps.v2.uniform_buffer_offset_alignment;
191 return vscreen->caps.caps.v1.bset.streamout_pause_resume;
193 return vscreen->caps.caps.v1.bset.start_instance;
206 return vscreen->caps.caps.v2.host_feature_check_version >= 10;
210 return vscreen->caps.caps.v1.max_tbo_size > 0;
212 return vscreen->caps.caps.v2.texture_buffer_offset_alignment;
216 return vscreen->caps.caps.v1.bset.cube_map_array;
218 return vscreen->caps.caps.v1.bset.texture_multisample;
220 return vscreen->caps.caps.v1.max_viewports;
222 return vscreen->caps.caps.v1.max_tbo_size;
233 return vscreen->caps.caps.v2.max_geom_output_vertices;
235 return vscreen->caps.caps.v2.max_geom_total_output_components;
237 return vscreen->caps.caps.v1.bset.texture_query_lod;
239 return vscreen->caps.caps.v1.max_texture_gather_components;
241 return vscreen->caps.caps.v1.bset.has_indirect_draw;
244 return vscreen->caps.caps.v1.bset.has_sample_shading;
246 return vscreen->caps.caps.v1.bset.has_cull;
248 return ((vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_TRANSFORM_FEEDBACK3) ||
249 (vscreen->caps.caps.v2.host_feature_check_version < 2)) ? 4 : 1;
251 return vscreen->caps.caps.v1.bset.conditional_render_inverted;
253 return vscreen->caps.caps.v1.bset.derivative_control;
255 return vscreen->caps.caps.v1.bset.polygon_offset_clamp;
257 return vscreen->caps.caps.v1.bset.transform_feedback_overflow_query;
259 return vscreen->caps.caps.v2.shader_buffer_offset_alignment;
261 return vscreen->caps.caps.v1.bset.has_fp64 ||
262 (vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_FAKE_FP64);
264 return vscreen->caps.caps.v2.max_shader_patch_varyings;
266 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_TEXTURE_VIEW;
268 return vscreen->caps.caps.v2.max_vertex_attrib_stride;
270 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_COPY_IMAGE;
272 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_TXQS;
274 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_FB_NO_ATTACH;
276 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_ROBUST_BUFFER_ACCESS;
278 return (vscreen->caps.caps.v2.capability_bits &
281 return vscreen->caps.caps.v2.capability_bits_v2 & VIRGL_CAP_V2_BLEND_EQUATION;
283 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_SHADER_CLOCK;
285 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_TGSI_COMPONENTS;
287 return vscreen->caps.caps.v2.max_combined_shader_buffers;
289 return vscreen->caps.caps.v2.max_combined_atomic_counters;
291 return vscreen->caps.caps.v2.max_combined_atomic_counter_buffers;
296 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_QBO;
298 if (vscreen->caps.caps.v1.glsl_level < 150)
299 return vscreen->caps.caps.v2.max_vertex_attribs;
304 return (vscreen->caps.caps.v1.max_samples == 1) ? 1 : 0;
306 return !!(vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_MULTI_DRAW_INDIRECT);
308 return !!(vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_INDIRECT_PARAMS);
310 return (vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_ARB_BUFFER_STORAGE) &&
311 (vscreen->caps.caps.v2.host_feature_check_version >= 4) &&
320 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_CLEAR_TEXTURE;
322 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_CLIP_HALFZ;
335 if (vscreen->caps.caps.v2.capability_bits_v2 & VIRGL_CAP_V2_VIDEO_MEMORY)
336 return vscreen->caps.caps.v2.max_video_memory;
341 return (vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_SRGB_WRITE_CONTROL) ||
342 (vscreen->caps.caps.v2.host_feature_check_version < 1);
349 return vscreen->caps.caps.v2.capability_bits_v2 & VIRGL_CAP_V2_MEMINFO;
351 return vscreen->caps.caps.v2.capability_bits_v2 & VIRGL_CAP_V2_STRING_MARKER;
353 return vscreen->caps.caps.v2.capability_bits_v2 & VIRGL_CAP_V2_IMPLICIT_MSAA;
357 if (vscreen->caps.caps.v2.host_feature_check_version >= 13)
358 return vscreen->caps.caps.v2.max_uniform_block_size;
373 !vscreen->caps.caps.v1.bset.has_tessellation_shaders)
377 !(vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_COMPUTE_SHADER))
400 return vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_INDIRECT_INPUT_ADDR;
402 if (vscreen->caps.caps.v1.glsl_level < 150)
403 return vscreen->caps.caps.v2.max_vertex_attribs;
405 shader == PIPE_SHADER_GEOMETRY) ? vscreen->caps.caps.v2.max_vertex_attribs : 32;
408 return vscreen->caps.caps.v1.max_render_targets;
409 return vscreen->caps.caps.v2.max_vertex_outputs;
415 return vscreen->caps.caps.v1.max_uniform_blocks;
421 return MIN2(vscreen->caps.caps.v2.max_shader_sampler_views,
424 return vscreen->caps.caps.v1.glsl_level >= 130;
428 if (vscreen->caps.caps.v2.host_feature_check_version < 12)
430 return vscreen->caps.caps.v2.max_const_buffer_size[shader];
433 return vscreen->caps.caps.v2.max_shader_buffer_frag_compute;
435 return vscreen->caps.caps.v2.max_shader_buffer_other_stages;
438 return vscreen->caps.caps.v2.max_shader_image_frag_compute;
440 return vscreen->caps.caps.v2.max_shader_image_other_stages;
446 return vscreen->caps.caps.v2.max_atomic_counters[shader];
448 return vscreen->caps.caps.v2.max_atomic_counter_buffers[shader];
478 return vscreen->caps.caps.v2.max_aliased_line_width;
480 return vscreen->caps.caps.v2.max_smooth_line_width;
482 return vscreen->caps.caps.v2.max_aliased_point_size;
484 return vscreen->caps.caps.v2.max_smooth_point_size;
486 return vscreen->caps.caps.v2.max_anisotropy;
488 return vscreen->caps.caps.v2.max_texture_lod_bias;
506 if (!(vscreen->caps.caps.v2.capability_bits & VIRGL_CAP_COMPUTE_SHADER))
512 grid_size[0] = vscreen->caps.caps.v2.max_compute_grid_size[0];
513 grid_size[1] = vscreen->caps.caps.v2.max_compute_grid_size[1];
514 grid_size[2] = vscreen->caps.caps.v2.max_compute_grid_size[2];
520 block_size[0] = vscreen->caps.caps.v2.max_compute_block_size[0];
521 block_size[1] = vscreen->caps.caps.v2.max_compute_block_size[1];
522 block_size[2] = vscreen->caps.caps.v2.max_compute_block_size[2];
528 *max_threads_per_block = vscreen->caps.caps.v2.max_compute_work_group_invocations;
535 *max_local_size = vscreen->caps.caps.v2.max_compute_shared_memory_size;
561 if (has_format_bit(&vscreen->caps.caps.v2.supported_readback_formats,
586 if (!(vscreen->caps.caps.v1.vertexbuffer.bitmask[big] & (1 << small)))
645 vscreen->caps.caps.v2.scanout.bitmask,
666 union virgl_caps *caps = &vscreen->caps.caps;
667 boolean may_emulate_bgra = (caps->v2.capability_bits &
693 if (!caps->v1.bset.texture_multisample)
697 if (sample_count > caps->v2.max_image_samples)
701 if (sample_count > caps->v1.max_samples)
704 if (caps->v2.host_feature_check_version >= 9 &&
705 !has_format_bit(&caps->v2.supported_multisample_formats,
749 caps->v1.render.bitmask,
760 if (!virgl_format_check_bitmask(format, caps->v2.scanout.bitmask, false))
807 caps->v1.sampler.bitmask,
886 fixup_formats(union virgl_caps *caps, struct virgl_supported_format_mask *mask)
898 mask->bitmask[i] = caps->v1.sampler.bitmask[i];
963 /* When we switch the host the caps might change and then we might have to
965 _mesa_sha1_update(&sha1_ctx, &screen->caps, sizeof(screen->caps));
999 fixup_renderer(union virgl_caps *caps)
1001 if (caps->v2.host_feature_check_version < 5)
1006 caps->v2.renderer);
1011 memcpy(caps->v2.renderer, renderer, renderer_len + 1);
1081 vws->get_caps(vws, &screen->caps);
1082 fixup_formats(&screen->caps.caps,
1083 &screen->caps.caps.v2.supported_readback_formats);
1084 fixup_formats(&screen->caps.caps, &screen->caps.caps.v2.scanout);
1085 fixup_renderer(&screen->caps.caps);
1087 union virgl_caps *caps = &screen->caps.caps;
1088 screen->tweak_gles_emulate_bgra &= !virgl_format_check_bitmask(PIPE_FORMAT_B8G8R8A8_SRGB, caps->v1.render.bitmask, false);
1091 /* Set up the NIR shader compiler options now that we've figured out the caps. */