Merged changes in the trunk up to revision 46045.
[blender-staging.git] / source / blender / blenkernel / intern / material.c
index f962881cd52fa542e5ee40209ecf98261dfe8bd7..6ddbf56605a5bd8ca7c5fc1afdd1dd904f1b131b 100644 (file)
@@ -494,7 +494,7 @@ short *give_totcolp(Object *ob)
 /* same as above but for ID's */
 Material ***give_matarar_id(ID *id)
 {
-       switch(GS(id->name)) {
+       switch (GS(id->name)) {
        case ID_ME:
                return &(((Mesh *)id)->mat);
                break;
@@ -510,7 +510,7 @@ Material ***give_matarar_id(ID *id)
 
 short *give_totcolp_id(ID *id)
 {
-       switch(GS(id->name)) {
+       switch (GS(id->name)) {
        case ID_ME:
                return &(((Mesh *)id)->totcol);
                break;
@@ -526,12 +526,12 @@ short *give_totcolp_id(ID *id)
 
 static void data_delete_material_index_id(ID *id, short index)
 {
-       switch(GS(id->name)) {
+       switch (GS(id->name)) {
        case ID_ME:
                mesh_delete_material_index((Mesh *)id, index);
                break;
        case ID_CU:
-               curve_delete_material_index((Curve *)id, index);
+               BKE_curve_delete_material_index((Curve *)id, index);
                break;
        case ID_MB:
                /* meta-elems don't have materials atm */
@@ -1053,7 +1053,7 @@ int material_in_material(Material *parmat, Material *mat)
 }
        
 /* ****************** */
-
+#if 0 /* UNUSED */
 static char colname_array[125][20]= {
 "Black","DarkRed","HalfRed","Red","Red",
 "DarkGreen","DarkOlive","Brown","Chocolate","OrangeRed",
@@ -1099,7 +1099,7 @@ void automatname(Material *ma)
        new_id(&G.main->mat, (ID *)ma, colname_array[nr]);
        
 }
-
+#endif
 
 int object_remove_material_slot(Object *ob)
 {