initial gif engine refactor