RDATA_NAME ?
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 22/08/2004 at 13:55, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 8.500
Platform: Windows ;
Language(s) : C.O.F.F.E.E ;---------
Hi there,
could anybody about the "RDATA_NAME" container id inside the RenderData class. It seems not to work in 8.5 COFFEE. Can I get the the name of those render settings witch can be reachable inside the actual document class?
thank you
fuxy -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 23/08/2004 at 09:29, xxxxxxxx wrote:
In 8.5 the RenderData objects are true BaseList2D's, so in C++ you can get the name with GetName(). However, the C.O.F.F.E.E. model doesn't reflect this -- there's no such member -- so it's doesn't seem possible to get the name.
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 23/08/2004 at 10:02, xxxxxxxx wrote:
Thank you Mikael.
Im not too happy.
Let's go to C++. -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 30/08/2004 at 23:19, xxxxxxxx wrote:
Hi Mikael,
I tried to rewrite COFFEE code in VC++, but it happened what I was affraid.
I have no experiences in C++ an I'm a poor architect some delphi practise so I will haven't too much practise in the future (i think ).
I don't know the right way to create new RenderData object and copy into a BaseContainer data from existing RenderData.
I would like to duplicate the selected render settings.
You can see the different codes. the coffee codes works properly except the GetName() function, the C++ codes works properly except the duplicate BaseContainer data :)))
the COFFEE code:var bc3; var ind; var i; var count; var render; var newbc = new(BaseContainer); var newrender = new(RenderData); doc = GetActiveDocument(); render = doc->GetFirstRenderData(); render->GetContainer()->CopyTo(newbc); newbc->SetData(RDATA_NAME,"FX created"); newrender->SetContainer(newbc); doc->InsertRenderData(newrender, NULL);
The C++ code
BaseContainer bc; BaseContainer newbc; RenderData *rdata; RenderData *newrdata; BaseDocument *doc; doc = GetActiveDocument(); rdata = doc->GetFirstRenderData(); name = "Copy of_" + rdata->GetName(); bc = rdata->GetData(); newrdata = rdata->Alloc(); newbc = BaseContainer(); newbc = bc(); newrdata->SetName(name); newrdata->SetData(newbc,TRUE); doc->InsertRenderData(newrdata,NULL);
thank you.
bye
Fuxy -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 02/09/2004 at 01:57, xxxxxxxx wrote:
This is one way to do it:
if (doc) { RenderData* rd = doc->GetFirstRenderData(); if (rd) { RenderData* newrd = static_cast<RenderData*>(rd->GetClone(0, NULL)); if (newrd) { newrd->SetName("Copy of " + rd->GetName()); doc->InsertRenderData(newrd, rd); EventAdd(); } } }
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 02/09/2004 at 02:16, xxxxxxxx wrote:
Thanks a lot Mikael. It works now.
bye
fuxy