specular

package
v0.11.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2019 License: BSD-2-Clause Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ExtensionName defines the PBRSpecularGlossiness unique key.
	ExtensionName = "KHR_materials_pbrSpecularGlossiness"
)

Variables

This section is empty.

Functions

func Unmarshal added in v0.10.0

func Unmarshal(data []byte) (interface{}, error)

Unmarshal decodes the json data into the correct type.

Types

type PBRSpecularGlossiness

type PBRSpecularGlossiness struct {
	DiffuseFactor             *gltf.RGBA        `json:"diffuseFactor,omitempty"`
	DiffuseTexture            *gltf.TextureInfo `json:"diffuseTexture,omitempty"`
	SpecularFactor            *gltf.RGB         `json:"specularFactor,omitempty"`
	GlossinessFactor          *float64          `json:"glossinessFactor,omitempty" validate:"omitempty,gte=0,lte=1"`
	SpecularGlossinessTexture *gltf.TextureInfo `json:"specularGlossinessTexture,omitempty"`
}

PBRSpecularGlossiness defines a specular-glossiness material model.

func (*PBRSpecularGlossiness) MarshalJSON

func (p *PBRSpecularGlossiness) MarshalJSON() ([]byte, error)

MarshalJSON marshal the pbr with the correct default values.

func (*PBRSpecularGlossiness) UnmarshalJSON

func (p *PBRSpecularGlossiness) UnmarshalJSON(data []byte) error

UnmarshalJSON unmarshal the pbr with the correct default values.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL