Skip to content

KBE3D / KBCore / materials / TextMaterial

类: TextMaterial

面状: 文字贴图材质 - Primitive使用

继承

属性

DefaultImageId

static DefaultImageId: string

Gets or sets the default texture uniform value.

继承自

Material.DefaultImageId


DefaultCubeMapId

static DefaultCubeMapId: string

Gets or sets the default cube map texture uniform value.

继承自

Material.DefaultCubeMapId


ColorType

readonly static ColorType: string

Gets the name of the color material.

继承自

Material.ColorType


ImageType

readonly static ImageType: string

Gets the name of the image material.

继承自

Material.ImageType


DiffuseMapType

readonly static DiffuseMapType: string

Gets the name of the diffuce map material.

继承自

Material.DiffuseMapType


AlphaMapType

readonly static AlphaMapType: string

Gets the name of the alpha map material.

继承自

Material.AlphaMapType


SpecularMapType

readonly static SpecularMapType: string

Gets the name of the specular map material.

继承自

Material.SpecularMapType


EmissionMapType

readonly static EmissionMapType: string

Gets the name of the emmision map material.

继承自

Material.EmissionMapType


BumpMapType

readonly static BumpMapType: string

Gets the name of the bump map material.

继承自

Material.BumpMapType


NormalMapType

readonly static NormalMapType: string

Gets the name of the normal map material.

继承自

Material.NormalMapType


GridType

readonly static GridType: string

Gets the name of the grid material.

继承自

Material.GridType


StripeType

readonly static StripeType: string

Gets the name of the stripe material.

继承自

Material.StripeType


CheckerboardType

readonly static CheckerboardType: string

Gets the name of the checkerboard material.

继承自

Material.CheckerboardType


DotType

readonly static DotType: string

Gets the name of the dot material.

继承自

Material.DotType


WaterType

readonly static WaterType: string

Gets the name of the water material.

继承自

Material.WaterType


RimLightingType

readonly static RimLightingType: string

Gets the name of the rim lighting material.

继承自

Material.RimLightingType


FadeType

readonly static FadeType: string

Gets the name of the fade material.

继承自

Material.FadeType


PolylineArrowType

readonly static PolylineArrowType: string

Gets the name of the polyline arrow material.

继承自

Material.PolylineArrowType


PolylineDashType

readonly static PolylineDashType: string

Gets the name of the polyline glow material.

继承自

Material.PolylineDashType


PolylineGlowType

readonly static PolylineGlowType: string

Gets the name of the polyline glow material.

继承自

Material.PolylineGlowType


PolylineOutlineType

readonly static PolylineOutlineType: string

Gets the name of the polyline outline material.

继承自

Material.PolylineOutlineType


ElevationContourType

readonly static ElevationContourType: string

Gets the name of the elevation contour material.

继承自

Material.ElevationContourType


ElevationRampType

readonly static ElevationRampType: string

Gets the name of the elevation contour material.

继承自

Material.ElevationRampType


SlopeRampMaterialType

readonly static SlopeRampMaterialType: string

Gets the name of the slope ramp material.

继承自

Material.SlopeRampMaterialType


AspectRampMaterialType

readonly static AspectRampMaterialType: string

Gets the name of the aspect ramp material.

继承自

Material.AspectRampMaterialType


ElevationBandType

readonly static ElevationBandType: string

Gets the name of the elevation band material.

继承自

Material.ElevationBandType


WaterMaskType

readonly static WaterMaskType: string

Gets the name of the water mask material.

继承自

Material.WaterMaskType


type

type: string

The material type. Can be an existing type or a new type. If no type is specified in fabric, type is a GUID.

继承自

Material.type


shaderSource

shaderSource: string

The glsl shader source for this material.

继承自

Material.shaderSource


materials

materials: any

Maps sub-material names to Material objects.

继承自

Material.materials


uniforms

uniforms: any

Maps uniform names to their values.

继承自

Material.uniforms


translucent

translucent: boolean | (...params: any[]) => any

When <code>true</code> or a function that returns <code>true</code>, the geometry is expected to appear translucent.

继承自

Material.translucent

方法

fromType()

static fromType(type: string, uniforms?: any): Material

Creates a new material using an existing material type. <br /><br /> Shorthand for: new Material({fabric : {type : type}});

参数

type

string

The base material type.

uniforms?

any

Overrides for the default uniforms.

返回

Material

New material object.

示例

ts
const material = Cesium.Material.fromType('Color', {
  color: new Cesium.Color(1.0, 0.0, 0.0, 1.0)
});

继承自

Material.fromType


fromTypeAsync()

static fromTypeAsync(type: string, uniforms?: any): Promise<Material>

Creates a new material using an existing material type and returns a promise that resolves when all of the material's resources have been loaded.

参数

type

string

The base material type.

uniforms?

any

Overrides for the default uniforms.

返回

Promise<Material>

A promise that resolves to a new material object when all resources are loaded.

示例

ts
const material = await Cesium.Material.fromTypeAsync('Image', {
   image: '../Images/Cesium_Logo_overlay.png'
});

继承自

Material.fromTypeAsync


isTranslucent()

isTranslucent(): boolean

Gets whether or not this material is translucent.

返回

boolean

true if this material is translucent, false otherwise.

继承自

Material.isTranslucent


isDestroyed()

isDestroyed(): boolean

Returns true if this object was destroyed; otherwise, false. <br /><br /> If this object was destroyed, it should not be used; calling any function other than <code>isDestroyed</code> will result in a DeveloperError exception.

返回

boolean

True if this object was destroyed; otherwise, false.

继承自

Material.isDestroyed


destroy()

destroy(): void

Destroys the WebGL resources held by this object. Destroying an object allows for deterministic release of WebGL resources, instead of relying on the garbage collector to destroy this object. <br /><br /> Once an object is destroyed, it should not be used; calling any function other than <code>isDestroyed</code> will result in a DeveloperError exception. Therefore, assign the return value (<code>undefined</code>) to the object as done in the example.

返回

void

示例

ts
material = material && material.destroy();

继承自

Material.destroy

构造函数

构造函数

new TextMaterial(options?: TextMaterialOptions): TextMaterial

参数

options?

TextMaterialOptions = {}

返回

TextMaterial

重写了

Material.constructor

KBE3D @3.0.0 Copyright © 2024-present KBE3D