libav: Use ref counted packets instead of copying data