The Destroy Instance Action

	#include "ofxCore.h"
	#define kOfxActionDestroyInstance       "OfxActionDestroyInstance" 
Arguments

  • handle handle to the interact instance, cast to an OfxInteractHandle
  • inArgs is redundant and is set to NULL,
  • outArgs is redundant and is set to NULL.

Description

This action is the last passed to an interact's instance before its destruction. It is there to allow a plugin to destroy any per-instance data structures it may have created.

Preconditions

  • kOfxActionCreateInstance has been called on the handle,
  • the instance has not had any of its members destroyed yet,

Postconditions

  • the instance pointer is no longer valid and any operation on it will be undefined

Return Values

To some extent, what is returned is moot, a bit like throwing an exception in a C++ destructor, so the host should continue destruction of the instance regardless. However...