PS. With this solution, immediate mode can be initialized and finalized consecutively if you drop a video part of T49043