Skip to content

Commit

Permalink
WEB-1389 (#3555)
Browse files Browse the repository at this point in the history
* Added FilterMaterial and related types to export list

* Handled WEB-1389
  • Loading branch information
AlexandruPopovici authored Nov 26, 2024
1 parent 5f1e0a0 commit 68bbedc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
10 changes: 9 additions & 1 deletion packages/viewer/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,11 @@ import { DepthNormalPass } from './modules/pipeline/Passes/DepthNormalPass.js'
import { BasitPass } from './modules/pipeline/Passes/BasitPass.js'
import { ProgressiveAOPass } from './modules/pipeline/Passes/ProgressiveAOPass.js'
import { TAAPass } from './modules/pipeline/Passes/TAAPass.js'
import {
FilterMaterial,
FilterMaterialOptions,
FilterMaterialType
} from './modules/materials/Materials.js'

export {
Viewer,
Expand Down Expand Up @@ -201,7 +206,10 @@ export {
MRTShadedViewPipeline,
MRTPenViewPipeline,
ViewModes,
ViewMode
ViewMode,
FilterMaterial,
FilterMaterialType,
FilterMaterialOptions
}

export type {
Expand Down
6 changes: 2 additions & 4 deletions packages/viewer/src/modules/Viewer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,9 @@ export class Viewer extends EventEmitter implements IViewer {
const cs = []
let pt = obj
do {
if ((pt = Object.getPrototypeOf(pt))) cs.push(pt.constructor || null)
if ((pt = Object.getPrototypeOf(pt))) cs.push(pt.constructor.name || null)
} while (pt !== null)
return cs.map(function (c) {
return c ? c.toString().split(/\s|\(/)[1] : null
})
return cs
}

public createExtension<T extends Extension>(type: Constructor<T>): T {
Expand Down

0 comments on commit 68bbedc

Please sign in to comment.