SBColorSchemeConstantIllustrate#

This class describes an illustrative constant color scheme. The colorization is done in the way that it resembles the “Molecule of the Month” style by David S. Goodsell.

Please refer to samson.SBNodeColorScheme.

See also

SAMSON SDK: SBDColorSchemeConstantIllustrate

class samson.SBColorSchemeConstantIllustrate(*args, **kwargs)#

Bases: SBNodeColorScheme

This class describes an illustrative constant color scheme. The colorization is done in the way that it resembles the “Molecule of the Month” style by David S. Goodsell.

Overloaded function.

  1. __init__(self: samson.SBColorSchemeConstantIllustrate) -> None

Constructs a constant color scheme with the white color (1.0, 1.0, 1.0, 1.0).

  1. __init__(self: samson.SBColorSchemeConstantIllustrate, red: float, green: float, blue: float, alpha: float = 1.0) -> None

Constructs a constant color scheme with the given color (red, green, blue, alpha). Arguments should be in the range [0.0, 1.0].

Parameters:
  • red (float) – The red component of RGB-color.

  • green (float) – The green component of RGB-color.

  • blue (float) – The blue component of RGB-color.

  • alpha (float, default=1.0) – The alpha component (transparency).

Examples

>>> constantColorScheme = SBColorSchemeConstant(0.25, 0.5, 0.75, 1.0)
  1. __init__(self: samson.SBColorSchemeConstantIllustrate, red: int, green: int, blue: int, alpha: int = 255) -> None

Constructs a constant color scheme with the given color (red, green, blue, alpha). Arguments should be in the range [0, 255].

Parameters:
  • red (int) – The red component of RGB-color.

  • green (int) – The green component of RGB-color.

  • blue (int) – The blue component of RGB-color.

  • alpha (int, default=255) – The alpha component (transparency).

Examples

>>> constantColorScheme = SBColorSchemeConstant(120, 160, 200, 255)
  1. __init__(self: samson.SBColorSchemeConstantIllustrate, color: samson.SBColor) -> None

Constructs a constant color scheme with the given color.

Parameters:

color (samson.SBColor) – A color