import { ExtensionProperty , IProperty , Nullable , PropertyType } from '@gltf-transform/core' ; import { KHR_MATERIALS_IOR } from '../constants' ; interface IIOR extends IProperty { ior : number ; } /**
 * # IOR
 *
 * Defines index of refraction for a PBR  Material . See  MaterialsIOR .
  export class IOR extends ExtensionProperty < IIOR > { public static EXTENSION_NAME = KHR_MATERIALS_IOR ; public declare extensionName : typeof KHR_MATERIALS_IOR ; public declare propertyType : 'IOR' ; public declare parentTypes : [ PropertyType . MATERIAL ] ; protected init ( ) { this . extensionName = KHR_MATERIALS_IOR ; this . propertyType = 'IOR' ; this . parentTypes = [ PropertyType . MATERIAL ] ; } protected getDefaults ( ) { return Object . assign ( super . getDefaults ( ) as IProperty , { ior : 0 } ) ; } /**********************************************************************************************
     * IOR.
     */ /** IOR. */ public getIOR ( ) { return this . get ( 'ior' ) ; } /** IOR. */ public setIOR ( ior ) { return this . set ( 'ior' , ior ) ; } }