So why is there no 16-bit rendering option in NewDark? I don't know, but here's how to enable it.
Using your favorite hex editor, make the following change to the game binary (thief.exe):
Then start the game and enjoy 16-bit banding like it's 1998.
With the hex edit, the value of the d3d_disp_enable_hdr configuration variable is directly used as the render target format. The value 23 for d3d_disp_enable_hdr is D3DFMT_R5G6B5, from (
) https://docs.microsoft.com/en-us/windows/win32/direct3d9/d3dformat. D3DFMT_X1R5G5B5 (24) also works. Some other formats, such as D3DFMT_L8 theoretically should work, but don't. I don't know why.
The hex edit modifies the code below. The first call here is clearly a call to a function to read the configuration variable, which is apparently returned in ESI. Then there's some weird gymnastics performed on it before it's passed on to the CreateRenderTarget() call at the end. The hex edit simply NOPs out all the operations on ESI, so that the value of the configuration variable is used as-is as the render target format.
Code:
00D9983A | 68 94CDE900 | push thief.E9CD94 | E9CD94:"d3d_disp_enable_hdr"
00D9983F | 8D4C24 14 | lea ecx,dword ptr ss:[esp+14] |
00D99843 | BA 01000000 | mov edx,1 |
00D99848 | C74424 14 10000000 | mov dword ptr ss:[esp+14],10 |
00D99850 | E8 DBBF0600 | call <thief.sub_E05830> |
00D99855 | 8B7424 14 | mov esi,dword ptr ss:[esp+14] |
00D99859 | 8B0D E4FF1201 | mov ecx,dword ptr ds:[112FFE4] |
00D9985F | A1 5C911701 | mov eax,dword ptr ds:[117915C] |
00D99864 | 8B10 | mov edx,dword ptr ds:[eax] |
00D99866 | 8B52 70 | mov edx,dword ptr ds:[edx+70] |
00D99869 | 83C4 04 | add esp,4 |
00D9986C | 53 | push ebx |
00D9986D | 68 60911701 | push thief.1179160 |
00D99872 | 83EE 20 | sub esi,20 |
00D99875 | 53 | push ebx |
00D99876 | 51 | push ecx |
00D99877 | 8B0D E0FF1201 | mov ecx,dword ptr ds:[112FFE0] |
00D9987D | F7DE | neg esi |
00D9987F | 1BF6 | sbb esi,esi |
00D99881 | 51 | push ecx |
00D99882 | 83E6 FD | and esi,FFFFFFFD |
00D99885 | 83C6 74 | add esi,74 |
00D99888 | 56 | push esi |
00D99889 | 55 | push ebp |
00D9988A | 57 | push edi |
00D9988B | 50 | push eax |
00D9988C | FFD2 | call edx | edx:public: virtual long __stdcall CBaseDevice::CreateRenderTarget(unsigned int,unsigned int,enum _D3DFORMAT,enum _D3DMULTISAMPLE_TYPE,unsigned long,int,struct IDirect3DSurface9 * *,void * *)