Exposed missing extensions
This commit is contained in:
parent
9ec4f33ddf
commit
642b6ca2df
|
@ -1,11 +1,10 @@
|
|||
#![allow(dead_code)]
|
||||
use prelude::*;
|
||||
use std::mem;
|
||||
use instance::Instance;
|
||||
use entry::Entry;
|
||||
use vk;
|
||||
use std::ffi::CStr;
|
||||
use ::RawPtr;
|
||||
use version::{EntryV1_0, InstanceV1_0};
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct AndroidSurface {
|
||||
|
@ -14,7 +13,9 @@ pub struct AndroidSurface {
|
|||
}
|
||||
|
||||
impl AndroidSurface {
|
||||
pub fn new(entry: &Entry, instance: &Instance) -> Result<AndroidSurface, Vec<&'static str>> {
|
||||
pub fn new<E: EntryV1_0, I: InstanceV1_0>(entry: &E,
|
||||
instance: &I)
|
||||
-> Result<AndroidSurface, Vec<&'static str>> {
|
||||
let surface_fn = vk::AndroidSurfaceFn::load(|name| {
|
||||
unsafe {
|
||||
mem::transmute(entry.get_instance_proc_addr(instance.handle(), name.as_ptr()))
|
||||
|
|
|
@ -1,11 +1,10 @@
|
|||
#![allow(dead_code)]
|
||||
use prelude::*;
|
||||
use std::mem;
|
||||
use instance::Instance;
|
||||
use entry::Entry;
|
||||
use vk;
|
||||
use std::ffi::CStr;
|
||||
use ::RawPtr;
|
||||
use version::{EntryV1_0, InstanceV1_0};
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct MirSurface {
|
||||
|
@ -14,7 +13,9 @@ pub struct MirSurface {
|
|||
}
|
||||
|
||||
impl MirSurface {
|
||||
pub fn new(entry: &Entry, instance: &Instance) -> Result<MirSurface, Vec<&'static str>> {
|
||||
pub fn new<E: EntryV1_0, I: InstanceV1_0>(entry: &E,
|
||||
instance: &I)
|
||||
-> Result<MirSurface, Vec<&'static str>> {
|
||||
let surface_fn = vk::MirSurfaceFn::load(|name| {
|
||||
unsafe {
|
||||
mem::transmute(entry.get_instance_proc_addr(instance.handle(), name.as_ptr()))
|
||||
|
|
|
@ -3,17 +3,17 @@ pub use self::surface::Surface;
|
|||
pub use self::xlib_surface::XlibSurface;
|
||||
pub use self::debug_report::DebugReport;
|
||||
pub use self::win32_surface::Win32Surface;
|
||||
//pub use self::mir_surface::MirSurface;
|
||||
//pub use self::xcb_surface::XcbSurface;
|
||||
//pub use self::wayland_surface::WaylandSurface;
|
||||
//pub use self::android_surface::AndroidSurface;
|
||||
//
|
||||
pub use self::mir_surface::MirSurface;
|
||||
pub use self::xcb_surface::XcbSurface;
|
||||
pub use self::wayland_surface::WaylandSurface;
|
||||
pub use self::android_surface::AndroidSurface;
|
||||
|
||||
mod swapchain;
|
||||
mod surface;
|
||||
mod xlib_surface;
|
||||
mod win32_surface;
|
||||
mod debug_report;
|
||||
//mod mir_surface;
|
||||
//mod android_surface;
|
||||
//mod wayland_surface;
|
||||
//mod xcb_surface;
|
||||
mod mir_surface;
|
||||
mod android_surface;
|
||||
mod wayland_surface;
|
||||
mod xcb_surface;
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
#![allow(dead_code)]
|
||||
use prelude::*;
|
||||
use std::mem;
|
||||
use instance::Instance;
|
||||
use entry::Entry;
|
||||
use vk;
|
||||
use std::ffi::CStr;
|
||||
use ::RawPtr;
|
||||
use version::{EntryV1_0, InstanceV1_0};
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct WaylandSurface {
|
||||
|
@ -13,7 +13,9 @@ pub struct WaylandSurface {
|
|||
}
|
||||
|
||||
impl WaylandSurface {
|
||||
pub fn new(entry: &Entry, instance: &Instance) -> Result<WaylandSurface, Vec<&'static str>> {
|
||||
pub fn new<E: EntryV1_0, I: InstanceV1_0>(entry: &E,
|
||||
instance: &I)
|
||||
-> Result<WaylandSurface, Vec<&'static str>> {
|
||||
let surface_fn = vk::WaylandSurfaceFn::load(|name| {
|
||||
unsafe {
|
||||
mem::transmute(entry.get_instance_proc_addr(instance.handle(), name.as_ptr()))
|
||||
|
|
|
@ -1,11 +1,10 @@
|
|||
#![allow(dead_code)]
|
||||
use prelude::*;
|
||||
use std::mem;
|
||||
use instance::Instance;
|
||||
use entry::Entry;
|
||||
use vk;
|
||||
use std::ffi::CStr;
|
||||
use ::RawPtr;
|
||||
use version::{EntryV1_0, InstanceV1_0};
|
||||
|
||||
#[derive(Clone)]
|
||||
pub struct XcbSurface {
|
||||
|
@ -14,7 +13,9 @@ pub struct XcbSurface {
|
|||
}
|
||||
|
||||
impl XcbSurface {
|
||||
pub fn new(entry: &Entry, instance: &Instance) -> Result<XcbSurface, Vec<&'static str>> {
|
||||
pub fn new<E: EntryV1_0, I: InstanceV1_0>(entry: &E,
|
||||
instance: &I)
|
||||
-> Result<XcbSurface, Vec<&'static str>> {
|
||||
let surface_fn = vk::XcbSurfaceFn::load(|name| {
|
||||
unsafe {
|
||||
mem::transmute(entry.get_instance_proc_addr(instance.handle(), name.as_ptr()))
|
||||
|
|
Loading…
Reference in a new issue