diff --git a/src/mol-plugin/behavior/dynamic/volume-streaming/behavior.ts b/src/mol-plugin/behavior/dynamic/volume-streaming/behavior.ts index 6dbc53ea78ca7a90e2e4dd9afc17c94f0ccb0e0d..61d55195d57013528575bcecf7eaa41f2731ce41 100644 --- a/src/mol-plugin/behavior/dynamic/volume-streaming/behavior.ts +++ b/src/mol-plugin/behavior/dynamic/volume-streaming/behavior.ts @@ -31,6 +31,7 @@ export namespace VolumeStreaming { return PD.Group({ isoValue: createIsoValueParam(defaultValue, stats), color: PD.Color(color), + wireframe: PD.Boolean(false), opacity: PD.Numeric(0.3, { min: 0, max: 1, step: 0.01 }) }, { label, isExpanded: true }); } @@ -78,7 +79,7 @@ export namespace VolumeStreaming { type RT = typeof createParams extends (...args: any[]) => (infer T) ? T : never export type Params = RT extends PD.Params ? PD.Values<RT> : {} - type ChannelsInfo = { [name in ChannelType]?: { isoValue: VolumeIsoValue, color: Color, opacity: number } } + type ChannelsInfo = { [name in ChannelType]?: { isoValue: VolumeIsoValue, color: Color, wireframe: boolean, opacity: number } } type ChannelsData = { [name in 'EM' | '2FO-FC' | 'FO-FC']?: VolumeData } export type ChannelType = 'em' | '2fo-fc' | 'fo-fc(+ve)' | 'fo-fc(-ve)' @@ -86,6 +87,7 @@ export namespace VolumeStreaming { interface ChannelInfo { data: VolumeData, color: Color, + wireframe: boolean, isoValue: VolumeIsoValue.Relative, opacity: number } @@ -267,6 +269,7 @@ export namespace VolumeStreaming { return { data, color: i.color, + wireframe: i.wireframe, opacity: i.opacity, isoValue: i.isoValue.kind === 'relative' ? i.isoValue : VolumeIsoValue.toRelative(i.isoValue, stats) }; diff --git a/src/mol-plugin/behavior/dynamic/volume-streaming/transformers.ts b/src/mol-plugin/behavior/dynamic/volume-streaming/transformers.ts index 8dd2be858575fc55f058fc4b57c166d963e22468..5a2228f6b805fae7cb9369dfbd351b91acc3abc4 100644 --- a/src/mol-plugin/behavior/dynamic/volume-streaming/transformers.ts +++ b/src/mol-plugin/behavior/dynamic/volume-streaming/transformers.ts @@ -198,6 +198,7 @@ const VolumeStreamingVisual = PluginStateTransform.BuiltIn({ function createVolumeProps(streaming: VolumeStreaming.Behavior, channelName: VolumeStreaming.ChannelType) { const channel = streaming.channels[channelName]!; - return VolumeRepresentation3DHelpers.getDefaultParamsStatic(streaming.plugin, 'isosurface', - { isoValue: channel.isoValue, alpha: channel.opacity }, 'uniform', { value: channel.color }); + return VolumeRepresentation3DHelpers.getDefaultParamsStatic(streaming.plugin, + 'isosurface', { isoValue: channel.isoValue, alpha: channel.opacity, visuals: channel.wireframe ? ['wireframe'] : ['solid'] }, + 'uniform', { value: channel.color }); } \ No newline at end of file