diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-04-18 12:51:20 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-04-18 17:35:38 +0300 |
commit | 15850a8740ed95afdc5779e224bf40f7540a7d62 (patch) | |
tree | af4b6f85d6ff7bb3a857106ed5397ed5c3190e03 /source/blender/blenloader | |
parent | 34dbe7ff33a3f565772ac6f0d60bbf955e07983c (diff) |
Workbench: don't change to workbench drawtype for files saved in 2.8.
Assume files saved in 2.8 were intended for Eevee and set them to material
viewport shading. In Eevee this is equal to rendered draw mode, in Cycles
this will draw with Eevee. This way Eevee demo files still show something
interesting when opened.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r-- | source/blender/blenloader/intern/versioning_280.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c index b3cd1a6a1b7..490344d30fa 100644 --- a/source/blender/blenloader/intern/versioning_280.c +++ b/source/blender/blenloader/intern/versioning_280.c @@ -934,6 +934,12 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *main) View3D *v3d = (View3D *)sl; v3d->drawtype_solid = OB_LIGHTING_STUDIO; v3d->drawtype_wireframe = OB_LIGHTING_STUDIO; + + /* Assume (demo) files written with 2.8 want to show + * Eevee renders in the viewport. */ + if (MAIN_VERSION_ATLEAST(main, 280, 0)) { + v3d->drawtype = OB_MATERIAL; + } } } } |