DOI: 10.5281/zenodo.4079182
title: EMIIA.AI (NEURALMAN)

description: &lt;!DOCTYPE html&gt;<br> &lt;!--<br> NOTES:<br> 1. All tokens are represented by '$' sign in the template.<br> 2. You can write your code only wherever mentioned.<br> 3. All occurrences of existing tokens will be replaced by their appropriate values.<br> 4. Blank lines will be removed automatically.<br> 5. Remove unnecessary comments before creating your template.<br> --&gt;<br> &lt;html&gt;<br> &lt;head&gt;<br> &lt;meta charset="UTF-8"&gt;<br> &lt;meta name="authoring-tool" content="Adobe_Animate_CC"&gt;<br> &lt;title&gt;man1&lt;/title&gt;<br> &lt;!-- write your code here --&gt;<br> &lt;script src="https://code.createjs.com/createjs-2015.11.26.min.js"&gt;&lt;/script&gt;<br> &lt;script src="https://emiia.github.io/svg/man3.js"&gt;&lt;/script&gt;<br> &lt;script&gt;<br> var canvas, stage, exportRoot, anim_container, dom_overlay_container, fnStartAnimation;<br> function init() {<br> canvas = document.getElementById("canvas");<br> anim_container = document.getElementById("animation_container");<br> dom_overlay_container = document.getElementById("dom_overlay_container");<br> var comp=AdobeAn.getComposition("CE752CCBB48F054A8D32F2E6A8EB7A08");<br> var lib=comp.getLibrary();<br> handleComplete({},comp);<br> }<br> function handleComplete(evt,comp) {<br> //This function is always called, irrespective of the content. You can use the variable "stage" after it is created in token create_stage.<br> var lib=comp.getLibrary();<br> var ss=comp.getSpriteSheet();<br> exportRoot = new lib.man1();<br> stage = new lib.Stage(canvas);<br> //Registers the "tick" event listener.<br> fnStartAnimation = function() {<br> stage.addChild(exportRoot);<br> createjs.Ticker.setFPS(lib.properties.fps);<br> createjs.Ticker.addEventListener("tick", stage);<br> }<br> //Code to support hidpi screens and responsive scaling.<br> function makeResponsive(isResp, respDim, isScale, scaleType) {<br> var lastW, lastH, lastS=1;<br> window.addEventListener('resize', resizeCanvas);<br> resizeCanvas();<br> function resizeCanvas() {<br> var w = lib.properties.width, h = lib.properties.height;<br> var iw = window.innerWidth, ih=window.innerHeight;<br> var pRatio = window.devicePixelRatio || 1, xRatio=iw/w, yRatio=ih/h, sRatio=0.5;<br> if(isResp) {<br> if((respDim=='width'&&lastW==iw) || (respDim=='height'&&lastH==ih)) {<br> sRatio = lastS;<br> }<br> else if(!isScale) {<br> if(iw&lt;w || ih&lt;h)<br> sRatio = Math.min(xRatio, yRatio);<br> }<br> else if(scaleType==1) {<br> sRatio = Math.min(xRatio, yRatio);<br> }<br> else if(scaleType==2) {<br> sRatio = Math.max(xRatio, yRatio);<br> }<br> }<br> canvas.width = w*pRatio*sRatio;<br> canvas.height = h*pRatio*sRatio;<br> canvas.style.width = dom_overlay_container.style.width = anim_container.style.width = w*sRatio+'px';<br> canvas.style.height = anim_container.style.height = dom_overlay_container.style.height = h*sRatio+'px';<br> stage.scaleX = pRatio*sRatio;<br> stage.scaleY = pRatio*sRatio;<br> lastW = iw; lastH = ih; lastS = sRatio;<br> stage.tickOnUpdate = false;<br> stage.update();<br> stage.tickOnUpdate = true;<br> }<br> }<br> makeResponsive(false,'both',false,1);<br> AdobeAn.compositionLoaded(lib.properties.id);<br> fnStartAnimation();<br> }<br> &lt;/script&gt;<br> &lt;!-- write your code here --&gt;<br> &lt;/head&gt;<br> &lt;body onload="init();" style="margin:0px;"&gt;<br> &lt;div id="animation_container" style="background-color:rgba(); width: px; position: relative; margin: auto; align: center; height:0px"&gt;<br> &lt;canvas id="canvas" width="" height="" style="position: absolute; display: block; background-color:rgba();"&gt;&lt;/canvas&gt;<br> &lt;div id="dom_overlay_container" style="pointer-events:none; overflow:hidden; width:0px; height:0px; position: absolute; left: 0px; top: 0px; display: block;"&gt;<br> &lt;/div&gt;<br> &lt;/div&gt;<br> &lt;/body&gt;<br> &lt;/html&gt;
description: ЭМИИА AI EMIIA.AI