Coder Social home page Coder Social logo

vsvr's Introduction

VSVR - The very simple Vulkan renderer (WIP!)

Build

This a very simple and basic Vulkan rendering framework / library that abstracts some of the Vulkan objects and functions using C++14 in one project without any unecessary submodules / libraries. It was supposed to make my life developing simple Vulkan applications easier, but don't expect too much from it. Use as you like according to the MIT LICENSE.

How to build?

Prequisites

From the command line

  • Navigate to the vsvr folder, then:
mkdir build && cd build
cmake ..
make -j $(grep -c '^processor' /proc/cpuinfo 2>/dev/null)

From Visual Studio Code

  • Must: Install the "C/C++ extension" by Microsoft.
  • Recommended: If you want intellisense functionality install the "C++ intellisense" extension by austin.
  • Must: Install the "CMake Tools" extension by vector-of-bool.
  • Restart / Reload Visual Studio Code if you have installed extensions.
  • Open the vsvr folder using "Open folder...".
  • Choose "Unspecified" as your active CMake kit if asked. It then should be autodetected correctly.
  • You should be able to build now using F7 and build + run using F5.

How to use?

  • Clone the library as a submodule to your project:
    git submodule add https://github.com/HorstBaerbel/vsvr vsvr

  • Adjust your CMakeLists.txt:

    • Include the library subdirectory in your project:
      add_subdirectory(vsvr)
    • Add shader compilation:
      set(SHADER_SRC_DIR "${CMAKE_CURRENT_SOURCE_DIR}/shaders")
      LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/vsvr")
      include(compile_shaders REQUIRED)
      (here your shaders will be read and written to "./shaders")
    • Add a dependency to shader compilation to your project:
      add_dependencies(<YOUR_PROJECT> shaders)
    • Add the library to your projects include paths:
      target_include_directories(<YOUR_PROJECT> PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/vsvr")
    • Make sure the library is linked to your project:
      target_link_libraries(<YOUR_PROJECT> vsvr)

vsvr's People

Contributors

horstbaerbel avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.