add stream api for vcdiff encode