Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/blenloader/intern/writefile.c')
-rw-r--r--source/blender/blenloader/intern/writefile.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index f941b5f77d2..0fd394428e3 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -994,6 +994,7 @@ static void write_textures(WriteData *wd, ListBase *idbase)
static void write_materials(WriteData *wd, ListBase *idbase)
{
Material *ma;
+ MaterialLayer *ml;
int a;
ma= idbase->first;
@@ -1010,6 +1011,10 @@ static void write_materials(WriteData *wd, ListBase *idbase)
if(ma->ramp_spec) writestruct(wd, DATA, "ColorBand", 1, ma->ramp_spec);
write_scriptlink(wd, &ma->scriptlink);
+
+ for (ml=ma->layers.first; ml; ml=ml->next)
+ writestruct(wd, DATA, "MaterialLayer", 1, ml);
+
}
ma= ma->id.next;
}