/*
All material copyright ESRI, All Rights Reserved, unless otherwise specified.
See https://js.arcgis.com/4.24/esri/copyright.txt for details.
*/
define(["../../chunks/_rollupPluginBabelHelpers","../../chunks/tslib.es6","../../Color","../../core/maybe","../../core/accessorSupport/decorators/property","../../core/arrayUtils","../../core/has","../../core/accessorSupport/ensureType","../../core/accessorSupport/decorators/subclass","./MeshMaterial","./MeshTexture"],(function(e,t,o,i,r,s,l,n,u,c,p){"use strict";var a;let h=a=function(t){function o(e){var o;return(o=t.call(this,e)||this).emissiveColor=null,o.emissiveTexture=null,o.occlusionTexture=null,o.metallic=1,o.roughness=1,o.metallicRoughnessTexture=null,o}e._inheritsLoose(o,t);var r=o.prototype;return r.clone=function(){return this.cloneWithDeduplication(null,new Map)},r.cloneWithDeduplication=function(e,t){const o=i.isSome(e)?e.get(this):null;if(o)return o;const r=new a(this.clonePropertiesWithDeduplication(t));return i.isSome(e)&&e.set(this,r),r},r.clonePropertiesWithDeduplication=function(e){return{...t.prototype.clonePropertiesWithDeduplication.call(this,e),emissiveColor:i.isSome(this.emissiveColor)?this.emissiveColor.clone():null,emissiveTexture:i.isSome(this.emissiveTexture)?this.emissiveTexture.cloneWithDeduplication(e):null,occlusionTexture:i.isSome(this.occlusionTexture)?this.occlusionTexture.cloneWithDeduplication(e):null,metallic:this.metallic,roughness:this.roughness,metallicRoughnessTexture:i.isSome(this.metallicRoughnessTexture)?this.metallicRoughnessTexture.cloneWithDeduplication(e):null}},o}(c);t.__decorate([r.property({type:o,json:{write:!0}})],h.prototype,"emissiveColor",void 0),t.__decorate([r.property({type:p,json:{write:!0}})],h.prototype,"emissiveTexture",void 0),t.__decorate([r.property({type:p,json:{write:!0}})],h.prototype,"occlusionTexture",void 0),t.__decorate([r.property({type:Number,nonNullable:!0,json:{write:!0},range:{min:0,max:1}})],h.prototype,"metallic",void 0),t.__decorate([r.property({type:Number,nonNullable:!0,json:{write:!0},range:{min:0,max:1}})],h.prototype,"roughness",void 0),t.__decorate([r.property({type:p,json:{write:!0}})],h.prototype,"metallicRoughnessTexture",void 0),h=a=t.__decorate([u.subclass("esri.geometry.support.MeshMaterialMetallicRoughness")],h);return h}));
