Request for Sample using ParamBlocks

 
 
 
Posted by:dhauffe
Data created:21 August 2009

Hi,

I've just downloaded and started using MaxDotNet. Excellent work, and thanks!

 

I'm curious if you have any plans to show a sample of using IParamBlock or IParamBlock2, demonstrating how to expose/store parameters via the parameter block and integrate them into the UI. A full video walkthrough isn't really necessary, but a downloadable code sample would be very much appreciated.

 

Again, thanks for this very exciting tool!

 

Derek Hauffe

Hi Derek,

 

There is currently no way of creating parameter block descriptors but that feature is coming in a near-future build. You can monitor for it in the request: https://ephere.com/autodesk/max/request_10.html

You can always access existing paramter block valies by getting the IIParamBlock(2) interface through GetParamBlock(...) or GetReference(...) methods and then using the appropriate value getters and setters. In the geometry video tutorial I explain how to store parameters using Max's serialization. That is the current work-around, but won\t be for very long.

 

Cheers,

 

Marsel

Marsel Khadiyev (Software Developer, EPHERE Inc.)

Hi Derek,

 

There is currently no way of creating parameter block descriptors but that feature is coming in a near-future build. You can monitor for it in the request: https://ephere.com/autodesk/max/request_10.html

You can always access existing paramter block valies by getting the IIParamBlock(2) interface through GetParamBlock(...) or GetReference(...) methods and then using the appropriate value getters and setters. In the geometry video tutorial I explain how to store parameters using Max's serialization. That is the current work-around, but won\t be for very long.

 

Cheers,

 

Marsel

Marsel Khadiyev (Software Developer, EPHERE Inc.)

Thanks for your response, Marsel. I guess parameter blocks are not so much my main goal. What I'm more interested in is an ability to create a geometry plugin with editable properties. To use your Plane as an example, I'd like to be able to edit the Height and Width of the plane after its initial creation. Does this require the presence of parameters blocks, or is there some other way to make this information editable?

Derek

Hi Derek,

Sorry for late reply. To make those parameters editable I would create a .NET form with textboxes from which they can be edited/changed. Then I would override OnBeginEdit/OnEndEdit in your plugin's class. Inside begin edit I'd put up the dialog, and in end edit I'd tear it down. You can also override Save and Load members to serialize the data.

Marsel

Marsel Khadiyev (Software Developer, EPHERE Inc.)

Thanks, Marsel. I'll take a look into that approach. I appreciate your response. Good luck with your project!

 

Derek