fix const problem, directx.c