FatLineBufferGeometry
This is a dedicated geometry for FatLineSegments| FatLineSegments.
This is a dedicated geometry for FatLineSegments| FatLineSegments.
Extends
Constructors
Constructor
new FatLineBufferGeometry(
geometry):FatLineBufferGeometry
Creates an instance of FatLineBufferGeometry. geometry layout must be LineSegment
Parameters
geometry
BufferGeometry<LineList>
Returns
FatLineBufferGeometry
Memberof
FatLineBufferGeometry
Overrides
InstancedBufferGeometry.constructor
Properties
name
name:
string
The name of viewer, which could be empty.
Inherited from
isBufferGeometry
isBufferGeometry:
boolean
Flag to indicate the type of this class. This value should not be changed by user.
Inherited from
InstancedBufferGeometry.isBufferGeometry
parameters
parameters:
object
This object is used to record all parameters which are set when instance is initialized. But, change the value of this object may not change the geometry directly.
Inherited from
InstancedBufferGeometry.parameters
meshBVH?
optionalmeshBVH?:MeshBVH
Use BVH to accelerate rendering. This value usually dose not need you to change it, it is built by the engine automatically.
Inherited from
InstancedBufferGeometry.meshBVH
_index
_index:
Nullable<IndexBufferAttribute>
Allows for vertices to be re-used across multiple triangles; this is called using “indexed triangles”.
and works much the same as it does in Geometry: each triangle is associated with the indices of three vertices.
This attribute therefore stores the index of each vertex for each triangular face.
If this attribute is not set, the renderer assumes that each three contiguous positions represent a single triangle.
This should be set by setIndex| setIndex() to avoid error.
Default Value
null
Inherited from
InstancedBufferGeometry._index
attributes
attributes:
object
Core data of Geometry such as vertex positions, normals, UVs and color.
Index Signature
[index: string]: BufferAttribute<TypedArray>
Tips
It’s better to use addAttribute| addAttribute() or setAttribute| setAttribute() to change this.
Remarks
See BufferAttribute for more details.
Inherited from
InstancedBufferGeometry.attributes
drawRange
drawRange:
BufferRange
Determines which part of buffer will be rendered.
Deprecated
Default Value
{ start: 0, count: Infinity } All data will be uploaded.
Inherited from
InstancedBufferGeometry.drawRange
__topologyMark
__topologyMark:
TriangleList
Inherited from
InstancedBufferGeometry.__topologyMark
isLineSegmentsGeometry
isLineSegmentsGeometry:
boolean
Used to check type of this or extended instance. This value should not be changed by user.
id
id:
number
Inherited from
isInstancedBufferGeometry
isInstancedBufferGeometry:
boolean
Used to check type of this or extended instance. This value should not be changed by user.
Inherited from
InstancedBufferGeometry.isInstancedBufferGeometry
type
type:
string
The type of this instance.
Inherited from
userData
readonlyuserData:Record<keyofany,any>
Inherited from
InstancedBufferGeometry.userData
_uuid
_uuid:
any
Inherited from
uuid
uuid:
string
Inherited from
_listeners
_listeners:
Map<Symbol,Listener<never>[]>
Inherited from
InstancedBufferGeometry._listeners
Accessors
index
Get Signature
get index():
IndexBufferAttribute
Returns
IndexBufferAttribute
Set Signature
set index(
v):void
Parameters
v
IndexBufferAttribute
Returns
void
Inherited from
position
Get Signature
get position():
BufferAttribute<TypedArray>
Returns
BufferAttribute<TypedArray>
Inherited from
InstancedBufferGeometry.position
uv
Get Signature
get uv():
BufferAttribute<TypedArray>
Returns
BufferAttribute<TypedArray>
Inherited from
fallback
Get Signature
get fallback():
BufferGeometry<LineList>
Returns
BufferGeometry<LineList>
instanceStart
Get Signature
get instanceStart():
InstancedBufferAttribute<Float32Array<ArrayBufferLike>>
Returns
InstancedBufferAttribute<Float32Array<ArrayBufferLike>>
instanceEnd
Get Signature
get instanceEnd():
InstancedBufferAttribute<Float32Array<ArrayBufferLike>>
Returns
InstancedBufferAttribute<Float32Array<ArrayBufferLike>>
instancedCount
Get Signature
get instancedCount():
number
Returns
number
Set Signature
set instancedCount(
v):void
Parameters
v
number
Returns
void
Inherited from
InstancedBufferGeometry.instancedCount
businessTag
Get Signature
get businessTag():
string
Returns
string
Set Signature
set businessTag(
v):void
Parameters
v
string
Returns
void
Inherited from
InstancedBufferGeometry.businessTag
Methods
getGroup()
getGroup(
index):BufferGroup|undefined
get group at index
Parameters
index
number
Returns
BufferGroup | undefined
Inherited from
InstancedBufferGeometry.getGroup
setGroup()
setGroup(
group,index):void
Split the data into different groups.
Parameters
group
BufferGroup
index
number
Returns
void
Inherited from
InstancedBufferGeometry.setGroup
setGroups()
setGroups(
groups):this
set entire groups
Parameters
groups
BufferGroup[]
Returns
this
Inherited from
InstancedBufferGeometry.setGroups
pushGroup()
pushGroup(
group):this
push a group
Parameters
group
BufferGroup
Returns
this
Inherited from
InstancedBufferGeometry.pushGroup
addGroup()
addGroup(
start,count,materialIndex?):void
Split geometry data to a new group.
Parameters
start
number
count
number
materialIndex?
number
Returns
void
Remarks
See groups| groups for more details.
Inherited from
InstancedBufferGeometry.addGroup
clearGroups()
clearGroups():
void
Clean all objects in the groups| groups.
Returns
void
Inherited from
InstancedBufferGeometry.clearGroups
getBoundingBox()
getBoundingBox():
Box3
If boundingBox| boundingBox is null, it will be calculated a new one.
Returns
Inherited from
InstancedBufferGeometry.getBoundingBox
getBoundingSphere()
getBoundingSphere():
Sphere
If boundingSphere| boundingSphere is null, it will be calculated a new one.
Returns
Inherited from
InstancedBufferGeometry.getBoundingSphere
notifyShapeChanged()
notifyShapeChanged():
void
Clear the bounding box and sphere and recalculate them later.
Returns
void
Inherited from
InstancedBufferGeometry.notifyShapeChanged
getAttributeLayoutKey()
getAttributeLayoutKey():
string
Generate a hash key according to index| index and all attributes| attributes.
Returns
string
Inherited from
InstancedBufferGeometry.getAttributeLayoutKey
className()
className():
string
The name of instance’s class.
Returns
string
Inherited from
InstancedBufferGeometry.className
attributeChanged()
attributeChanged():
void
Clean old data of engine and load new data in next update.
Returns
void
Inherited from
InstancedBufferGeometry.attributeChanged
getBufferGeometry()
getBufferGeometry():
this
Return current instance of this class.
Returns
this
Inherited from
InstancedBufferGeometry.getBufferGeometry
getLineBufferGeometry()
getLineBufferGeometry():
this
Return current instance of this class.
Returns
this
Inherited from
InstancedBufferGeometry.getLineBufferGeometry
getIndex()
getIndex():
IndexBufferAttribute
Return the instance of index| index.
Returns
IndexBufferAttribute
Inherited from
InstancedBufferGeometry.getIndex
onAttributeUpdate()
onAttributeUpdate():
void
Call this method to let engine refresh data of meshBVH.
Returns
void
Inherited from
InstancedBufferGeometry.onAttributeUpdate
setIndex()
setIndex(
index):this
Use this method to set new index| index for geometry.
Parameters
index
TypedArray | number[] | IndexBufferAttribute
source data of the index.
Returns
this
Inherited from
InstancedBufferGeometry.setIndex
addAttribute()
addAttribute(
name,attribute):this
Parameters
name
string
attribute
Returns
this
Inherited from
InstancedBufferGeometry.addAttribute
setAttribute()
setAttribute(
name,attribute):this
Change the given attributes| attributes for geometry.
Parameters
name
string
the name of data such as position, uv and normal.
attribute
source data. see BufferAttribute for more details.
Returns
this
Inherited from
InstancedBufferGeometry.setAttribute
addOrSetAttribute()
addOrSetAttribute(
name,array,itemSize):void
Get specified attributes| attributes from geometry.
Parameters
name
string
the name of target attributes.
array
TypedArray
itemSize
number
Returns
void
Inherited from
InstancedBufferGeometry.addOrSetAttribute
getAttribute()
getAttribute(
name):BufferAttribute<TypedArray> |undefined
Parameters
name
string
Returns
BufferAttribute<TypedArray> | undefined
Inherited from
InstancedBufferGeometry.getAttribute
removeAttribute()
removeAttribute(
name):this
Remove specified attributes| attributes from geometry.
Parameters
name
string
the name of target attributes.
Returns
this
Inherited from
InstancedBufferGeometry.removeAttribute
removeAndDestroyAttribute()
removeAndDestroyAttribute(
name):this
Parameters
name
string
Returns
this
Inherited from
InstancedBufferGeometry.removeAndDestroyAttribute
getGroupByVertexIndex()
getGroupByVertexIndex(
index):object
Find the group which the vertex belong to.
Parameters
index
number
Queried vertex index.
Returns
object
group
group:
BufferGroup
groupIndex
groupIndex:
number
Inherited from
InstancedBufferGeometry.getGroupByVertexIndex
setDrawRange()
setDrawRange(
start,count):void
Change the value of drawRange.
Parameters
start
number
count
number
Returns
void
Deprecated
Inherited from
InstancedBufferGeometry.setDrawRange
_computeGroups()
_computeGroups(
geometry):void
Parameters
geometry
Geometry
Returns
void
Inherited from
InstancedBufferGeometry._computeGroups
getUUID()
getUUID():
string
UUID of this BufferGeometries instance. This gets automatically assigned, so this shouldn’t be edited.
Returns
string
Inherited from
InstancedBufferGeometry.getUUID
serialize()
serialize(
ctx):void
Store the attributes of this class into string as serializing format.
Parameters
ctx
Serializer
this parameter has not supported external Serializer yet. It may cause that this method can not be used directly.
Returns
void
Inherited from
InstancedBufferGeometry.serialize
deserialize()
deserialize(
ctx):void
Parse the data for this class from string according to serializing format.
Parameters
ctx
Deserializer
this parameter has not supported external Deserializer yet. It may cause that this method can not be used directly.
Returns
void
Inherited from
InstancedBufferGeometry.deserialize
destroy()
destroy():
void
Returns
void
Inherited from
InstancedBufferGeometry.destroy
destroyAttributes()
destroyAttributes():
void
Returns
void
Inherited from
InstancedBufferGeometry.destroyAttributes
freeAttributesGpuResource()
freeAttributesGpuResource():
void
Returns
void
Inherited from
InstancedBufferGeometry.freeAttributesGpuResource
destroyAllResourcesOwned()
destroyAllResourcesOwned():
void
Returns
void
Inherited from
InstancedBufferGeometry.destroyAllResourcesOwned
freeAllGpuResourceOwned()
freeAllGpuResourceOwned():
void
Returns
void
Inherited from
InstancedBufferGeometry.freeAllGpuResourceOwned
forceCastTopology()
forceCastTopology<
R>():BufferGeometry<R>
Type Parameters
R
R extends Topology
Returns
Inherited from
InstancedBufferGeometry.forceCastTopology
applyMatrix()
applyMatrix(
matrix):FatLineBufferGeometry
Apply the given matrix to vertexes data.
Parameters
matrix
Returns
FatLineBufferGeometry
this object.
setPositions()
setPositions(
lineSegments):FatLineBufferGeometry
Build segmented line data by given data and update bounding.
Parameters
lineSegments
Float32Array
the segments data store as Float32Array.
Returns
FatLineBufferGeometry
this object.
computeBoundingBox()
computeBoundingBox():
void
Recalculate the bounding box for this geometry.
Returns
void
Overrides
InstancedBufferGeometry.computeBoundingBox
computeBoundingSphere()
computeBoundingSphere():
void
Recalculate the bounding sphere for this geometry.
Returns
void
Overrides
InstancedBufferGeometry.computeBoundingSphere
freeGPU()
freeGPU():
void
Clear the current geometry’s data in memory.
Returns
void
Overrides
InstancedBufferGeometry.freeGPU
notifyGeometryContentChange()
notifyGeometryContentChange():
void
Returns
void
Inherited from
InstancedBufferGeometry.notifyGeometryContentChange
copy()
copy(
source):this
Copy the data to this object from source. This method need override in derived classes to copy extended data.
Parameters
source
the data source.
Returns
this
Inherited from
clone()
clone():
InstancedBufferGeometry
Create a clone of this instance.
Returns
Inherited from
markBusinessTag()
markBusinessTag(
v):this
Parameters
v
string
Returns
this
Inherited from
InstancedBufferGeometry.markBusinessTag
isDestroyed()
isDestroyed():
boolean
Returns
boolean
Inherited from
InstancedBufferGeometry.isDestroyed
validate()
validate():
void
Returns
void
Inherited from
InstancedBufferGeometry.validate
on()
on<
T>(_type,_listener):void
Adds a listener to an event type.
Type Parameters
T
T
Parameters
_type
EventType<T>
_listener
Listener<T>
Returns
void
Inherited from
once()
once<
T>(_type,_listener):void
Only active the listener one times and then off it| it.
Type Parameters
T
T
Parameters
_type
EventType<T>
_listener
Listener<T>
Returns
void
Inherited from
has()
has<
T>(_type,_listener):boolean
Checks if listener is added to an event type.
Type Parameters
T
T
Parameters
_type
EventType<T>
_listener
Listener<T>
Returns
boolean
Inherited from
off()
off<
T>(_type,_listener):void
Removes a listener from listening list.
Type Parameters
T
T
Parameters
_type
EventType<T>
_listener
Listener<T>
Returns
void
Inherited from
emit()
Call Signature
emit(
type):void
Active the event and call the registered listener.
Parameters
type
EventType<never>
Returns
void
Inherited from
Call Signature
emit<
T>(type,payload):void
Type Parameters
T
T
Parameters
type
EventType<T>
payload
T
Returns
void
Inherited from
clearAllListeners()
clearAllListeners():
void
Removes all listeners from listening list.
Returns
void