Understanding Mesh Attributes in SAMSON’s Node Specification Language

For molecular modelers using SAMSON, understanding the attributes of mesh nodes can greatly enhance workflow efficiency and precision. These mesh-specific attributes, defined in the Node Specification Language (NSL), allow users to filter and interact with mesh nodes based on properties like visibility, material ownership, and selection state. In this post, we’ll focus on the basics of mesh attributes, their syntax, and the typical use cases for molecular modeling.

What Are Mesh Attributes?

The mesh attribute space (short name: me) in NSL is designed specifically for mesh nodes within molecular designs. It enables users to efficiently identify and query mesh-specific properties. These attributes often inherit properties from the general node attribute space but are tailored to work exclusively with meshes.

Main Mesh Attributes

Here’s an overview of some of the most commonly used mesh attributes and how to interact with them:

Attribute Name Short Name Possible Values Examples
hasMaterial hm true, false me.hm, not me.hm
hidden h true, false me.h, not me.h
name n strings in quotes me.n "A", me.n "L*"
ownsMaterial om true, false me.om

Practical Use Cases

Here are some scenarios where using mesh attributes can improve your workflow in SAMSON:

  • Filtering Based on Visibility: Use the visible attribute (short name: v) to identify meshes that are currently displayed or hidden in the scene. For example, me.v retrieves all visible meshes, while not me.v finds all hidden ones.
  • Locating Materials: The ownsMaterial attribute (short name: om) checks whether a mesh owns a material. This is particularly handy when dealing with complex scenes containing multiple materials.
  • Naming Filters: Use the name attribute (short name: n) to find meshes with specific naming conventions. For instance, query me.n "Protein*" to filter for all meshes starting with the keyword “Protein”.

Key Advantages of Using Mesh Attributes

Integrating mesh attribute searches into your molecular modeling processes brings several benefits. It provides precise query control, reduces manual selection errors, and allows for automated workflows where attributes define inclusion or exclusion criteria.

Learn More and Get Started

These are just some of the capabilities offered by mesh attributes in the Node Specification Language. Mastering their use will allow you to tackle large molecular models with more efficiency and precision. To dive deeper into the details of mesh attributes, check out the official documentation page: documentation.samson-connect.net/users/latest/nsl/mesh/.

SAMSON and all SAMSON Extensions are free for non-commercial use. You can download SAMSON here.

Comments are closed.