Added parameter to disable hardware acceleration