Hi all, I am very new to gimp and it's development. I am trying to learn gimp-plugins. I can run the plugin fine for the first using the Xtns->... menu. But if I want to run the same plugin for second time, the menu entry is disabled. Is there something that I am doing wrong? please let me know. Thanks much in advance.
HERE IS MY CODE:
run (const gchar *name,
const GimpParam *param,
static GimpParam values;
GimpPDBStatusType status = GIMP_PDB_SUCCESS;
gint32 SImg, SLay;
/* Setting mandatory output values */
*nreturn_vals = 1;
*return_vals = values;
values.type = GIMP_PDB_STATUS;
values.data.d_status = status;
SImg = gimp_image_new(720,720,GIMP_RGB);
SLay = gimp_layer_new(SImg, "Layer1", 720, 720, GIMP_RGB_IMAGE, 100, GIMP_NORMAL_MODE);
gimp_image_add_layer(SImg, SLay, 0);
Hi. I had a similar problem before. Please show your registration code.
Your plugin needs to take an image as its first input in order to be repeatable.
Your plugin will be grayed out if you registered it as accepting the wrong image types. In this case "*" is the right image type to accept. Using '' will create a plugin that accepts any input image, but is not repeatable (this was my mistake.)
_______________________________________________ Gimp-developer mailing list Gimp-developer@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-developer