Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Hello Ferdinand
- I am getting the error when setting the values when using Set function from https://developers.maxon.net/docs/Cinema4DCPPSDK/html/page_handbook_node_implementation_programmatically.html
- template <typename ATTR> Result<void> Set(const Id& category, const ATTR& attr, const typename ATTR::ValueType& value)
- {
- // Retrieve the category"s and add an attribute.
- iferr_scope;
- DataDictionary& dict = GetPortDictionary(category) iferr_return;
- dict.Set(attr, value) iferr_return;
- return OK;
- }
- Below is a part of the code and I am getting the error when setting DESCRIPTION::DATA::BASE::ENUM. It works all good with other data types.
- maxon::Id options[] = { Id("Test1"), Id("Test2"), Id("Test3") };
- Block<Id> block = maxon::ToBlock(options);
- maxon::BaseArray<maxon::Tuple<maxon::Id, maxon::Data>> data = maxon::BlockToEnumArray(block) iferr_return;
- node.Set(DATADESCRIPTION_CATEGORY_DATA, DESCRIPTION::DATA::BASE::DATATYPE, GetDataType<InternedId>().GetId()) iferr_return;
- node.Set(DATADESCRIPTION_CATEGORY_DATA, DESCRIPTION::DATA::BASE::CLASSIFICATION, DESCRIPTION::DATA::BASE::CLASSIFICATION.ENUM_NONE) iferr_return;
- node.Set(DATADESCRIPTION_CATEGORY_DATA, DESCRIPTION::DATA::BASE::ENUM, data) iferr_return;
- node.Set(DATADESCRIPTION_CATEGORY_UI, DESCRIPTION::UI::BASE::GROUPID, page_id) iferr_return;
- node.Set(DATADESCRIPTION_CATEGORY_UI, DESCRIPTION::UI::BASE::GUITYPEID, Id("net.maxon.ui.enum")) iferr_return;
- node.Set(LANGUAGE_ENGLISH_ID, DESCRIPTION::STRING::BASE::TRANSLATEDSTRING, (maxon::String)meta.m_label) iferr_return;
- This is the error message I am getting too.
- error C2664: 'maxon::Result<void> delight_network::ProceduralNodeBuilder::Set<maxon::DESCRIPTION::DATA::BASE::ENUM_PrivateAttribute>(const maxon::Id &,const ATTR &,const maxon::DESCRIPTION::DATA::BASE::ENUM_PrivateAttribute::ValueType &)': cannot convert argument 3 from 'maxon::BaseArray<maxon::Tuple<maxon::Id,maxon::Data>,16,maxon::BASEARRAYFLAGS::NONE,maxon::DefaultAllocator>' to 'const maxon::DESCRIPTION::DATA::BASE::ENUM_PrivateAttribute::ValueType &'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement