diff --git a/src/mol-repr/structure/visual/gaussian-density-point.ts b/src/mol-repr/structure/visual/gaussian-density-point.ts index c61ae5745b16ade507a1d381f201aab48042847c..3e260df8c0575e516e67895d1284aad3b4c66474 100644 --- a/src/mol-repr/structure/visual/gaussian-density-point.ts +++ b/src/mol-repr/structure/visual/gaussian-density-point.ts @@ -67,7 +67,6 @@ export function GaussianDensityPointVisual(): UnitsVisual<GaussianDensityPointPa if (newProps.radiusOffset !== currentProps.radiusOffset) state.createGeometry = true if (newProps.smoothness !== currentProps.smoothness) state.createGeometry = true if (newProps.useGpu !== currentProps.useGpu) state.createGeometry = true - if (newProps.ignoreCache !== currentProps.ignoreCache) state.createGeometry = true } }) } \ No newline at end of file diff --git a/src/mol-repr/structure/visual/gaussian-surface-mesh.ts b/src/mol-repr/structure/visual/gaussian-surface-mesh.ts index e39766fd43413f9334d43078a7c502edb8214781..9dc645bbc1dba06ca9c702f06d60eeda2a0d72a3 100644 --- a/src/mol-repr/structure/visual/gaussian-surface-mesh.ts +++ b/src/mol-repr/structure/visual/gaussian-surface-mesh.ts @@ -52,7 +52,6 @@ export function GaussianSurfaceVisual(): UnitsVisual<GaussianSurfaceParams> { if (newProps.radiusOffset !== currentProps.radiusOffset) state.createGeometry = true if (newProps.smoothness !== currentProps.smoothness) state.createGeometry = true if (newProps.useGpu !== currentProps.useGpu) state.createGeometry = true - if (newProps.ignoreCache !== currentProps.ignoreCache) state.createGeometry = true } }) } \ No newline at end of file diff --git a/src/mol-repr/structure/visual/gaussian-surface-wireframe.ts b/src/mol-repr/structure/visual/gaussian-surface-wireframe.ts index 68c31c56ffb903a7853a4adb7dda7ee7e4914bcc..a292ff3e5670aa68e66816cac1dec5a28e1eb80b 100644 --- a/src/mol-repr/structure/visual/gaussian-surface-wireframe.ts +++ b/src/mol-repr/structure/visual/gaussian-surface-wireframe.ts @@ -51,7 +51,6 @@ export function GaussianWireframeVisual(): UnitsVisual<GaussianWireframeParams> if (newProps.radiusOffset !== currentProps.radiusOffset) state.createGeometry = true if (newProps.smoothness !== currentProps.smoothness) state.createGeometry = true if (newProps.useGpu !== currentProps.useGpu) state.createGeometry = true - if (newProps.ignoreCache !== currentProps.ignoreCache) state.createGeometry = true } }) } \ No newline at end of file diff --git a/src/mol-repr/structure/visual/util/gaussian.ts b/src/mol-repr/structure/visual/util/gaussian.ts index 2f268c9835933030d70570eb1b4b86fe3a72150b..a648e2bb65fc3919d523a002e41ece6bd91e9a0c 100644 --- a/src/mol-repr/structure/visual/util/gaussian.ts +++ b/src/mol-repr/structure/visual/util/gaussian.ts @@ -6,8 +6,7 @@ import { Unit, StructureElement, ElementIndex, Structure } from 'mol-model/structure'; import { GaussianDensity } from 'mol-math/geometry/gaussian-density'; -import { Task, RuntimeContext } from 'mol-task'; -import { DensityData } from 'mol-math/geometry'; +import { Task } from 'mol-task'; import { ParamDefinition as PD } from 'mol-util/param-definition'; import { GaussianDensityTexture } from 'mol-math/geometry/gaussian-density/gpu'; import { Texture } from 'mol-gl/webgl/texture'; @@ -20,7 +19,6 @@ export const GaussianDensityParams = { radiusOffset: PD.Numeric(0, { min: 0, max: 10, step: 0.1 }), smoothness: PD.Numeric(1.5, { min: 0.5, max: 2.5, step: 0.1 }), useGpu: PD.Boolean(false), - ignoreCache: PD.Boolean(false), } export const DefaultGaussianDensityProps = PD.getDefaultValues(GaussianDensityParams) export type GaussianDensityProps = typeof DefaultGaussianDensityProps @@ -67,15 +65,6 @@ export function computeUnitGaussianDensityTexture(unit: Unit, props: GaussianDen }); } -export async function computeUnitGaussianDensityCached(unit: Unit, props: GaussianDensityProps, cache: Map<string, DensityData>, ctx: RuntimeContext, webgl?: WebGLContext) { - const key = `${props.radiusOffset}|${props.resolution}|${props.smoothness}` - let density = cache.get(key) - if (density && !props.ignoreCache) return density - density = await computeUnitGaussianDensity(unit, props, webgl).runInContext(ctx) - if (!props.ignoreCache) cache.set(key, density) - return density -} - // function getStructureConformationAndRadius(structure: Structure) {