         private function initVideoCallback(info:Object):void {
             _hasVideo = true;
             _videoInfo = info;
+            _bytesARGB = new ByteArray();
+            _bytesARGB.length = info.width * info.height * 4;
             if (oninitvideo != null) {
                 oninitvideo(_videoInfo);
             }

                yCbCrBuffer.width, yCbCrBuffer.height,
                yCbCrBuffer.hdec, yCbCrBuffer.vdec
            );
            var bytesARGB:ByteArray = extractBuffer(bufferARGB, yCbCrBuffer.width * yCbCrBuffer.height * 4);
            bytesARGB.endian = Endian.BIG_ENDIAN; // Switch the endian back or it'll get byte-swapped later
            return bytesARGB;
        }

        /**

                throw new Error("called dequeueFrame when no frame ready");
            }
        }

        /**
         * @param yCbCrBuffer dequeued frame info structure
         * @return ByteArray full of ARGB pixels ready to be drawn
         *
         * Warning: the buffer will be reused.
         */
        public function convertYCbCr(yCbCrBuffer:Object):ByteArray {
            var bufferARGB:int = OgvSwfConvertYCbCr(
                yCbCrBuffer.bufferY, yCbCrBuffer.bufferCb, yCbCrBuffer.bufferCr,
