Documentation ¶
Index ¶
- type Context
- func (app *Context) BeginOneTimeCommands() vk.CommandBuffer
- func (ctx *Context) CreateImage(extent vk.Extent2D, format vk.Format, tiling vk.ImageTiling, ...) (image vk.Image, imageMemory vk.DeviceMemory)
- func (ctx *Context) CreateImageView(image vk.Image, format vk.Format, aspectMask vk.ImageAspectFlags) vk.ImageView
- func (app *Context) EndOneTimeCommands(buf vk.CommandBuffer)
- func (ctx *Context) FindMemoryType(typeFilter uint32, flags vk.MemoryPropertyFlags) uint32
- func (ctx *Context) Initialize(hInstance windows.Handle, hWnd windows.HWND)
- func (ctx *Context) Teardown()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context struct {
EnableApiLayers, EnableInstanceExtensions, EnableDeviceExtensions []string
Instance vk.Instance
Surface vk.SurfaceKHR
PhysicalDevice vk.PhysicalDevice
Device vk.Device
GraphicsQueueFamilyIndex, PresentQueueFamilyIndex uint32
GraphicsQueue, PresentQueue vk.Queue
// Command pool and buffers
CommandPool vk.CommandPool
CommandBuffers []vk.CommandBuffer // Primary buffers
// Swapchain handles
Swapchain vk.SwapchainKHR
SwapchainExtent vk.Extent2D
SwapchainImageFormat vk.Format
SwapchainImages []vk.Image
SwapchainImageViews []vk.ImageView
SwapChainFramebuffers []vk.Framebuffer
// Sync objects
ImageAvailableSemaphore, RenderFinishedSemaphore vk.Semaphore
InFlightFence vk.Fence
}
func (*Context) BeginOneTimeCommands ¶
func (app *Context) BeginOneTimeCommands() vk.CommandBuffer
func (*Context) CreateImage ¶
func (ctx *Context) CreateImage(extent vk.Extent2D, format vk.Format, tiling vk.ImageTiling, usage vk.ImageUsageFlags, memProps vk.MemoryPropertyFlags) (image vk.Image, imageMemory vk.DeviceMemory)
func (*Context) CreateImageView ¶
func (ctx *Context) CreateImageView(image vk.Image, format vk.Format, aspectMask vk.ImageAspectFlags) vk.ImageView
func (*Context) EndOneTimeCommands ¶
func (app *Context) EndOneTimeCommands(buf vk.CommandBuffer)
func (*Context) FindMemoryType ¶
func (*Context) Initialize ¶
Click to show internal directories.
Click to hide internal directories.