Commit: 2fcb9ef919b93626182c1d711bab7316140215a5
Author: Campbell Barton
Date:   Wed Jul 6 23:27:22 2016 +1000
Branches: master
https://developer.blender.org/rB2fcb9ef919b93626182c1d711bab7316140215a5

writefile: add flushes

Flush on grease pencil and data with image preview or packed data.

===================================================================

M       source/blender/blenloader/intern/writefile.c

===================================================================

diff --git a/source/blender/blenloader/intern/writefile.c 
b/source/blender/blenloader/intern/writefile.c
index 77df7ae..217162a 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -1922,6 +1922,9 @@ static void write_vfonts(WriteData *wd, ListBase *idbase)
 
                vf = vf->id.next;
        }
+
+       /* flush helps the compression for undo-save */
+       mywrite(wd, MYWRITE_FLUSH, 0);
 }
 
 
@@ -2358,6 +2361,9 @@ static void write_lattices(WriteData *wd, ListBase 
*idbase)
                }
                lt = lt->id.next;
        }
+
+       /* flush helps the compression for undo-save */
+       mywrite(wd, MYWRITE_FLUSH, 0);
 }
 
 static void write_images(WriteData *wd, ListBase *idbase)
@@ -2571,6 +2577,9 @@ static void write_lamps(WriteData *wd, ListBase *idbase)
                }
                la = la->id.next;
        }
+
+       /* flush helps the compression for undo-save */
+       mywrite(wd, MYWRITE_FLUSH, 0);
 }
 
 static void write_sequence_modifiers(WriteData *wd, ListBase *modbase)
@@ -2856,6 +2865,9 @@ static void write_gpencils(WriteData *wd, ListBase *lb)
                        }
                }
        }
+
+       /* flush helps the compression for undo-save */
+       mywrite(wd, MYWRITE_FLUSH, 0);
 }
 
 static void write_windowmanagers(WriteData *wd, ListBase *lb)
@@ -3291,6 +3303,9 @@ static void write_groups(WriteData *wd, ListBase *idbase)
                        }
                }
        }
+
+       /* flush helps the compression for undo-save */
+       mywrite(wd, MYWRITE_FLUSH, 0);
 }
 
 static void write_nodetrees(WriteData *wd, ListBase *idbase)
@@ -3914,6 +3929,9 @@ static void write_libraries(WriteData *wd, Main *main)
                        }
                }
        }
+
+       /* flush helps the compression for undo-save */
+       mywrite(wd, MYWRITE_FLUSH, 0);
 }
 
 /* context is usually defined by WM, two cases where no WM is available:

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to