Git Product home page Git Product logo

hyunjunekim / diligentsamples Goto Github PK

View Code? Open in Web Editor NEW

This project forked from diligentgraphics/diligentsamples

0.0 1.0 0.0 317.94 MB

Sample projects demonstrating the usage of Diligent Engine

Home Page: http://diligentgraphics.com/diligent-engine/samples/

License: Apache License 2.0

C++ 83.28% GLSL 2.96% HLSL 0.39% CMake 3.10% Java 5.85% Shell 0.71% Objective-C++ 0.93% C 2.22% Batchfile 0.58%

diligentsamples's Introduction

DiligentSamples

This module contains tutorials and sample applications intended to demonstrate the usage of Diligent Engine. The module depends on the Core and Tools submodules.

To build and run the applications in the module, please follow the instructions in the master repository.

License Chat on gitter Chat on Discord Build Status Build Status Codacy Badge

Table of Contents

Tutorials

This tutorial shows how to render simple triangle using Diligent Engine API.

This tutorial demonstrates how to render an actual 3D object, a cube. It shows how to load shaders from files, create and use vertex, index and uniform buffers.

This tutorial demonstrates how to apply a texture to a 3D object. It shows how to load a texture from file, create shader resource binding object and how to sample a texture in the shader.

This tutorial is identical to Tutorial03, but is implemented using C API.

This tutorial demonstrates how to use instancing to render multiple copies of one object using unique transformation matrix for every copy.

This tutorial demonstrates how to combine instancing with texture arrays to use unique texture for every instance.

This tutorial shows how to generate command lists in parallel from multiple threads.

This tutorial shows how to use geometry shader to render smooth wireframe.

This tutorial shows how to use hardware tessellation to implement simple adaptive terrain rendering algorithm.

This tutorial shows how to render multiple 2D quads, frequently swithcing textures and blend modes.

This tutorial shows dynamic buffer mapping strategy using MAP_FLAG_DISCARD and MAP_FLAG_DO_NOT_SYNCHRONIZE flags to efficiently stream varying amounts of data to GPU.

This tutorial demonstrates different ways to update buffers and textures in Diligent Engine and explains important internal details and performance implications related to each method.

This tutorial demonstrates how to render a 3d cube into an offscreen render target and do a simple post-processing effect.

This tutorial demonstrates how to render basic shadows using a shadow map.

This tutorial shows how to implement a simple particle simulation system using compute shaders.

This tutorial demonstrates how to use Diligent Engine to render to multiple windows.

This tutorial shows how to implement bindless resources, a technique that leverages dynamic shader resource indexing feature enabled by the next-gen APIs to significantly improve rendering performance.

This tutorial demonstrates how to use multisample anti-aliasing (MSAA) to make geometrical edges look smoother and more temporarily stable.

This tutorial demonstrates how to use queries to retrieve various information about the GPU operation, such as the number of primitives rendered, command processing duration, etc.

This tutorial demonstrates how to use the render passes API to implement simple deferred shading.

Samples

This sample demonstrates how to integrate Epipolar Light Scattering post-processing effect into an application to render physically-based atmosphere.

This sample demonstrates how to use the Asset Loader and GLTF PBR Renderer to load and render GLTF models.

This sample demonstrates how to integrate the Shadowing component into an application to render high-quality shadows.

This sample demonstrates the integration of the engine with dear imgui UI library.

This sample demonstrates the integration of the engine with nuklear UI library.

This sample demonstrates how to use Diligent Engine in a basic Android AR application.

Build and Run Instructions

Please refer to Build and Run Instructions section in the master repository's readme.

Command line options:

  • -mode {d3d11|d3d12|vk|gl} - select rendering back-end (example: -mode d3d12).
  • -width value - set desired window width (example: -width 1024).
  • -height value - set desired window height (example: -height 768).
  • -capture_path path - path to the folder where screen captures will be saved. Specifying this parameter enables screen capture (example: -capture_path .).
  • -capture_name name - screen capture file name. Specifying this parameter enables screen capture (example: -capture_name frame).
  • -capture_fps fps - recording fps when capturing frame sequence (example: -capture_fps 10). Default value: 15.
  • -capture_frames value - number of frames to capture after the app starts (example: -capture_frames 50).
  • -capture_format {jpg|png} - image file format (example: -capture_format jpg). Default value: jpg.
  • -capture_quality value - jpeg quality (example: -capture_quality 80). Default value: 95.
  • -capture_alpha value - when saving png, whether to write alpha channel (example: -capture_alpha 1). Default value: false.
  • -validation value - set validation level (example: -validation 1). Default value: 1 in debug build; 0 in release builds.
  • -adapter value - select GPU adapter, if there are more than one installed on the system (example: -adapter 1). Default value: 0.

When image capture is enabled the following hot keys are available:

  • F2 starts frame capture recording.
  • F3 finishes frame capture recroding.
  • F4 saves single screenshot.

To record multiple frames after the app starts, use command line like this:

-mode d3d12 -capture_path . -capture_fps 15 -capture_name frame -width 640 -height 480 -capture_format png -capture_frames 50

License

See Apache 2.0 license.

This project has some third-party dependencies, each of which may have independent licensing:

  • nuklear: A single-header ANSI C gui library.

Contributing

To contribute your code, submit a Pull Request to this repository. Diligent Engine is licensed under the Apache 2.0 license that guarantees that code in the DiligentSamples repository is free of Intellectual Property encumbrances. In submitting code to this repository, you are agreeing that the code is free of any Intellectual Property claims.

Diligent Engine uses clang-format to ensure consistent source code style throught the code base. The format is validated by appveyor and travis for each commit and pull request, and the build will fail if any code formatting issue is found. Please refer to this page for instructions on how to set up clang-format and automatic code formatting.


diligentgraphics.com

Diligent Engine on Twitter Diligent Engine on Facebook

diligentsamples's People

Contributors

themostdiligent avatar dolphineye avatar

Watchers

James Cloos 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.