Exemplo n.º 1
0
        //--------------------//

        #region Reference control
        /// <summary>
        /// Calls <see cref="Asset.HoldReference"/> for all contained <see cref="XTexture"/>s.
        /// </summary>
        public void HoldReference()
        {
            if (DiffuseMaps != null)
            {
                foreach (var texture in DiffuseMaps.WhereNotNull())
                {
                    texture.HoldReference();
                }
            }
            NormalMap?.HoldReference();
            HeightMap?.HoldReference();
            SpecularMap?.HoldReference();
            EmissiveMap?.HoldReference();
        }