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
AgeCommit message (Collapse)Author
2017-09-20Layer collection enable flagDalai Felinto
Right now this is exposed in the outliner, though all this (visible/selectable/enable) should be moved to a new panel soon. This removes objects from the depsgraph when the collection is disabled. It allows you to "hide" lamps but still having them lighting the scene. Same for light probes and other support objects. Pending tasks: * Have depsgraph to include invisible objects in the DEG_OBJECTS_ITER, and then have Eevee and other engines to make a distinction between an invisible and a visible object. (for example, we probably want invisible objects to not show in the viewport, but cast shadows and show up in light probes). * Change how we evaluate collection settings so that an invisible collection can force an object to be invisible. Reviewers: campbellbarton Subscribers: sergey Differential Revision: https://developer.blender.org/D2848
2017-06-12Rename probe to light-probeCampbell Barton
Probe is a real general term, the new name is used often in docs online.
2017-06-09Probe: Add new object datablockClément Foucault
We went for a new datablock because blending probe functionality with empties was going to be messy.
2017-06-01Main Workspace IntegrationJulian Eisel
This commit does the main integration of workspaces, which is a design we agreed on during the 2.8 UI workshop (see https://wiki.blender.org/index.php/Dev:2.8/UI/Workshop_Writeup) Workspaces should generally be stable, I'm not aware of any remaining bugs (or I've forgotten them :) ). If you find any, let me know! (Exception: mode switching button might get out of sync with actual mode in some cases, would consider that a limitation/ToDo. Needs to be resolved at some point.) == Main Changes/Features * Introduces the new Workspaces as data-blocks. * Allow storing a number of custom workspaces as part of the user configuration. Needs further work to allow adding and deleting individual workspaces. * Bundle a default workspace configuration with Blender (current screen-layouts converted to workspaces). * Pressing button to add a workspace spawns a menu to select between "Duplicate Current" and the workspaces from the user configuration. If no workspaces are stored in the user configuration, the default workspaces are listed instead. * Store screen-layouts (`bScreen`) per workspace. * Store an active screen-layout per workspace. Changing the workspace will enable this layout. * Store active mode in workspace. Changing the workspace will also enter the mode of the new workspace. (Note that we still store the active mode in the object, moving this completely to workspaces is a separate project.) * Store an active render layer per workspace. * Moved mode switch from 3D View header to Info Editor header. * Store active scene in window (not directly workspace related, but overlaps quite a bit). * Removed 'Use Global Scene' User Preference option. * Compatibility with old files - a new workspace is created for every screen-layout of old files. Old Blender versions should be able to read files saved with workspace support as well. * Default .blend only contains one workspace ("General"). * Support appending workspaces. Opening files without UI and commandline rendering should work fine. Note that the UI is temporary! We plan to introduce a new global topbar that contains the workspace options and tabs for switching workspaces. == Technical Notes * Workspaces are data-blocks. * Adding and removing `bScreen`s should be done through `ED_workspace_layout` API now. * A workspace can be active in multiple windows at the same time. * The mode menu (which is now in the Info Editor header) doesn't display "Grease Pencil Edit" mode anymore since its availability depends on the active editor. Will be fixed by making Grease Pencil an own object type (as planned). * The button to change the active workspace object mode may get out of sync with the mode of the active object. Will either be resolved by moving mode out of object data, or we'll disable workspace modes again (there's a `#define USE_WORKSPACE_MODE` for that). * Screen-layouts (`bScreen`) are IDs and thus stored in a main list-base. Had to add a wrapper `WorkSpaceLayout` so we can store them in a list-base within workspaces, too. On the long run we could completely replace `bScreen` by workspace structs. * `WorkSpace` types use some special compiler trickery to allow marking structs and struct members as private. BKE_workspace API should be used for accessing those. * Added scene operators `SCENE_OT_`. Was previously done through screen operators. == BPY API Changes * Removed `Screen.scene`, added `Window.scene` * Removed `UserPreferencesView.use_global_scene` * Added `Context.workspace`, `Window.workspace` and `BlendData.workspaces` * Added `bpy.types.WorkSpace` containing `screens`, `object_mode` and `render_layer` * Added Screen.layout_name for the layout name that'll be displayed in the UI (may differ from internal name) == What's left? * There are a few open design questions (T50521). We should find the needed answers and implement them. * Allow adding and removing individual workspaces from workspace configuration (needs UI design). * Get the override system ready and support overrides per workspace. * Support custom UI setups as part of workspaces (hidden panels, hidden buttons, customizable toolbars, etc). * Allow enabling add-ons per workspace. * Support custom workspace keymaps. * Remove special exception for workspaces in linking code (so they're always appended, never linked). Depends on a few things, so best to solve later. * Get the topbar done. * Workspaces need a proper icon, current one is just a placeholder :) Reviewed By: campbellbarton, mont29 Tags: #user_interface, #bf_blender_2.8 Maniphest Tasks: T50521 Differential Revision: https://developer.blender.org/D2451
2017-04-25Outliner: Re-build depsgraph when reordering collectionsDalai Felinto
Otherwise if we create a new collection, and drag a collection into it we either get a crash, or at the very least we dont get the visibility flags correct.
2017-03-10Improve outliner drag&drop feedback by using drop poll callbacksJulian Eisel
This way we can ensure the overlay to indicate where the item would be placed if it was dropped now is always at the correct place and doesn't mislead the user.
2017-03-10Support drag & drop of collections across multiple hierarchy levelsJulian Eisel
Two issues are remaining, they'll be fixed separately: * Graphical feedback when dragging within the master collection is wrong * There's some bug where collections swap places instead, Dalai will investigate
2017-03-02Get UI ready for using drag & drop to nest a collection into another oneJulian Eisel
Nothing happen yet when it's supposed to insert the collection into another one, that part will be handled by @dfelinto. See gif for demo of how it works UI wise: {F500337} Also fixed off-by-one error in utility function.
2017-03-01Outliner: Support dragging object into collectionJulian Eisel
Doing this will add the object to the collection.
2017-03-01Cleanup: Rename outliner enumJulian Eisel
2017-02-28Cleanup: Add outliner_utils.c, move functions into itJulian Eisel
2017-02-28Outliner: Delete all selected collections, not just active oneJulian Eisel
There were some issues with how we store outliner tree elements: Apparently the only removable elements have been data-blocks so far. When recreating the TreeElements, their TreeStoreElem instances were mainly identified by their ID pointer. However non-data-blocks mostly depend on an index. For collections, such an index isn't a reliable measure though if we want to allow removing items. Depending on it for identifying the TreeStoreElem instance would cause some quite noticeable glitches (wrong highlights, two elements sharing highlight, etc). For now I've solved that by actually removing the TreeStoreElem that represents the removed element. A little limitation of this is that after undoing the removal, some information might get lost, like flags to store selection, or opened/closed state. A better solution that would also fix this issue would be having a real unique identifier for each non-data-block element, like an idname or even its data-pointer. Not sure if we can get those to work reliable with file read/write though, would have to investigate... Also added a general Outliner tree traversal utility.
2017-02-22UI: Support drag & drop reordering of collectionsJulian Eisel
This adds initial support for reordering collections from the Outliner using drag & drop. Although drag & drop support is limited to collections for now, this lays most foundations for general drag & drop reordering support in the Outliner. There are some design questions to be answered though: * Would reordering of other data types (like objects) be a purely visual change or would it affect the order in which they are stored? (Would that make a difference for the user?) * Should/can we allow mixing of different data types? (e.g. mixing render layers with objects) * How could we realize this technically? Notes: * "Sort Alphabetically" has to be disabled to use this ("View" menu). * Reordering only works with collections on the same hierarchy level. * Added some visual feedback that should work quite well, it's by far not a final design though: {F493806} * Modified collection orders are stored in .blends. * Reordering can be undone. * Did minor cleanups here and there.
2017-02-17Layer/Outliner: add a few operators that I need for the video demoDalai Felinto
2017-02-16Outliner collection operators, all but collection linkDalai Felinto
Note: It may be missing a notifier to prevent Outliner from crashing when deleting collections.
2017-02-15Revert "Collection Editor based on patch by Julian Eisel"Dalai Felinto
This reverts commit 3da834e83ce9d7056c033148dab04885a6d3b1b7. We will use the outliner for this now. I'm also moving the collections_ops.c to outliner_collections.c
2017-02-09Main fix for outliner, but still need changesDalai Felinto
Fix outliner related crashes. Basically in some functions bContext was not passed around, so CTX_data_scene_layer(C) was crashing. Right now we still rely on ob->flag SELECT in some places. In order to use the base flag we will need to bring back the Bases to the outliner.
2017-02-07Render Layers and Collections (merge from render-layers)Dalai Felinto
Design Documents ---------------- * https://wiki.blender.org/index.php/Dev:2.8/Source/Layers * https://wiki.blender.org/index.php/Dev:2.8/Source/DataDesignRevised User Commit Log --------------- * New Layer and Collection system to replace render layers and viewport layers. * A layer is a set of collections of objects (and their drawing options) required for specific tasks. * A collection is a set of objects, equivalent of the old layers in Blender. A collection can be shared across multiple layers. * All Scenes have a master collection that all other collections are children of. * New collection "context" tab (in Properties Editor) * New temporary viewport "collections" panel to control per-collection visibility Missing User Features --------------------- * Collection "Filter" Option to add objects based on their names * Collection Manager operators The existing buttons are placeholders * Collection Manager drawing The editor main region is empty * Collection Override * Per-Collection engine settings This will come as a separate commit, as part of the clay-engine branch Dev Commit Log -------------- * New DNA file (DNA_layer_types.h) with the new structs We are replacing Base by a new extended Base while keeping it backward compatible with some legacy settings (i.e., lay, flag_legacy). Renamed all Base to BaseLegacy to make it clear the areas of code that still need to be converted Note: manual changes were required on - deg_builder_nodes.h, rna_object.c, KX_Light.cpp * Unittesting for main syncronization requirements - read, write, add/copy/remove objects, copy scene, collection link/unlinking, context) * New Editor: Collection Manager Based on patch by Julian Eisel This is extracted from the layer-manager branch. With the following changes: - Renamed references of layer manager to collections manager - I doesn't include the editors/space_collections/ draw and util files - The drawing code itself will be implemented separately by Julian * Base / Object: A little note about them. Original Blender code would try to keep them in sync through the code, juggling flags back and forth. This will now be handled by Depsgraph, keeping Object and Bases more separated throughout the non-rendering code. Scene.base is being cleared in doversion, and the old viewport drawing code was poorly converted to use the new bases while the new viewport code doesn't get merged and replace the old one. Python API Changes ------------------ ``` - scene.layers + # no longer exists - scene.objects + scene.scene_layers.active.objects - scene.objects.active + scene.render_layers.active.objects.active - bpy.context.scene.objects.link() + bpy.context.scene_collection.objects.link() - bpy_extras.object_utils.object_data_add(context, obdata, operator=None, use_active_layer=True, name=None) + bpy_extras.object_utils.object_data_add(context, obdata, operator=None, name=None) - bpy.context.object.select + bpy.context.object.select = True + bpy.context.object.select = False + bpy.context.object.select_get() + bpy.context.object.select_set(action='SELECT') + bpy.context.object.select_set(action='DESELECT') -AddObjectHelper.layers + # no longer exists ```
2016-12-28Revert particle system and point cache removal in blender2.8 branch.Lukas Tönne
This reverts commit 5aa19be91263a249ffae75573e3b32f24269d890 and b4a721af694817fa921b119df83d33ede7d7fed0. Due to postponement of particle system rewrite it was decided to put particle code back into the 2.8 branch for the time being.
2016-10-16Merge branch 'master' into blender2.8Julian Eisel
Conflicts: source/blender/editors/space_outliner/outliner_draw.c source/blender/editors/space_outliner/outliner_edit.c source/blender/editors/space_outliner/outliner_intern.h source/blender/editors/space_outliner/outliner_select.c
2016-10-16Cleanup: Unused parameters in OutlinerJulian Eisel
These were only passed to own recursion calls.
2016-10-16Outliner: Rework element selection behaviorJulian Eisel
* LMB now replaces selection instead of adding to it. Shift+LMB adds to selection (or removes if already selected). This is usual selection behavior Blender. * Outliner selection isn't completely separate from object/sequencer-strip/render-layer/... selection anymore, when selecting an outliner item we now always try to select (and activate) the object it belongs to. Previously you had to click the name or icon of an item to select the object (or whatever) and on empty space within the row to set outliner selection. * Collapsed items may show click-able icons for their children (nothing new). Clicking on such an icon will also select the hidden item it represents now, you'll notice after opening the parent. This valid from a technical POV, I'm not sure if this is wanted from user POV though. Changing would be easy, feedback welcome! * Code cleanup. Part of T37430.
2016-10-15Outliner: Element mouse hover feedbackJulian Eisel
Some little UI polish to get familiar with outliner code (but also because it's a useful feature). Committing to blender2.8 branch but can also port to master (2.7) if wanted. This basically causes the mouse hovered element to be highlighted. Contrast of the highlight should be fine, even with a non-default theme. Also did some minor cleanup.
2016-09-26Merge branch 'master' into blender2.8Bastien Montagne
WARNING! Full build is broken, alembic has not been merged in correctly and has some references to particle stuff. Don't have time to tackle this now (and probably would be better if someone knowing what he's doing does it anyway). Conflicts: release/scripts/startup/bl_ui/properties_particle.py source/blender/blenkernel/intern/library_remap.c source/blender/blenkernel/intern/smoke.c source/blender/editors/physics/particle_object.c source/blender/editors/physics/physics_intern.h source/blender/editors/physics/physics_ops.c source/blender/editors/space_outliner/outliner_intern.h source/blender/editors/space_view3d/drawvolume.c source/blender/makesrna/intern/rna_smoke.c
2016-09-23Outliner: Fix assert failure with palette IDSergey Sharybin
2016-08-06Merge branch 'master' into blender2.8Bastien Montagne
Conflicts: release/scripts/startup/bl_ui/properties_particle.py release/scripts/startup/bl_ui/properties_physics_cloth.py release/scripts/startup/bl_ui/properties_physics_dynamicpaint.py release/scripts/startup/bl_ui/properties_physics_softbody.py source/blender/blenkernel/BKE_library.h source/blender/blenkernel/BKE_particle.h source/blender/blenkernel/intern/cloth.c source/blender/blenkernel/intern/library.c source/blender/blenkernel/intern/library_query.c source/blender/blenkernel/intern/particle_system.c source/blender/blenkernel/intern/scene.c source/blender/blenkernel/intern/softbody.c source/blender/blenloader/intern/readfile.c source/blender/blenloader/intern/versioning_270.c source/blender/editors/space_file/filesel.c source/blender/editors/space_outliner/outliner_intern.h source/blender/makesdna/DNA_ID.h source/blender/makesdna/DNA_object_force.h source/blender/makesdna/DNA_particle_types.h source/blender/makesrna/intern/rna_particle.c source/blender/makesrna/intern/rna_sculpt_paint.c source/blender/makesrna/intern/rna_smoke.c source/blender/makesrna/intern/rna_space.c
2016-08-06Basic Alembic supportKévin Dietrich
All in all, this patch adds an Alembic importer, an Alembic exporter, and a new CacheFile data block which, for now, wraps around an Alembic archive. This data block is made available through a new modifier ("Mesh Sequence Cache") as well as a new constraint ("Transform Cache") to somewhat properly support respectively geometric and transformation data streaming from alembic caches. A more in-depth documentation is to be found on the wiki, as well as a guide to compile alembic: https://wiki.blender.org/index.php/ User:Kevindietrich/AlembicBasicIo. Many thanks to everyone involved in this little project, and huge shout out to "cgstrive" for the thorough testings with Maya, 3ds Max, Houdini and Realflow as well as @fjuhec, @jensverwiebe and @jasperge for the custom builds and compile fixes. Reviewers: sergey, campbellbarton, mont29 Reviewed By: sergey, campbellbarton, mont29 Differential Revision: https://developer.blender.org/D2060
2016-07-12Merge branch 'master' into blender2.8Bastien Montagne
Conflicts: intern/cycles/blender/addon/ui.py source/blender/blenkernel/BKE_particle.h source/blender/blenkernel/intern/dynamicpaint.c source/blender/blenkernel/intern/library.c source/blender/blenkernel/intern/object.c source/blender/blenkernel/intern/particle.c source/blender/blenkernel/intern/particle_distribute.c source/blender/blenkernel/intern/texture.c source/blender/editors/object/object_add.c source/blender/editors/object/object_relations.c source/blender/editors/physics/particle_edit.c source/blender/editors/physics/particle_object.c source/blender/editors/transform/transform_snap_object.c
2016-07-01Outliner: pass operator's reports to all operation callbacks.Bastien Montagne
Also define single callback func typedef, cleaner this way! Note: maybe we want to do that for the other callbacks too (data, etc.), but will be enough for now.
2016-06-23Merge branch 'master' into blender2.8Campbell Barton
2016-06-22ID-Remap, step two: add some user-level tools.Bastien Montagne
This commit adds operators and Outliner menu entries to reload or relocate a library, and to delete or replace a datablock. RNA ID API is also extended to allow ID deletion and remapping from python. Review task: D2027 (https://developer.blender.org/D2027). Reviewed by campbellbarton, thanks a bunch.
2016-06-22ID-Remap - Step one: core work (cleanup and rework of generic ID datablock ↵Bastien Montagne
handling). This commit changes a lot of how IDs are handled internally, especially the unlinking/freeing processes. So far, this was very fuzy, to summarize cleanly deleting or replacing a datablock was pretty much impossible, except for a few special cases. Also, unlinking was handled by each datatype, in a rather messy and prone-to-errors way (quite a few ID usages were missed or wrongly handled that way). One of the main goal of id-remap branch was to cleanup this, and fatorize ID links handling by using library_query utils to allow generic handling of those, which is now the case (now, generic ID links handling is only "knwon" from readfile.c and library_query.c). This commit also adds backends to allow live replacement and deletion of datablocks in Blender (so-called 'remapping' process, where we replace all usages of a given ID pointer by a new one, or NULL one in case of unlinking). This will allow nice new features, like ability to easily reload or relocate libraries, real immediate deletion of datablocks in blender, replacement of one datablock by another, etc. Some of those are for next commits. A word of warning: this commit is highly risky, because it affects potentially a lot in Blender core. Though it was tested rather deeply, being totally impossible to check all possible ID usage cases, it's likely there are some remaining issues and bugs in new code... Please report them! ;) Review task: D2027 (https://developer.blender.org/D2027). Reviewed by campbellbarton, thanks a bunch.
2016-04-28Merge branch 'master' into temp_remove_particlestemp_remove_particlesLukas Tönne
2016-04-26Cleanup: use const for outliner argsCampbell Barton
Also c99 edits for outliner_find_id
2016-04-26Outliner: "Show Active" support for active bonePhilipp Oeser
Resolves T48229
2016-04-16Removed the ID_PA code used for ParticleSettings.Lukas Tönne
2016-04-04Fix missing ID_SO sound type in outliner's ID types.Bastien Montagne
Note that we may want to review that some day, we have quite a bit of ID types here that are 'blend file' view only, might be worth splitting the check based on this.
2015-12-19Add a void 'user_data' memeber to Outliner's callbacks.Bastien Montagne
This is not used currently, but needed for work done in id-remap branch, and will greatly reduce diff noise in this area...
2015-12-01Outliner: add an option to "delete" libraries.Bastien Montagne
Caminandes team request. In current master it's not possible to do this in a total clean way, so we are simply setting all user counts of given lib's datablocks to zero (similar to rna_ID_user_clear()'s doing). This is a bit crappy because it still lets datablocks floating around (with invalid user count values), and requires a save & reload cycle to be finalized. But for now it should be good enough. Propper implementation will be added to id-remap.
2015-10-22Fix T46561: Crash in outliner delete hierarchyCampbell Barton
When children & parents were selected in the outliner, it attempted to free the the object twice.
2015-09-09Fix (unreported) crash with undo/outliner and drivers.Bastien Montagne
To reproduce the crash: * Add some shapekeys to default cube. * Add at least on driver (can be default empty one) to a shapekey value. * **Make this driver visible in Outliner**. * Delete all shapekeys. * Undo. * Crash. Root of the issue is outliner reading code in `blo_lib_link_screen_restore()`, which would try to `restore_pointer_by_name()` for all `TreeStoreElement->id` pointers. Thing is, those id pointers are not always IDs, they can be animdata, sequence, RNA struct/property... That's really not so great design, but also has reasons like size of the struct, we have to live with it. So now: * TreeStoreElement->type defines are braught back into DNA. * There we also define a `TSE_IS_REAL_ID` macro to check whether a given TreeStoreElement actually stores an ID pointer or not. * And in Outliner read code we only try to retore pointers by name for actual ID ones, and set the others to default NULL value. Also, added clear comment to TSE types that do not store a real ID pointer!
2015-08-29Add some more missing ID types to TREESTORE_ID_TYPE...Bastien Montagne
2015-08-14Outliner: Context menu for scenesPhilipp Oeser
Adds context menu for scenes in the outliner, for now, with only a 'Delete' entry. D1448 by @lichtwerk, review by @aligorith and @Severin
2015-07-21Fix assert in Outliner.Bastien Montagne
2015-05-18Fix assert in outliner regarding WM and SCR ID types...Bastien Montagne
2015-04-30Fix T44439: outliner's treestore could keep invalid ID pointers, could crash ↵Bastien Montagne
on undo due to invalid mem access. We cannot nuke treestore in readfile's `blo_lib_link_screen_restore()`, because this will destroy all UI-state data (like opened/closed items, etc.). Since we cannot know for sure whether an ID pointer from tselem->id is valid here, we have to ensure they are never invalid, i.e. to always set them to NULL when we delete them. To do so, this commit uses a similar approach as what already exists for ID references in WM notifiers - it extends `free_notifier_reference_cb()` to also nullify those IDs in all outliners. Note that some ID types are not used(shown) by outliner currently, so `TREESTORE_ID_TYPE` macro was added, that checks whether an ID is possibly used by outliner. Avoids a few searches in whole tree whene deleting some IDs. Reviewers: campbellbarton, sergey Maniphest Tasks: T44439 Differential Revision: https://developer.blender.org/D1272
2015-03-28Cleanup: redundant struct declarationsCampbell Barton
2015-02-15Outliner: "Purge All" function for Outliner in "Orphaned Datablocks" modeJoshua Leung
Many users have been requesting a way to remove unused datablocks from the file/session "without closing and reopening" Blender (or at least that's the impression I'm getting). This commit adds a new operator (exposed as the "Purge All" button in the header of the "Orphaned Datablocks" mode in the Outliner, which seems to be the logical place for this) for doing so. It does so by wrapping up the save and "revert" (i.e. reload the saved file from disk, without needing to quit Blender) operators along with a confirmation prompt for good measure. Caveats: * Ultimately, we still cannot really cleanly delete any datablocks from the current session outright without reloading the file/data at some point. Thus, we do need to reload the file again before it can be used. * This does mean that this operation is irreversible. Notably, Undo history is lost is doing this operation. Hence the warnings... (Then again, undo/redo actually reloads the entire scene DB from memory, so it's not anything uncommon ;) Other Notes: * The addition of this operator brings this mode more into line with being a kind of "Trashcan" place, with this new operator being the manual "Empty Trash" button. If the "Orphaned Datablocks" name is too obscure, maybe we could rename this mode to "Trash" or something similar?
2015-02-11Outliner: ContextMenus for constraints/modifiersCampbell Barton
Context menu to toggle render, visibility & delete D996 by @lichtwerk
2015-02-09Fix outliner crash renaming library /w filterCampbell Barton
D1045 by @a.romanov