Html5 target and video

hi all,

I know about this topic showing how to get video to play with the swf target. I’m keen though on playing preloaded video (bytearray) in html.

Sadly, openfl.net.NetStream does not have ‘appendBytes’ function.

Anyone any tips? Below is what I have been trying.

Cheers,
Andy.

	private function setVideo(vid_bytearray:ByteArray, image:Image) {
	
	if (nc != null) return;		
	
	function onNetStreamConnect(evt:NetStatusEvent) {
		var ns:NetStream = new NetStream(nc);		
		ns.appendBytes(vid_bytearray);
		var video:Video = new Video();
		video.attachNetStream(ns);
		image.sprite.addChild(video);
		ns.play(null);
		
	}
	
	nc = new NetConnection();
	nc.addEventListener(NetStatusEvent.NET_STATUS, onNetStreamConnect);
	nc.connect(null);


}

this looks promising HTML5 loading video from Assets directory