Well after countless tries, I can't seem to solve the jumping of vertices.
output.position = output.position / output.position.w;
When this line is removed the problem no longer persists, but again, that creates another issue as the map doesn't become correct.
Creation of D3D11_RASTERIZER_DESC :
D3D11_RASTERIZER_DESC rasterizerState;
rasterizerState.FillMode = D3D11_FILL_SOLID;
rasterizerState.CullMode = D3D11_CULL_BACK;
rasterizerState.FrontCounterClockwise = false;
rasterizerState.DepthBias = false;
rasterizerState.DepthBiasClamp = 0;
rasterizerState.SlopeScaledDepthBias = 0;
rasterizerState.DepthClipEnable = true;
rasterizerState.ScissorEnable = true;
rasterizerState.MultisampleEnable = false;
rasterizerState.AntialiasedLineEnable = false;
dev->CreateRasterizerState(&rasterizerState, &RsRMAP);
Shader work:
VS
output.position = mul(position, worldMatrix);
output.position = mul(output.position, viewMatrix);
output.position = mul(output.position, projectionMatrix);
output.position = output.position / output.position.w;
// The decider between the front and back side
output.position.z *= _dpmSetting; // 1 front || -1 back
// Determine the distance between the paraboloid origin and the vertex.
float L = length( output.position.xyz );
// Normalize the vector to the vertex
output.position = output.position / L;
// Save the z-component of the normalized vector
output.z_value = output.position.z;
output.position.z = output.position.z + 1;
output.position.x = output.position.x / output.position.z;
output.position.y = output.position.y / output.position.z;
output.position.z = (L - 0.1)/(500.0-0.1);
output.position.w = 1;
PS
clip( input.z_value );
Now what on the earth have I done wrong... again...