Yes, I think I am using fences correctly. To be sure about that I replaced my fences mechanism by FlushCommandQueue() (that basically does not begin to render next frame until current frame was completely executed by GPU) and I had the same problem.
Civilization 5 uses DirectX 11 and DirectCompute to leverage a variable bit rate texture codec algorithm. The algorithm is so efficient that 2 GB of leader textures compress down to less than 150 MB of disk storage.
DiRT 3 employs DirectCompute for its high-definition ambient occlusion (HDAO) effect. Unfortunately, there is no equivalent effect in the game based on pixel shading, so we can’t compare the two directly.
The advanced depth of field (DOF) effect in Metro 2033 needs three rendering passes. Two of these employ pixel shading, while the third uses DirectCompute."
I was trying to get a good displacement mapping effect using cubes, but I need to improve tessellation on the edges. Basically I am using the same algorithm for all the shapes. You can check it in my repository, the project is called DisplacementMapping.
Hi community. I finished a new mini project about Displacement Mapping using DirectX 11.
A normal map is a texture, but instead of storing RGB data at each texel,
we store a compressed x-coordinate, y-coordinate and z-coordinate in
the red component, green component, and blue component, respectively.
These coordinates define a normal vector, thus a normal map stores a
normal vector at each pixel.
The strategy of normal mapping is to texture our polygons with normal
maps. We then have per-pixel normals which capture the fine details of a
surface like bumps, scratches and crevices. We then use these per-pixel
normals from the normal map in our lighting calculations, instead of
the interpolated vertex normal.
Normal mapping just improves the lighting detail, but it does not
improve the detail of the actual geometry. So in a sense, normal mapping
is just a lighting trick.
The idea of displacement mapping is to utilize an additional map, called a heightmap, which describes the
bumps and crevices of the surface. In other words, whereas a normal map
has three color channels to yield a normal vector (x, y, z) for each
pixel, the heightmap has a single color channel to yield a height value h
at each pixel. Visually, a heightmap is just a grayscale image (grays
because there is only one color channel), where each pixel is
interpreted as a height value, it is basically a discrete representation
of a 2D scalar field h = f(x, z). When we tessellate the mesh, we
sample the heightmap in the domain shader to offset the vertices in the
normal vector direction to add geometric detail to the mesh.
While tessellating geometry adds triangles, it does not add detail
on its own. That is, if you subdivide a triangle several times, you just
get more triangles that lie on the original triangle plane. To add
detail, then you need to offset the tessellated vertices in some way. A
heightmap is one input source that can be used to displace the
To generate heightmaps you could use NVIDIA Photoshop's plugin or CrazyBump for example
Introduction to 3D Game programming using DirectX 11.
Real Time Rendering