better mutex handling. fixed audio problems.