Made API of audio and video encoders more consistent.
Added to streams notifications on start/finish writing.