June 29th, 2010
How to merge two documents in COFFEE :
Example of use :
-
MyMenuPlugin::Execute(doc)
-
{
-
var file = new(Filename);
-
if (file->FileSelect("File to merge", FALSE) == FALSE)
-
return FALSE;
-
MergeDocument(doc, file);
-
return TRUE;
-
}
-
The MergeDocument() code :
(more…)
June 29th, 2010
ContainerFile is a class which allow to save and apply all object’s matrix of a hierarchy :
-
class ContainerFile
-
{
-
public:
-
ContainerFile(name);
-
Write(parent);
-
Apply(parent);
-
};
-
Just include this file in your COFFEE code : container_file.coh
include "container_file.coh"
Here the saveread plugin to show how to use this class : saveread.cof
/!\ Update available
(more…)
June 29th, 2010
How to add a bitmap button in a COFFEE interface :
[bool] AddBitmapButton([int] id, [GeDialog] dialog, [string] name, [int] flags);
Use like this :
-
enum {
-
MY_BUTTON = 1000,
-
BITMAP_BUTTON,
-
_DUMMY_
-
}
-
-
MyDialog::CreateLayout()
-
{
-
SetTitle(PLUGIN_NAME);
-
AddButton(MY_BUTTON, BFV_FIT, 100, 15, "Dummy");
-
AddBitmapButton(BITMAP_BUTTON, this, "image.bmp", BFH_CENTER);
-
return TRUE;
-
}
-
-
MyDialog::Command(id, msg)
-
{
-
switch (id)
-
{
-
case MY_BUTTON :
-
println("Dummy button clicked");
-
break;
-
case BITMAP_BUTTON :
-
println("Bitmap button clicked");
-
break;
-
}
-
return TRUE;
-
}
Just include this file in your COFFEE code : bitmap_button.coh
include "bitmap_button.coh"
(more…)
June 28th, 2010
How to add a bitmap in a COFFEE interface :
[bool] AddBitmap([int] id, [GeDialog] dialog, [string] name, [int] flags);
Use like this :
-
enum {
-
MY_BUTTON = 1000,
-
MY_BITMAP,
-
_DUMMY_
-
}
-
-
MyDialog::CreateLayout()
-
{
-
SetTitle(PLUGIN_NAME);
-
AddButton(MY_BUTTON, BFV_FIT, 100, 15, "Dummy");
-
AddBitmap(MY_BITMAP, this, "my_image.jpg", BFH_CENTER);
-
return TRUE;
-
}
Just include this file in your COFFEE code : bitmap_gui.coh
include "bitmap_gui.coh"
(more…)
June 24th, 2010

Ceci est un plugin COFFEE pour Cinema 4D qui permet de mettre à jour les références de XRefs.
This is a COFFEE plugin for Cinema 4D that can update XRefs references.
Example :
XRef = object_02.c4d
Folder :
– object1.c4d
– object_02.c4d
– object-4.c4d
– object006.c4d
Le plugin va mettre à jour object_02.c4d en object006.c4d (le plus récent).
The plugin will update object_02.c4d into object006.c4d (the most recent).
Download xsXRefUpdate