C# Development

Using C# with XSI

C# (pronounced "C sharp") is a simple, type-safe programming language that represents a hybrid between C++ and scripting languages. Plug-ins written in C# are much faster than scripted plug-ins and as of vPioneer, XSI plug-ins can be written in C#.

For more information about the C# language, the Microsoft Developer’s Network (MSDN) has technical specs and C# reference and overview documentation. In addition, MSDN offers a C# FAQ and Microsoft’s GotDotNet provides a number of QuickStart tutorials.

 

If you don’t have Visual Studio .NET 2005, you can use Visual C# Express, a free version that comes with full C# doc and a debugger.

How C# Works with XSI

The Assembly is the primary unit of deployment within the .NET Framework; it is similar to a C++ .dll or .so file and can contain references to other assemblies and modules.

The XSI Object Model type library has been ported to a C# assembly which allows developers to access the XSI SDK using C#. Virtually the entire object model is accessible, except for a few interfaces which are not available:

• obsolete interfaces: XSIDialog, Cluster_V1, ClusterProperty_V1, Geometry_V1, Geometry0D, Geometry1D, and Geometry2D

• empty interfaces: AlignedAxisConstraint and SpotLight

PPG (handled by the class for C#) and XSIFileService (import/export services)

 

Visual Studio .NET 2005 provides useful features that you can use to familiarize yourself with the XSI Object Model for C#. These include an ObjectBrowser that you can use to browse through the XSI object model typelib and an autocomplete function which provides a list of available objects and their members as you type your source code.

How C# Plug-ins Work with XSI

Instead of functions exported from a .dll, C# plug-in items are implemented as C# objects. You create a plug-in object that implements public methods matching the plug-in item callbacks. To get a hook into XSI, you make sure you include the XSIOM (object model) assembly and then create a base object that will register the plug-in in XSI.

 



SOFTIMAGE|XSI v6.01     

Return to Softimage XSI Index