I don't know what could be the problem, in theory only d3d9.h needed as you wrote. but dynamic shadowmapping in 0.91b is a bit buggy, the variance and squared variance is wrongly calculated, thus you will never get really smoothed shadows, despite the test scene looks okay. I corrected it and as I remember shared it in the forum earlier, but was not satisfied with performance and quality, so finally I took it out of shade-c and transformed into exponential shadowmapping. if you take its source from latest MapBuilder I think you can put it back into shade-c with some work... probably you do better if switch to Shade-C EVO.