{"id":0,"registry":{"0":{"shape":{"__isSmartRef__":true,"id":1},"submorphs":[],"scripts":[],"_ClipMode":"auto","derivationIds":["3ABFAB66-3E1D-4B57-B4D3-DBF0D37DCE60","D3CB6A05-D42B-419A-992D-1DDF9DDED959","034779AD-D220-487C-A85D-C8C72ED576E0","334AD1D8-40EC-4B9C-818C-37699FB7674D","84D78072-9CDC-4D7A-9F75-56681F89DF7E","F19DA916-0485-4B6D-B336-3B804252F0AB","524F6B82-3EE0-4368-AA37-DC9BF0AC187E","EAFA5923-8B15-4F15-A967-226837C3BDBA","99ED38FB-9C21-41DD-8581-73A789669C26","6C11A546-5CEC-41C7-84AD-EAF8CC247F04","7311C32A-91AB-422C-B6F8-68F2C979BD99","519ABD29-7315-4089-A746-0DE8361DCECC","7DCB436E-5813-403A-9FA4-D35D94B6E546","A277934D-3BC2-4781-BBAF-0C3000B912D9","E6DC2597-5B90-4A8A-BDEE-E6F3DCEEA132","D1610C70-C799-443A-A5B4-AFCC29BF97F0","0ACF85E0-4BFB-4342-B6D6-F69CB36B1CA8","0A998CFB-5CAD-49C1-ACD5-118C19466E6F","03362844-94D7-4573-AF44-AB28D7318EF4","9189DDF9-B541-48C7-9366-E8E10C786384","0C465327-6FF2-4B99-BAA2-068935670294","C00EACCC-F586-44ED-B2A3-2AB5368EA336","4473AEE5-F052-4394-80D2-E888353220A6"],"id":"014BABF3-A351-4EF6-80BB-26A249DEBC3E","droppingEnabled":true,"halosEnabled":true,"_StyleClassNames":["Morph","HtmlWrapperMorph","selectable"],"eventHandler":{"__isSmartRef__":true,"id":2},"showsHalos":false,"partsBinMetaInfo":{"__isSmartRef__":true,"id":3},"name":"VideoScreen","prevScroll":[0,4],"isBeingDragged":false,"videoStream":{"__isSmartRef__":true,"id":30},"layout":{"__isSmartRef__":true,"id":31},"__serializedExpressions__":["_Position","distanceToDragEvent"],"streamingConfig":{"__isSmartRef__":true,"id":32},"isBeingStreamed":false,"_Rotation":0,"_Scale":1,"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":34},"__LivelyClassName__":"lively.morphic.HtmlWrapperMorph","__SourceModuleName__":"Global.lively.morphic.AdditionalMorphs","_Position":"lively.pt(0.0,0.0)","distanceToDragEvent":"lively.pt(402.0,-15.0)"},"1":{"_BorderWidth":0,"stringifiedShapeNode":"<div xmlns=\"http://www.w3.org/1999/xhtml\" data-lively-morphid=\"014BABF3-A351-4EF6-80BB-26A249DEBC3E\" class=\"Morph HtmlWrapperMorph selectable\" id=\"null\" style=\"overflow: auto; border: 0px solid rgb(255, 255, 255); padding: 0px; width: 582px; height: 328px; position: absolute; left: 0px; top: 0px; background: rgb(247, 247, 247);\"><video id=\"screen\"></video></div>","_BorderRadius":0,"__serializedExpressions__":["_Padding","_Position","_Extent","_Fill","extent","_BorderColor"],"__LivelyClassName__":"lively.morphic.Shapes.External","__SourceModuleName__":"Global.lively.morphic.Shapes","_Padding":"lively.rect(0,0,0,0)","_Position":"lively.pt(0.0,0.0)","_Extent":"lively.pt(582.0,328.0)","_Fill":"Color.rgb(247,247,247)","extent":"lively.pt(582.0,328.0)","_BorderColor":"Color.rgb(255,255,255)"},"2":{"morph":{"__isSmartRef__":true,"id":0},"__LivelyClassName__":"lively.morphic.EventHandler","__SourceModuleName__":"Global.lively.morphic.Events"},"3":{"partName":"VideoScreen","requiredModules":[],"partsSpaceName":"PartsBin/Felix/","comment":"Video screen for displaying a local screen share. Streaming is enabled.","changes":[{"__isSmartRef__":true,"id":4},{"__isSmartRef__":true,"id":5},{"__isSmartRef__":true,"id":6},{"__isSmartRef__":true,"id":7},{"__isSmartRef__":true,"id":8},{"__isSmartRef__":true,"id":9},{"__isSmartRef__":true,"id":10},{"__isSmartRef__":true,"id":11},{"__isSmartRef__":true,"id":12},{"__isSmartRef__":true,"id":13},{"__isSmartRef__":true,"id":14},{"__isSmartRef__":true,"id":15},{"__isSmartRef__":true,"id":16},{"__isSmartRef__":true,"id":17},{"__isSmartRef__":true,"id":18},{"__isSmartRef__":true,"id":19},{"__isSmartRef__":true,"id":20},{"__isSmartRef__":true,"id":21},{"__isSmartRef__":true,"id":22},{"__isSmartRef__":true,"id":23},{"__isSmartRef__":true,"id":24},{"__isSmartRef__":true,"id":25},{"__isSmartRef__":true,"id":26},{"__isSmartRef__":true,"id":27},{"__isSmartRef__":true,"id":28},{"__isSmartRef__":true,"id":29}],"migrationLevel":9,"__serializedExpressions__":["lastModifiedDate"],"__LivelyClassName__":"lively.PartsBin.PartsBinMetaInfo","__SourceModuleName__":"Global.lively.PartsBin","lastModifiedDate":"new Date(\"Tue Dec 16 2014 11:30:05 GMT-0800 (PST)\")"},"4":{"author":"felix","message":"no comment","id":"D7FD3843-AEA1-43AE-923C-47C65E39A2E5","__serializedExpressions__":["date"],"date":"new Date(\"Fri Nov 07 2014 15:14:33 GMT-0800 (PST)\")"},"5":{"author":"felix","message":"no comment","id":"F5E78D55-A017-42D4-BB69-76DBCD1E545B","__serializedExpressions__":["date"],"date":"new Date(\"Fri Nov 07 2014 15:06:15 GMT-0800 (PST)\")"},"6":{"author":"felix","message":"no comment","id":"A8785682-FB9B-4958-98D5-A893D2CC155F","__serializedExpressions__":["date"],"date":"new Date(\"Fri Nov 07 2014 14:56:15 GMT-0800 (PST)\")"},"7":{"author":"Felix","message":"no comment","id":"6CFEBA4D-99D9-4CAA-9B3B-DF7892075364","__serializedExpressions__":["date"],"date":"new Date(\"Fri Oct 31 2014 12:02:52 GMT-0700 (PDT)\")"},"8":{"author":"Felix","message":"no comment","id":"1CBD1EB7-4B4E-49E0-9949-FB6F8310827F","__serializedExpressions__":["date"],"date":"new Date(\"Mon Oct 13 2014 17:28:33 GMT-0700 (PDT)\")"},"9":{"author":"Felix","message":"no comment","id":"D883CD05-D40C-4DCB-B670-D2D39B226F1E","__serializedExpressions__":["date"],"date":"new Date(\"Wed Oct 01 2014 11:25:15 GMT-0700 (PDT)\")"},"10":{"author":"Felix","message":"no comment","id":"1D3E1C17-4E3F-4100-BC8A-89483E845DD6","__serializedExpressions__":["date"],"date":"new Date(\"Fri Sep 19 2014 11:58:39 GMT-0700 (PDT)\")"},"11":{"author":"Felix","message":"no comment","id":"8ADFF105-D597-4120-9BB9-185D78A0120B","__serializedExpressions__":["date"],"date":"new Date(\"Fri Sep 19 2014 11:51:40 GMT-0700 (PDT)\")"},"12":{"author":"Felix","message":"no comment","id":"F5EB70F2-0C07-455E-9C56-C4B4399D75A6","__serializedExpressions__":["date"],"date":"new Date(\"Wed Sep 17 2014 11:57:10 GMT-0700 (PDT)\")"},"13":{"author":"Felix","message":"no comment","id":"B885FE7C-2AE8-40C9-98B2-454801DAEAAD","__serializedExpressions__":["date"],"date":"new Date(\"Wed Sep 17 2014 11:51:14 GMT-0700 (PDT)\")"},"14":{"author":"Felix","message":"no comment","id":"DA5F2553-C571-4C5F-BE03-F34BFE597DCB","__serializedExpressions__":["date"],"date":"new Date(\"Mon Sep 15 2014 16:57:32 GMT-0700 (PDT)\")"},"15":{"author":"robertkrahn","message":"Fixed reset as suggested by Rick. Thanks Rick!","id":"C9389773-D839-4E3C-AF10-28F6282541BB","__serializedExpressions__":["date"],"date":"new Date(\"Thu Jul 17 2014 12:02:10 GMT-0700 (PDT)\")"},"16":{"author":"robertkrahn","message":"no comment","id":"4B305BE4-1B35-4BBB-ABCE-D255D563CBD9","__serializedExpressions__":["date"],"date":"new Date(\"Wed Feb 12 2014 15:34:42 GMT-0800 (PST)\")"},"17":{"author":"robertkrahn","message":"no comment","id":"FC45EDD5-3632-41E9-8CCF-1E7BF0F5B7FA","__serializedExpressions__":["date"],"date":"new Date(\"Wed Feb 12 2014 15:35:06 GMT-0800 (PST)\")"},"18":{"author":"robertkrahn","message":"clipped","id":"D4A9A56A-16E6-4D3D-9B42-425F9CE8E8B6","__serializedExpressions__":["date"],"date":"new Date(\"Wed Feb 12 2014 16:29:30 GMT-0800 (PST)\")"},"19":{"author":"robertkrahn","message":"clipped","id":"287FA9C0-4815-46CD-B588-28102199A3F0","__serializedExpressions__":["date"],"date":"new Date(\"Wed Feb 12 2014 16:29:38 GMT-0800 (PST)\")"},"20":{"author":"Felix","message":"no comment","id":"3AF61770-FDB7-47F7-8A96-9F72BEF4B07A","__serializedExpressions__":["date"],"date":"new Date(\"Mon Sep 15 2014 09:57:39 GMT-0700 (PDT)\")"},"21":{"author":"Felix","message":"no comment","id":"88D77A70-F30A-4F5E-9428-7B3A223A612C","__serializedExpressions__":["date"],"date":"new Date(\"Mon Sep 15 2014 16:59:24 GMT-0700 (PDT)\")"},"22":{"author":"Felix","message":"no comment","id":"0857F38C-AA5A-4BC1-93B9-DF50D54978BA","__serializedExpressions__":["date"],"date":"new Date(\"Mon Sep 15 2014 17:13:36 GMT-0700 (PDT)\")"},"23":{"author":"Felix","message":"no comment","id":"09F25D55-CBC2-4571-BA3B-C753B9A3DA76","__serializedExpressions__":["date"],"date":"new Date(\"Wed Sep 17 2014 11:38:12 GMT-0700 (PDT)\")"},"24":{"author":"Felix","message":"no comment","id":"AD88A605-E189-4413-93AD-76E016F4002D","__serializedExpressions__":["date"],"date":"new Date(\"Tue Sep 30 2014 17:47:47 GMT-0700 (PDT)\")"},"25":{"author":"Felix","message":"no comment","id":"C0B6C053-F2DF-4623-BA69-4264D51D489B","__serializedExpressions__":["date"],"date":"new Date(\"Wed Oct 01 2014 11:39:21 GMT-0700 (PDT)\")"},"26":{"author":"Felix","message":"no comment","id":"3A31E19E-B661-4F1C-A4FF-240E3BA5520F","__serializedExpressions__":["date"],"date":"new Date(\"Fri Oct 31 2014 11:54:40 GMT-0700 (PDT)\")"},"27":{"author":"Felix","message":"no comment","id":"4F525628-2EC7-4AF7-BC23-920FC04117DD","__serializedExpressions__":["date"],"date":"new Date(\"Fri Oct 31 2014 12:04:37 GMT-0700 (PDT)\")"},"28":{"__serializedExpressions__":["date"],"author":"felix","message":"no comment","id":"38207940-5BAD-48F4-8AC7-3CD2CE80269A","date":"new Date(\"Tue Dec 16 2014 11:30:05 GMT-0800 (PST)\")"},"29":{"__serializedExpressions__":["date"],"author":"felix","message":"no comment","id":"C50CEE72-7B7E-404F-8B0C-31983515195F","date":"new Date(\"Tue Dec 16 2014 13:55:56 GMT-0800 (PST)\")"},"30":{"onremovetrack":null,"onaddtrack":null,"onended":null,"ended":true,"id":"HiLaYwIRvzFW46PSgjvR5Iew8f9Mnu3R5jQf","label":"HiLaYwIRvzFW46PSgjvR5Iew8f9Mnu3R5jQf"},"31":{"resizeWidth":true,"resizeHeight":true},"32":{"mediatype":"image","steptime":200,"compressionParameters":{"__isSmartRef__":true,"id":33},"record":false,"streamId":10},"33":{"imgCompression":"image/webp","imgQuality":0.2,"lzwCompression":true},"34":{"isPlaying":{"__isSmartRef__":true,"id":35},"reset":{"__isSmartRef__":true,"id":38},"startVideo":{"__isSmartRef__":true,"id":41},"stopVideo":{"__isSmartRef__":true,"id":44},"playStream":{"__isSmartRef__":true,"id":47},"registerEventOnScreen":{"__isSmartRef__":true,"id":50},"swapScreen":{"__isSmartRef__":true,"id":53},"setExtent":{"__isSmartRef__":true,"id":56},"getVideoElement":{"__isSmartRef__":true,"id":63},"showBitrate":{"__isSmartRef__":true,"id":66},"addBitrateLabel":{"__isSmartRef__":true,"id":69},"isDroppableMedia":{"__isSmartRef__":true,"id":72},"onDropOn":{"__isSmartRef__":true,"id":75},"getMediaType":{"__isSmartRef__":true,"id":82},"onLoad":{"__isSmartRef__":true,"id":85},"restoreStreamingConfig":{"__isSmartRef__":true,"id":88},"captureFrame":{"__isSmartRef__":true,"id":91}},"35":{"varMapping":{"__isSmartRef__":true,"id":36},"source":"function isPlaying() {\n    var video = this.jQuery().children('video').get(0);\n    \n    // when the video element has no source attribute, it is \n    // not playing any stream\n    return !!video.src;\n}","funcProperties":{"__isSmartRef__":true,"id":37},"__LivelyClassName__":"lively.Closure"},"36":{"this":{"__isSmartRef__":true,"id":0}},"37":{"user":"Felix","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Sep 19 2014 11:51:17 GMT-0700 (PDT)\")"},"38":{"varMapping":{"__isSmartRef__":true,"id":39},"source":"function reset() {\n    this.setClipMode(\"auto\");\n    this.jQuery().html(\"<video width=0 height=0 id='video'></video>\");\n}","funcProperties":{"__isSmartRef__":true,"id":40},"__LivelyClassName__":"lively.Closure"},"39":{"this":{"__isSmartRef__":true,"id":0}},"40":{"user":"unknown_user","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Sat Sep 06 2014 22:34:16 GMT-0700 (PDT)\")"},"41":{"varMapping":{"__isSmartRef__":true,"id":42},"source":"function startVideo(mediaStream, callback) {\n    // if no stream provided, use webcam instead\n    if (mediaStream) {\n        this.playStream(mediaStream);\n        if (callback) callback(null, mediaStream);\n    } else {\n        navigator.getUserMedia = \n        navigator.getUserMedia || \n        navigator.webkitGetUserMedia || \n        navigator.mozGetUserMedia;\n\n        var constraints = {video: true, audio: true};\n        var panel = this;\n        \n        function sucCallback(localMediaStream) {\n            panel.playStream(localMediaStream);\n            if (callback) callback(null, localMediaStream);\n        }\n        \n        function errCallback(err) {\n            console.error('VideoScreen Error: ', err);\n            if (callback) callback(err);\n        }\n        \n        navigator.getUserMedia(constraints, sucCallback, errCallback);\n    }\n}","funcProperties":{"__isSmartRef__":true,"id":43},"__LivelyClassName__":"lively.Closure"},"42":{"this":{"__isSmartRef__":true,"id":0}},"43":{"user":"robin","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Mon Sep 08 2014 12:08:49 GMT-0700 (PDT)\")"},"44":{"varMapping":{"__isSmartRef__":true,"id":45},"source":"function stopVideo() {\n    if (!this.videoStream || !this.isPlaying()) return;\n    \n    this.videoStream.stop();\n    this.reset();\n}","funcProperties":{"__isSmartRef__":true,"id":46},"__LivelyClassName__":"lively.Closure"},"45":{"this":{"__isSmartRef__":true,"id":0}},"46":{"user":"Felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Sep 19 2014 11:58:14 GMT-0700 (PDT)\")"},"47":{"varMapping":{"__isSmartRef__":true,"id":48},"source":"function playStream(mediaStream) {\n    this.videoStream = mediaStream;\n    var video = this.jQuery().children('video').get(0);\n    // sometimes the video pauses, so we just restart it\n    video.addEventListener('pause', function() {\n        console.log('Video: paused -> restart');\n        video.play();\n    }, false);\n    var extent = this.getExtent();\n    video.height = extent.y;\n    video.width = extent.x;\n    video.src = window.URL.createObjectURL(mediaStream);\n    video.play();\n}","funcProperties":{"__isSmartRef__":true,"id":49},"__LivelyClassName__":"lively.Closure"},"48":{"this":{"__isSmartRef__":true,"id":0}},"49":{"user":"Felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Wed Oct 01 2014 11:23:56 GMT-0700 (PDT)\")"},"50":{"varMapping":{"__isSmartRef__":true,"id":51},"source":"function registerEventOnScreen(event, callback) {\n    var video = this.jQuery().children('video').get(0);\n    video.addEventListener(event, callback);\n}","funcProperties":{"__isSmartRef__":true,"id":52},"__LivelyClassName__":"lively.Closure"},"51":{"this":{"__isSmartRef__":true,"id":0}},"52":{"user":"Felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Mon Sep 15 2014 17:12:59 GMT-0700 (PDT)\")"},"53":{"varMapping":{"__isSmartRef__":true,"id":54},"source":"function swapScreen(initiator) {\n    var mainScreen = this.get('MainRemoteVideoScreen');\n}","funcProperties":{"__isSmartRef__":true,"id":55},"__LivelyClassName__":"lively.Closure"},"54":{"this":{"__isSmartRef__":true,"id":0}},"55":{"user":"Felix","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Wed Sep 17 2014 12:04:32 GMT-0700 (PDT)\")"},"56":{"varMapping":{"__isSmartRef__":true,"id":57},"source":"function setExtent(newExt) {\n    $super(newExt);\n    var video = this.jQuery().children('video').get(0);\n    video.height = newExt.y;\n    video.width = newExt.x;\n}","funcProperties":{"__isSmartRef__":true,"id":62},"__LivelyClassName__":"lively.Closure"},"57":{"this":{"__isSmartRef__":true,"id":0},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":58}},"58":{"$super":{"__isSmartRef__":true,"id":59}},"59":{"varMapping":{"__isSmartRef__":true,"id":60},"source":"function () {\n                try {\n                    // FIXME super is supposed to be static\n                    return Object.getPrototypeOf(obj)[name].apply(obj, arguments);\n                } catch (e) {\n                    if ($world)\n                        $world.logError(e, 'Error in $super call')\n                    else\n                        alert('Error in $super call: ' + e + '\\n' + e.stack);\n                    return null;\n                }\n            }","funcProperties":{"__isSmartRef__":true,"id":61},"__LivelyClassName__":"lively.Closure"},"60":{"obj":{"__isSmartRef__":true,"id":0},"name":"setExtent"},"61":{},"62":{"user":"Felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Wed Oct 01 2014 11:25:03 GMT-0700 (PDT)\")"},"63":{"varMapping":{"__isSmartRef__":true,"id":64},"source":"function getVideoElement() {\n    return this.jQuery().children('video').get(0);\n}","funcProperties":{"__isSmartRef__":true,"id":65},"__LivelyClassName__":"lively.Closure"},"64":{"this":{"__isSmartRef__":true,"id":0}},"65":{"user":"Felix","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Mon Oct 13 2014 17:28:17 GMT-0700 (PDT)\")"},"66":{"varMapping":{"__isSmartRef__":true,"id":67},"source":"function showBitrate(bitrate) {\n    if (!this.bitrateLabel) this.addBitrateLabel();\n    \n    this.bitrateLabel.setTextString(bitrate);\n    this.bitrateLabel.growOrShrinkToFit();\n    this.bitrateLabel.setPosition(this.getExtent());\n}","funcProperties":{"__isSmartRef__":true,"id":68},"__LivelyClassName__":"lively.Closure"},"67":{"this":{"__isSmartRef__":true,"id":0}},"68":{"user":"Felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Oct 31 2014 12:02:38 GMT-0700 (PDT)\")"},"69":{"varMapping":{"__isSmartRef__":true,"id":70},"source":"function addBitrateLabel() {\n    var label = $world.loadPartItem('Label', 'PartsBin/Text');\n    label.setFontSize(10);\n    label.setFill(Global.Color.white);\n    label.setBorderRadius(2);\n    label.setOpacity(0.9);\n    label.setTextString('---');\n    label.growOrShrinkToFit();\n    label.setExtent(lively.pt(label.getExtent().x, 16));\n    label.setOrigin(label.getExtent().addPt(lively.pt(5, 0)));\n    label.setPosition(this.getExtent());\n    \n    this.bitrateLabel = label;\n    this.addMorph(label);\n}","funcProperties":{"__isSmartRef__":true,"id":71},"__LivelyClassName__":"lively.Closure"},"70":{"this":{"__isSmartRef__":true,"id":0}},"71":{"user":"Felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Oct 31 2014 12:04:30 GMT-0700 (PDT)\")"},"72":{"varMapping":{"__isSmartRef__":true,"id":73},"source":"function isDroppableMedia() {\n    return true;\n}","funcProperties":{"__isSmartRef__":true,"id":74},"__LivelyClassName__":"lively.Closure"},"73":{"this":{"__isSmartRef__":true,"id":0}},"74":{"user":"felix","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Nov 07 2014 14:54:49 GMT-0800 (PST)\")"},"75":{"varMapping":{"__isSmartRef__":true,"id":76},"source":"function onDropOn(aMorph) {\n    if (aMorph.onMorphAdded) {\n        aMorph.onMorphAdded(this);\n    }\n    return false;\n}","funcProperties":{"__isSmartRef__":true,"id":81},"__LivelyClassName__":"lively.Closure"},"76":{"this":{"__isSmartRef__":true,"id":0},"__serializedLivelyClosures__":{"__isSmartRef__":true,"id":77}},"77":{"$super":{"__isSmartRef__":true,"id":78}},"78":{"varMapping":{"__isSmartRef__":true,"id":79},"source":"function () {\n                try {\n                    // FIXME super is supposed to be static\n                    return Object.getPrototypeOf(obj)[name].apply(obj, arguments);\n                } catch (e) {\n                    if ($world)\n                        $world.logError(e, 'Error in $super call')\n                    else\n                        alert('Error in $super call: ' + e + '\\n' + e.stack);\n                    return null;\n                }\n            }","funcProperties":{"__isSmartRef__":true,"id":80},"__LivelyClassName__":"lively.Closure"},"79":{"obj":{"__isSmartRef__":true,"id":0},"name":"onDropOn"},"80":{},"81":{"user":"felix","__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Nov 07 2014 15:05:59 GMT-0800 (PST)\")"},"82":{"varMapping":{"__isSmartRef__":true,"id":83},"source":"function getMediaType() {\n    return 'video/canvas';\n}","funcProperties":{"__isSmartRef__":true,"id":84},"__LivelyClassName__":"lively.Closure"},"83":{"this":{"__isSmartRef__":true,"id":0}},"84":{"user":"felix","tags":[],"__serializedExpressions__":["timestamp"],"timestamp":"new Date(\"Fri Nov 07 2014 15:14:23 GMT-0800 (PST)\")"},"85":{"varMapping":{"__isSmartRef__":true,"id":86},"source":"function onLoad() {\n    this.restoreStreamingConfig();\n}","funcProperties":{"__isSmartRef__":true,"id":87},"__LivelyClassName__":"lively.Closure"},"86":{"this":{"__isSmartRef__":true,"id":0}},"87":{"__serializedExpressions__":["timestamp"],"user":"felix","tags":[],"timestamp":"new Date(\"Tue Dec 16 2014 11:27:57 GMT-0800 (PST)\")"},"88":{"varMapping":{"__isSmartRef__":true,"id":89},"source":"function restoreStreamingConfig() {\n    this.streamingConfig = {\n        mediatype: \"image\",\n        steptime: 100,\n        compressionParameters:  {\n            imgCompression: \"image/webp\",\n            imgQuality: 0.2,\n            lzwCompression: true\n        },\n        record: false\n    }\n}","funcProperties":{"__isSmartRef__":true,"id":90},"__LivelyClassName__":"lively.Closure"},"89":{"this":{"__isSmartRef__":true,"id":0}},"90":{"__serializedExpressions__":["timestamp"],"user":"felix","tags":[],"timestamp":"new Date(\"Tue Dec 16 2014 11:29:30 GMT-0800 (PST)\")"},"91":{"varMapping":{"__isSmartRef__":true,"id":92},"source":"function captureFrame(encoding, quality) {\n    var video = this.getVideoElement();\n    var canvas = document.createElement('canvas');\n    canvas.width = video.width;\n    canvas.height = video.height;\n    var ctx = canvas.getContext('2d');\n    ctx.drawImage(video, 0, 0, video.width, video.height);\n    \n    return canvas.toDataURL(encoding, quality);\n}","funcProperties":{"__isSmartRef__":true,"id":93},"__LivelyClassName__":"lively.Closure"},"92":{"this":{"__isSmartRef__":true,"id":0}},"93":{"__serializedExpressions__":["timestamp"],"user":"felix","timestamp":"new Date(\"Tue Dec 16 2014 11:37:51 GMT-0800 (PST)\")"},"isSimplifiedRegistry":true}}