Match


Description

Match determines whether an element (such as a 3D object, or an edge, point, or polygon) matches the filter requirements. Softimage uses the Match callback to filter selections in 3D views and the schematic. For subcomponent filters, however, Softimage will use Subset, if it exists, instead of Match to filter the selection.

Match returns True to keep an element, and False to filter the element out.

You can implement a custom filter by writing a single callback: the Match callback. All filters must implement Match, and can optionally implement two additional callbacks: Subset and Filter Callbacks.


Applies To

Custom Filters


Syntax

public class <filter_name>

{

	public bool Match( Context in_context )

	{

		...

	}

}
CStatus <filter_name>_Match( CRef& in_context )

{ 

	... 

}
function <filter_name>_Match( in_context )

{ 

	... 

}
def <filter_name>_Match( in_context ):

	...
Function <filter_name>_Match( in_context )

	...

End Function
sub <filter_name>_Match 

{ 

	my $in_context = shift; 

}

<filter_name> is the name specified in the call to PluginRegistrar.RegisterFilter, with any spaces converted to underscores.


Parameters

Parameter Language Type Description
in_context Scripting and C# Context Context.Source returns the Filter.
C++ CRef& A reference to the Context object. Context::GetSource returns the Filter.


Context Attributes

Attribute Description
Input The elements to filter. For a 3D object filter, the input is a 3D object.


See Also