text: // All material copyright ESRI, All Rights Reserved, unless otherwise specified.
  // See https://js.arcgis.com/4.11/esri/copyright.txt for details.
  //>>built
  define("require exports ../../../../core/mathUtils ./TextRenderer ./Texture ../../../webgl/Texture ../../../webgl/capabilities/isWebGL2Context".split(" "),function(m,n,e,f,g,h,k){var l={canvas:null};return function(){function a(a,b,d,c){this._idHint=c;this._requiresPowerOfTwo=!k.default(a.gl);this._renderer=new f.default(b,d)}Object.defineProperty(a.prototype,"id",{get:function(){null==this._id&&(this._id=g.idGen.gen(this._idHint));return this._id},enumerable:!0,configurable:!0});a.prototype.deferredLoading=
  function(){return!1};a.prototype.getWidth=function(){return this._renderer.renderedWidth};a.prototype.getHeight=function(){return this._renderer.renderedHeight};Object.defineProperty(a.prototype,"textureWidth",{get:function(){var a=this.getWidth();return this._requiresPowerOfTwo?e.nextHighestPowerOfTwo(a):a},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"textureHeight",{get:function(){var a=this.getHeight();return this._requiresPowerOfTwo?e.nextHighestPowerOfTwo(a):a},enumerable:!0,
  configurable:!0});Object.defineProperty(a.prototype,"displayWidth",{get:function(){return this._renderer.displayWidth},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"displayHeight",{get:function(){return this._renderer.displayHeight},enumerable:!0,configurable:!0});Object.defineProperty(a.prototype,"texcoordScale",{get:function(){return[this._renderer.renderedWidth/this.textureWidth,this._renderer.renderedHeight/this.textureHeight]},enumerable:!0,configurable:!0});a.prototype.initializeThroughRender=
  function(a,b){var d=f.getTextHelperCanvas(l,this.textureWidth,this.textureHeight),c=d.getContext("2d");c.save();b.samplingMode=9987;b.wrapMode=33071;b.flipped=!0;b.preMultiplyAlpha=!0;b.hasMipmap=!0;this._renderer.render(c,0,this.textureHeight-this._renderer.renderedHeight);a=new h(a,b,d);c.restore();return a};a.prototype.setUnloadFunc=function(a){this._unloadFunc=a};a.prototype.unload=function(){this._unloadFunc&&(this._unloadFunc(this._id),this._unloadFunc=null)};return a}()});