Blender V5.3
blender::nodes::SocketInContext Struct Reference

#include <NOD_node_in_compute_context.hh>

Public Member Functions

#SocketInContext Inline Methods
uint64_t hash () const
ComputeContextHash context_hash () const
const bNodeSocket * operator-> () const
const bNodeSocket & operator* () const
 operator bool () const
NodeInContext owner_node () const

Public Attributes

const ComputeContext * context = nullptr
const bNodeSocket * socket = nullptr

Friends

bool operator== (const SocketInContext &a, const SocketInContext &b)

Detailed Description

Utility struct to pair a socket with a compute context. This uniquely identifies a socket in a node-tree evaluation.

Definition at line 57 of file NOD_node_in_compute_context.hh.

Member Function Documentation

◆ context_hash()

ComputeContextHash blender::nodes::SocketInContext::context_hash ( ) const
inline

Definition at line 143 of file NOD_node_in_compute_context.hh.

References context, and blender::ComputeContext::hash().

Referenced by hash(), and operator==.

◆ hash()

uint64_t blender::nodes::SocketInContext::hash ( ) const
inline

◆ operator bool()

blender::nodes::SocketInContext::operator bool ( ) const
inline

Definition at line 158 of file NOD_node_in_compute_context.hh.

References socket.

◆ operator*()

const bNodeSocket & blender::nodes::SocketInContext::operator* ( ) const
inline

Definition at line 153 of file NOD_node_in_compute_context.hh.

References socket.

◆ operator->()

const bNodeSocket * blender::nodes::SocketInContext::operator-> ( ) const
inline

Definition at line 148 of file NOD_node_in_compute_context.hh.

References socket.

◆ owner_node()

◆ operator==

bool operator== ( const SocketInContext & a,
const SocketInContext & b )
friend

Two sockets in context compare equal if their context hash is equal, not the pointer to the context. This is important as the same compute context may be constructed multiple times.

Definition at line 73 of file NOD_node_in_compute_context.hh.

References b, context_hash(), and socket.

Member Data Documentation

◆ context

◆ socket


The documentation for this struct was generated from the following file: