vulkano icon indicating copy to clipboard operation
vulkano copied to clipboard

[KHR_display] I have tried KHR_display, and it is working

Open sprhawk opened this issue 6 years ago • 1 comments

https://github.com/vulkano-rs/vulkano/blob/37fcd507d0b7cc5d0ec7ac643444cd4d9142ba75/vulkano/src/swapchain/display.rs#L12

The documentation said there is no device with KHR_Display Extension. But in fact, the Display Extension is for linux framebuffer, and the ARM driver for fbdev will contain this device extension. I have tried sample in ARM vulkan-sdk, then I tried with vulkano

The demo shows a triangle on the display and here is the output of my demo:

Hello, Vulkan! Instance extensions: khr_surface:true khr_display:true khr_xlib_surface: false khr_xcb_surface: false khr_wayland_surface: false khr_mir_surface: false khr_android_surface: false khr_win32_surface: false ext_debug_report: false mvk_ios_surface: false mvk_macos_surface: false mvk_moltenvk: false nn_vi_surface: false ext_swapchain_colorspace: false khr_get_phyiscal_device_properties2: false Available layers:

Device Info: Name:Mali-T760 Type:IntegratedGpu Api: 1.0.11 Driver: 3216195990 Supported Features: Features { robust_buffer_access: true, full_draw_index_uint32: true, image_cube_array: false, independent_blend: true, geometry_shader: false, tessellation_shader: false, sample_rate_shading: false, dual_src_blend: false, logic_op: false, multi_draw_indirect: false, draw_indirect_first_instance: true, depth_clamp: false, depth_bias_clamp: true, fill_mode_non_solid: false, depth_bounds: false, wide_lines: false, large_points: true, alpha_to_one: false, multi_viewport: false, sampler_anisotropy: false, texture_compression_etc2: true, texture_compression_astc_ldr: true, texture_compression_bc: false, occlusion_query_precise: false, pipeline_statistics_query: false, vertex_pipeline_stores_and_atomics: false, fragment_stores_and_atomics: true, shader_tessellation_and_geometry_point_size: false, shader_image_gather_extended: false, shader_storage_image_extended_formats: false, shader_storage_image_multisample: false, shader_storage_image_read_without_format: false, shader_storage_image_write_without_format: false, shader_uniform_buffer_array_dynamic_indexing: true, shader_sampled_image_array_dynamic_indexing: true, shader_storage_buffer_array_dynamic_indexing: true, shader_storage_image_array_dynamic_indexing: true, shader_clip_distance: false, shader_cull_distance: false, shader_f3264: false, shader_int64: false, shader_int16: true, shader_resource_residency: false, shader_resource_min_lod: false, sparse_binding: false, sparse_residency_buffer: false, sparse_residency_image2d: false, sparse_residency_image3d: false, sparse_residency2_samples: false, sparse_residency4_samples: false, sparse_residency8_samples: false, sparse_residency16_samples: false, sparse_residency_aliased: false, variable_multisample_rate: false, inherited_queries: false } Queue families: queue 0: count: 2 graphics:true compute:true transfers:true sparse_bind:false memtype 0: local:true, host_visible: true, host_coherent: true, host_cached: false, lazily_allocated: false memtype 1: local:true, host_visible: true, host_coherent: false, host_cached: true, lazily_allocated: false memtype 2: local:true, host_visible: false, host_coherent: false, host_cached: false, lazily_allocated: true memheap 0: size: 2108825600, local: true Limits: max_image_dimension_1d: 8192 max_image_dimension_2d: 8192 max_image_dimension_3d: 4096 max_image_dimension_cube: 8192 Device extensions: khr_swapchain: true khr_display_swapchain: false khr_sampler_mirror_clamp_to_edge: false khr_maintenance1: false khr_get_memory_requirements: false khr_dedicated_allocation: false khr_incremental_present: false ext_debug_marker: false

Displays: name: /dev/fb0 dimension(0 x 0) resolution(1536 x 2048) modes: region(1536 x 2048) refresh rate: 60000 DisplayPlane: 0 Surface capabilities:min_image_count:(2)max_image_count(Some(2))current_extent(1536x2048)min_image_extent(1536x2048)max_image_extent(1536x2048)max_image_array_layers(1)supprted_transform(identity:true rotate90: false rotate180: false rotate279: false horizontal_mirror: false horizontal_mirror_rotate90: false horizontal_mirror_rotate180: false horizontal_mirror_rotate270: false inherit: false supported_format: {(B8G8R8A8Unorm, SrgbNonLinear(B8G8R8A8Srgb, SrgbNonLinear} supported_present_mode: {immediate: true fifo: true mailbox: false relaxed: false} image_usage: ImageUsage { transfer_source: true, transfer_destination: true, sampled: false, storage: false, color_attachment: true, depth_stencil_attachment: false, transient_attachment: false, input_attachment: false } supported_composite_alpha: SupportedCompositeAlpha { opaque: true, pre_multiplied: false, post_multiplied: false, inherit: false } !!! WARNING !!! Single fbdev framebuffer available, will fake double buffering on top of single buffered surface.

sprhawk avatar Apr 29 '18 00:04 sprhawk

This is amazing! I think it means that vulkano and all of its derived crates can potentially be used for writing compositors?

skyne98 avatar Apr 16 '19 14:04 skyne98