예제 #1
0
파일: Engine.cpp 프로젝트: zgub4/op3d
void op3d::Engine::initVulkan()
{
    instance.create();
    callback.setup(instance);
    surface.create(instance, window);
    physicalDevice.create(instance, surface);
    device.create(physicalDevice, surface, graphicsQueue, presentQueue);
    swapChain.create(device, surface, physicalDevice, window);
    swapChain.createImageViews(device, swapChainImageViews);
    createRenderPass();
    createDescriptorSetLayout();
    createGraphicsPipeline();
    commandBufferManager.createCommandPool(physicalDevice, surface);
    createDepthResources();
    createFramebuffers();
    createTextureImage();
    createTextureImageView();
    createTextureSampler();
    createVertexBuffer();
    createIndexBuffer();
    createUniformBuffer();
    descriptorPool.createPool();
    descriptorSet.createSet(uniformBuffer, textureImageView, textureSampler, descriptorSetLayout, descriptorPool, device);
    createCommandBuffers();
    createSemaphores();
}
void GraphicsManager::initOpenGL()
{
    setGLVersion();
    updateExtensions();
    initOpenGLFunctions();
    updatePlanformExtensions();
    updateDebugLog();
    createTextureSampler();
    updateLimits();
}