Skip to content

Compute, Tessellation and Geometry Shader Samples for MonoGame Android

Notifications You must be signed in to change notification settings

cpt-max/MonoGame-Shader-Samples-Mobile

Repository files navigation

MonoGame Shader Samples Overview for Android

Each sample is in a separate branch of this repository, so don't use this branch, pick a sample from below first.
The samples are based on a custom MonoGame fork, that adds tesselation, geometry and compute shaders.
You don't need to build the fork in order to run the samples, as they use prebuilt NuGet packages.

.NET 6 and the Android SDK needs to be installed. Either use Visual Studio 2022 or install them manually. On Linux you may also need to install the Java SDK.

Equivalent DirectX and OpenGL Desktop Samples
Compute Shader Guide for MonoGame
NuGet Packages, Platform Support and Build Requirements
Pull Request for main MonoGame Repo
MonoGame Forum Post
Download Prebuilt Executables (win-x64, linux-x64, requires .Net 5+)

This sample uses a very simple hull and domain shader to tessellate a single input triangle into many sub triangles. Each sub triangle is then passed into a geometry shader to generate even more triangles along it's edges, which creates a wireframe-like effect.

This sample uses a compute shader to update particles on the GPU. The particle buffer is used directly by the vertex shader that draws the particles. Since no data needs to be downloaded to the CPU, this method is very fast.

About

Compute, Tessellation and Geometry Shader Samples for MonoGame Android

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published