diff --git a/src/main.cpp b/src/main.cpp
index 3216354..c39b1d3 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -734,6 +734,30 @@ private:
 
     /////////////////////////////////////////////////////////////
     /// vertex buffer
+    void createBuffer(
+        const vk::DeviceSize size,
+        const vk::BufferUsageFlags usage,
+        const vk::MemoryPropertyFlags properties,
+        vk::raii::Buffer& buffer,
+        vk::raii::DeviceMemory& bufferMemory
+    ) {
+        vk::BufferCreateInfo bufferInfo;
+        bufferInfo.size = size;
+        bufferInfo.usage = usage;
+        bufferInfo.sharingMode = vk::SharingMode::eExclusive;
+
+        buffer = m_device.createBuffer(bufferInfo);
+
+        const vk::MemoryRequirements memRequirements = buffer.getMemoryRequirements();
+
+        vk::MemoryAllocateInfo allocInfo;
+        allocInfo.allocationSize = memRequirements.size;
+        allocInfo.memoryTypeIndex = findMemoryType(memRequirements.memoryTypeBits, properties);
+
+        bufferMemory = m_device.allocateMemory( allocInfo );
+
+        buffer.bindMemory(bufferMemory, 0);
+    }
     uint32_t findMemoryType(const uint32_t typeFilter,const vk::MemoryPropertyFlags properties) const {
         // vk::PhysicalDeviceMemoryProperties
         const auto memProperties = m_physicalDevice.getMemoryProperties();
@@ -744,29 +768,58 @@ private:
         }
         throw std::runtime_error("failed to find suitable memory type!");
     }
-    void createVertexBuffer() {
-        vk::BufferCreateInfo bufferInfo;
-        bufferInfo.size = sizeof(vertices[0]) * vertices.size();
-        bufferInfo.usage = vk::BufferUsageFlagBits::eVertexBuffer;
-        bufferInfo.sharingMode = vk::SharingMode::eExclusive;
+    void copyBuffer(const vk::raii::Buffer& srcBuffer,const vk::raii::Buffer& dstBuffer,const vk::DeviceSize size) const {
+        vk::CommandBufferAllocateInfo allocInfo;
+        allocInfo.level = vk::CommandBufferLevel::ePrimary;
+        allocInfo.commandPool = m_commandPool;
+        allocInfo.commandBufferCount = 1;
 
-        m_vertexBuffer = m_device.createBuffer(bufferInfo);
+        // std::vector<vk::raii::CommandBuffer>
+        auto commandBuffers = m_device.allocateCommandBuffers(allocInfo);
+        const vk::raii::CommandBuffer commandBuffer = std::move(commandBuffers.at(0));
 
-        const vk::MemoryRequirements memRequirements = m_vertexBuffer.getMemoryRequirements();
-        vk::MemoryAllocateInfo allocInfo;
-        allocInfo.allocationSize = memRequirements.size;
-        allocInfo.memoryTypeIndex = findMemoryType(
-            memRequirements.memoryTypeBits,
+        vk::CommandBufferBeginInfo beginInfo;
+        beginInfo.flags = vk::CommandBufferUsageFlagBits::eOneTimeSubmit;
+        commandBuffer.begin(beginInfo);
+
+        vk::BufferCopy copyRegion;
+        copyRegion.srcOffset = 0; // optional
+        copyRegion.dstOffset = 0; // optional
+        copyRegion.size = size;
+        commandBuffer.copyBuffer(srcBuffer, dstBuffer, copyRegion);
+        commandBuffer.end();
+        vk::SubmitInfo submitInfo;
+        submitInfo.setCommandBuffers( *commandBuffer );
+
+        m_graphicsQueue.submit(submitInfo);
+        m_graphicsQueue.waitIdle();
+    }
+    void createVertexBuffer() {
+        const vk::DeviceSize bufferSize = sizeof(Vertex) * vertices.size();
+
+        vk::raii::DeviceMemory stagingBufferMemory{ nullptr };
+        vk::raii::Buffer stagingBuffer{ nullptr };
+        createBuffer(bufferSize,
+            vk::BufferUsageFlagBits::eTransferSrc,
             vk::MemoryPropertyFlagBits::eHostVisible |
-            vk::MemoryPropertyFlagBits::eHostCoherent
+            vk::MemoryPropertyFlagBits::eHostCoherent,
+            stagingBuffer,
+            stagingBufferMemory
         );
 
-        m_vertexBufferMemory = m_device.allocateMemory( allocInfo );
-        m_vertexBuffer.bindMemory(m_vertexBufferMemory, 0);
+        void* data = stagingBufferMemory.mapMemory(0, bufferSize);
+        memcpy(data, vertices.data(), static_cast<size_t>(bufferSize));
+        stagingBufferMemory.unmapMemory();
+
+        createBuffer(bufferSize,
+            vk::BufferUsageFlagBits::eTransferDst |
+            vk::BufferUsageFlagBits::eVertexBuffer,
+            vk::MemoryPropertyFlagBits::eDeviceLocal,
+            m_vertexBuffer,
+            m_vertexBufferMemory
+        );
 
-        void* data = m_vertexBufferMemory.mapMemory(0, bufferInfo.size);
-        memcpy(data, vertices.data(), static_cast<size_t>(bufferInfo.size));
-        m_vertexBufferMemory.unmapMemory();
+        copyBuffer(stagingBuffer, m_vertexBuffer, bufferSize);
     }
     /////////////////////////////////////////////////////////////
 };
