.net 4.0 - wpf application for broadcasting video with delay -
i have wpf application broadcasting video using expression encoder 4 , framework 4.0, got delay of 15 sec while broadcasting.is there suggestion reduce delay while broadcasting.
below code
private void button1_click(object sender, routedeventargs e) { try { encoderdevice video = null; encoderdevice audio = null;
getselectedvideoandaudiodevices(out video, out audio); stopjob(); if (video == null) { return; } stopjob(); _job = new livejob(); if (video != null && audio != null) { //stopjob(); _devicesource = null; _devicesource = _job.adddevicesource(video, audio); _job.activatesource(_devicesource); // finds , applys smooth streaming preset //_job.applypreset(livepresets.vc1highspeedbroadband4x3); // creates publishing format job pullbroadcastpublishformat format = new pullbroadcastpublishformat(); format.broadcastport = 9090; format.maximumnumberofconnections = 50; // adds publishing format job _job.publishformats.add(format); // starts encoding _job.startencoding(); } //webcamctrl.startcapture(); } catch (exception ex) { writelogfile(this.gettype().name, "button1_click", ex.message.tostring()); } }
Comments
Post a Comment