bug fix for swtich between software/hardawre video