refactored renderfun further to be able to include in avfeed with little dependencies
additional terminal work, still ways to go