On 04/12/2016 at 06:54, xxxxxxxx wrote:
User Information:
Cinema 4D Version: R18
Platform: Windows ;
Language(s) : C++ ;
---------
As the CallUVCommand isn't functional within the Python API, I have been playing around with the C++ SDK.
I am trying to perform a relaxation of the polygons defined in the BaseSelect bsPolys , given a set of edges specified in BaseSelect bsEdges. However, I haven't found any documentation, nor example as how to set the BaseSelect into the BaseContainer being passed to CallUVCommand.
Could someone explain, or point me to some explanation how to go about this?
Thanks
TempUVHandle* handle = GetActiveUVSet(doc, GETACTIVEUVSET_ALL);
if (handle)
{
BaseSelect* bsPolys;
BaseSelect* bsEdges;
...
BaseContainer bc;
bc.SetBool(RELAXUV_CUT_EDGESEL, true);
bc. ??? (RELAXUV_EDGESEL_POINTER, ??? bsEdges); // <-----------
bc.SetBool(RELAXUV_KEEP_NEIGHBORS, false);
bc.SetBool(RELAXUV_KEEP_BORDER, false);
bc.SetInt32(RELAXUV_MODE, RELAXUV_MODE_LSCM);
CallUVCommand(
handle->GetPoint(),
handle->GetPointCount(),
handle->GetPoly(),
handle->GetPolyCount(),
handle->GetUVW(),
handle->GetPolySel(),
handle->GetUVPointSel(),
handle->GetBaseObject(),
Muvpolygons,
UVCOMMAND_RELAX,
bc);
handle->SetUVWFromTextureView(handle->GetUVW(), false, false, false);
FreeActiveUVSet(handle);
}