Added support for directx11

Also edited CMake. Some experimental features for cmake has been added.