It looks like you're new here. If you want to get involved, click one of these buttons!
Arnold has its own string type now (AtString) moving forward it is the option to use but in the mean time the API has both versions. So I want to support both...
Arnold.test.kl:103:24: error: ambiguous resolution for function AiNode(String) Arnold.test.kl:103:24: Candidates are: Arnold.test.kl:103:24: function AtNode AiNode(AtString) Arnold.test.kl:103:24: function AtNode AiNode(CxxCharConstPtr)
AtNode mesh = AiNode("polymesh");
So, to fix this I can make an explicit cast to AtString, which will actually be required in Arnold 5...
AtNode mesh = AiNode(AtString("polymesh"));
optionally I can get the c_str version of the KL String.
AtNode mesh = AiNode("polymesh".data());
But if the KL String is a const char *, why doesn't the first one work? What is the best way to handle cpp functions with const char * arguments so the user doesn't have to call .data() or c_str()?
©Copyright 2017 Fabric Software Inc. All rights reserved. | Privacy