Quickly Find the Right Camera in Your Molecular Scene

Managing complex molecular scenes can be time-consuming, especially when working with multiple cameras. If you’ve ever needed to select a specific camera—or a group of them—based on their name or state, you might have found yourself clicking around endlessly. Fortunately, there’s a simple way to streamline this task using the Node Specification Language (NSL) in SAMSON.

In this post, we’ll look at how you can use the camera attribute space to easily and precisely target the cameras in your molecular scene. These filters give you powerful control and help you focus on what matters most: designing and analyzing molecules more efficiently.

Target cameras with precision

In NSL, camera attributes exist in the camera attribute space, whose short name is ca. This means you can use expressions like ca.name or ca.selected to query or filter cameras. Here’s what you can do with them:

🎯 Select cameras by name

If you’ve named your cameras (e.g. “Angle1”, “TopView”, etc.), you can easily select them using:

Or to select cameras where the name starts with a letter (e.g. L):

This is especially helpful when you’re working with multiple predefined views and want to isolate only some of them.

🟢 Detect which cameras are selected

Want to know which cameras are currently selected? Use:

Conversely, to see only the ones that are not selected:

This way, you can act specifically on unselected cameras, or simply audit your scene.

🚥 Use selection flags for temporary filters

Sometimes, you might tag cameras temporarily without wanting to change their selection state. This is where the selectionFlag attribute shines.

or

This is a useful trick when you’re scripting or automating the application of transformations or image exports to a subset of cameras.

What’s inherited from nodes?

These attributes are inherited from the general node attribute space, but with slight differences in short names (for instance, selected doesn’t have an s short name in the camera space).

Here is the table from the documentation for quick reference:

Camera attributes table

Save time in scene management

This approach is especially valuable when you’re preparing animations, simulations, or presentations, and need to rotate through multiple camera angles quickly and precisely. Node filters, especially on specialized node types like cameras, help minimize UI overhead and speed up your workflow.

You can learn more by visiting the full documentation page: https://documentation.samson-connect.net/users/latest/nsl/camera/

SAMSON and all SAMSON Extensions are free for non-commercial use. You can download SAMSON at https://www.samson-connect.net.

Comments are closed.