Skip to content

copper3d / Modules / Scene/commonSceneMethod / commonScene

Class: commonScene

Scene/commonSceneMethod.commonScene

Hierarchy

Table of contents

Constructors

Properties

Methods

Constructors

constructor

new commonScene(container, opt?)

Parameters

NameType
containerHTMLDivElement
opt?ICopperSceneOpts

Defined in

src/Scene/commonSceneMethod.ts:48

Properties

camera

camera: PerspectiveCamera | OrthographicCamera

Defined in

src/Scene/commonSceneMethod.ts:29


container

container: HTMLDivElement

Defined in

src/Scene/commonSceneMethod.ts:27


controls

controls: Copper3dTrackballControls | OrbitControls | TrackballControls

Defined in

src/Scene/commonSceneMethod.ts:37


copperOrthographicCamera

copperOrthographicCamera: OrthographicCamera

Defined in

src/Scene/commonSceneMethod.ts:32


copperPerspectiveCamera

copperPerspectiveCamera: PerspectiveCamera

Defined in

src/Scene/commonSceneMethod.ts:31


depthStep

Protected depthStep: number = 0.4

Defined in

src/Scene/commonSceneMethod.ts:44


pickableObjects

Protected pickableObjects: Mesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap>[] = []

Defined in

src/Scene/commonSceneMethod.ts:46


preRenderCallbackFunctions

Protected preRenderCallbackFunctions: preRenderCallbackFunctionType

Defined in

src/Scene/commonSceneMethod.ts:42


renderNrrdVolume

Protected renderNrrdVolume: boolean = false

Defined in

src/Scene/commonSceneMethod.ts:40


scene

scene: Scene

Defined in

src/Scene/commonSceneMethod.ts:28


sort

Protected sort: boolean = true

Defined in

src/Scene/commonSceneMethod.ts:43


subCamera

subCamera: null | PerspectiveCamera = null

Defined in

src/Scene/commonSceneMethod.ts:36


subCopperControl

Protected subCopperControl: null | Controls = null

Defined in

src/Scene/commonSceneMethod.ts:39


subDiv

subDiv: null | HTMLDivElement = null

Defined in

src/Scene/commonSceneMethod.ts:34


subRender

Protected subRender: null | WebGLRenderer = null

Defined in

src/Scene/commonSceneMethod.ts:38


subScene

subScene: Scene

Defined in

src/Scene/commonSceneMethod.ts:35

Methods

addObject

addObject(obj): void

Parameters

NameType
objany

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:107


addPreRenderCallbackFunction

addPreRenderCallbackFunction(callbackFunction): number

Parameters

NameType
callbackFunctionFunction

Returns

number

Defined in

src/Scene/commonSceneMethod.ts:122


addSubView

addSubView(): HTMLDivElement

create a new sub view to display models

Returns

HTMLDivElement

Defined in

src/Scene/commonSceneMethod.ts:174


createDemoMesh

createDemoMesh(): void

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:96


loadDicom

loadDicom(urls, opts?): void

Parameters

NameType
urlsstring | string[]
opts?dicomLoaderOptsType

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:198


loadNrrd

loadNrrd(url, loadingBar, segmentation, callback?, opts?): void

Parameters

NameType
urlstring
loadingBarloadingBarType
segmentationboolean
callback?(volume: any, nrrdMeshes: nrrdMeshesType, nrrdSlices: nrrdSliceType, gui?: GUI) => void
opts?optsType

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:314


loadNrrdTexture3d

loadNrrdTexture3d(url, callback?): void

Parameters

NameType
urlstring
callback?(volume: any, gui?: GUI) => void

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:338


loadOBJ

loadOBJ(url, callback?, opts?): void

Parameters

NameType
urlstring
callback?(mesh: Group<Object3DEventMap>) => void
opts?Object
opts.colorstring

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:350


pickModel

pickModel(content, callback, options?): void

Parameters

NameType
contentGroup<Object3DEventMap>
callback(selectMesh: undefined | Mesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap>) => void
options?string[]

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:132


pickSpecifiedModel

pickSpecifiedModel(content, mousePosition): Object

Parameters

NameType
contentMesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap> | Mesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap>[]
mousePositionmouseMovePositionType

Returns

Object

NameType
intersectedObjectnull | Object3D<Object3DEventMap>
intersectsIntersection<Object3D<Object3DEventMap>>[]

Defined in

src/Scene/commonSceneMethod.ts:154


removePreRenderCallbackFunction

removePreRenderCallbackFunction(id): void

Parameters

NameType
idnumber

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:128


setDepth

setDepth(value): void

Parameters

NameType
valuenumber

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:111


setDicomFilesOrder

setDicomFilesOrder(value): void

Parameters

NameType
value"ascending" | "descending"

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:114


updateControls

updateControls(camera): void

Parameters

NameType
cameraPerspectiveCamera | OrthographicCamera

Returns

void

Defined in

src/Scene/commonSceneMethod.ts:329