rewrite onInit()
fix getPreferred funct wrong choosing formts quality