Cortex  10.0.0-a4
Public Member Functions | List of all members
IECoreRI::ScopedContext Class Reference

#include <ScopedContext.h>

Inherits noncopyable.

Public Member Functions

 ScopedContext (RtContextHandle context)
 
 ~ScopedContext ()
 

Detailed Description

The ScopedContext class makes it easy to manage calls to RiContext() so you can manage calls to many contexts relatively easily, with little fear of Exceptions or multiple return paths leaving you in the wrong context.

Constructor & Destructor Documentation

IECoreRI::ScopedContext::ScopedContext ( RtContextHandle  context)

Saves the current context and instates the specified context with RiContext(). If context is RI_NULL then does nothing.

IECoreRI::ScopedContext::~ScopedContext ( )

Restores the previously saved context, unless the context specified in the constructor was RI_NULL in which case it does nothing.


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