Ver Fonte

ignoreHydrogens in cellpack presets

Alexander Rose há 5 anos atrás
pai
commit
1f32d5469e
1 ficheiros alterados com 10 adições e 3 exclusões
  1. 10 3
      src/apps/viewer/extensions/cellpack/model.ts

+ 10 - 3
src/apps/viewer/extensions/cellpack/model.ts

@@ -282,19 +282,26 @@ function getReprParams(ctx: PluginContext, params: { representation: 'spacefill'
             return traceOnly
                 ? [
                     ctx.structureRepresentation.registry.get('spacefill'),
-                    () => ({ sizeFactor: 2 })
+                    () => ({ sizeFactor: 2, ignoreHydrogens: true })
+                ] as [any, any]
+                : [
+                    ctx.structureRepresentation.registry.get('spacefill'),
+                    () => ({ ignoreHydrogens: true })
                 ] as [any, any]
-                : ctx.structureRepresentation.registry.get('spacefill')
         case 'gaussian-surface':
             return [
                 ctx.structureRepresentation.registry.get('gaussian-surface'),
                 () => ({
                     quality: 'custom', resolution: 10, radiusOffset: 2,
                     alpha: 1.0, flatShaded: false, doubleSided: false,
+                    ignoreHydrogens: true
                 })
             ] as [any, any]
         case 'point':
-            return ctx.structureRepresentation.registry.get('point')
+            return [
+                ctx.structureRepresentation.registry.get('point'),
+                () => ({ ignoreHydrogens: true })
+            ] as [any, any]
     }
 }