video module refactoring