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
2018-10-19CTX_DATA_BEGIN for active object only (..._from_active_object)Dalai Felinto
For now only `selected_pose_bones_from_active_object`, more options can be added on demand. Discussed this with Campbell Barton. We may need this only for selected pose bones, time will tell.
2018-10-17Cleanup: remove some #if 0 blocksJacques Lucke
Reviewers: brecht, campbellbarton Differential Revision: https://developer.blender.org/D3802
2018-09-24Merge branch 'master' into blender2.8Brecht Van Lommel
2018-09-24Spelling fixes in comments and descriptions, patch by luzpaz.Brecht Van Lommel
Differential Revision: https://developer.blender.org/D3719
2018-08-29Cleanup: rename files from group to collection to match contents.Brecht Van Lommel
2018-07-31New Grease Pencil object for 2D animationAntonioya
This commit merge the full development done in greasepencil-object branch and include mainly the following features. - New grease pencil object. - New drawing engine. - New grease pencil modes Draw/Sculpt/Edit and Weight Paint. - New brushes for grease pencil. - New modifiers for grease pencil. - New shaders FX. - New material system (replace old palettes and colors). - Split of annotations (old grease pencil) and new grease pencil object. - UI adapted to blender 2.8. You can get more info here: https://code.blender.org/2017/12/drawing-2d-animation-in-blender-2-8/ https://code.blender.org/2018/07/grease-pencil-status-update/ This is the result of nearly two years of development and I want thanks firstly the other members of the grease pencil team: Daniel M. Lara, Matias Mendiola and Joshua Leung for their support, ideas and to keep working in the project all the time, without them this project had been impossible. Also, I want thanks other Blender developers for their help, advices and to be there always to help me, and specially to Clément Foucault, Dalai Felinto, Pablo Vázquez and Campbell Barton.
2018-07-15Cleanup: use variable names based on term gizmoCampbell Barton
2018-07-15WM: rename manipulator to gizmo internallyCampbell Barton
2018-07-04Workspaces: store view layer per main window, instead of per workspace.Brecht Van Lommel
It was a bit odd that the scene was stored per window but not the view layer. The reasoning was that you would use different view layers for different tasks. This is still possible, but it's more predictable to switch them both explicitly, and with child window support manually syncing the view layers between multiple windows is no longer needed as often.
2018-06-29Cleanup: trailing newlinesCampbell Barton
2018-06-17Merge branch 'master' into blender2.8Campbell Barton
2018-06-17Cleanup: trailing space for blenkernelCampbell Barton
2018-05-18Collections and groups unificationBrecht Van Lommel
OVERVIEW * In 2.7 terminology, all layers and groups are now collection datablocks. * These collections are nestable, linkable, instanceable, overrideable, .. which opens up new ways to set up scenes and link + override data. * Viewport/render visibility and selectability are now a part of the collection and shared across all view layers and linkable. * View layers define which subset of the scene collection hierarchy is excluded for each. For many workflows one view layer can be used, these are more of an advanced feature now. OUTLINER * The outliner now has a "View Layer" display mode instead of "Collections", which can display the collections and/or objects in the view layer. * In this display mode, collections can be excluded with the right click menu. These will then be greyed out and their objects will be excluded. * To view collections not linked to any scene, the "Blender File" display mode can be used, with the new filtering option to just see Colleciton datablocks. * The outliner right click menus for collections and objects were reorganized. * Drag and drop still needs to be improved. Like before, dragging the icon or text gives different results, we'll unify this later. LINKING AND OVERRIDES * Collections can now be linked into the scene without creating an instance, with the link/append operator or from the collections view in the outliner. * Collections can get static overrides with the right click menu in the outliner, but this is rather unreliable and not clearly communicated at the moment. * We still need to improve the make override operator to turn collection instances into collections with overrides directly in the scene. PERFORMANCE * We tried to make performance not worse than before and improve it in some cases. The main thing that's still a bit slower is multiple scenes, we have to change the layer syncing to only updated affected scenes. * Collections keep a list of their parent collections for faster incremental updates in syncing and caching. * View layer bases are now in a object -> base hash to avoid quadratic time lookups internally and in API functions like visible_get(). VERSIONING * Compatibility with 2.7 files should be improved due to the new visibility controls. Of course users may not want to set up their scenes differently now to avoid having separate layers and groups. * Compatibility with 2.8 is mostly there, and was tested on Eevee demo and Hero files. There's a few things which are know to be not quite compatible, like nested layer collections inside groups. * The versioning code for 2.8 files is quite complicated, and isolated behind #ifdef so it can be removed at the end of the release cycle. KNOWN ISSUES * The G-key group operators in the 3D viewport were left mostly as is, they need to be modified still to fit better. * Same for the groups panel in the object properties. This needs to be updated still, or perhaps replaced by something better. * Collections must all have a unique name. Less restrictive namespacing is to be done later, we'll have to see how important this is as all objects within the collections must also have a unique name anyway. * Full scene copy and delete scene are exactly doing the right thing yet. Differential Revision: https://developer.blender.org/D3383 https://code.blender.org/2018/05/collections-and-groups/
2018-05-01Fix crash opening files saved in sculpt/vertex paint modesSergey Sharybin
Skip access to any evaluated data when operator is run on file load, we don't have depsgraph evaluated yet. In this case we skip part of sculpt session initialization, since it will be done during depsgraph evaluation which happens after DEG_on_visible_update(). We can not skip sculpt session initialization since during normal operation we want all the data to be initialized on mode change, and not on initial brush stroke.
2018-04-20Dopesheet-Timeline: Removal of Timeline Editor!Joshua Leung
This commit removes all references to the old timeline editor. Unfortuantely, the removal of the Timeline spacetype defining functions has ended up breaking the version patching code I'd been working on earlier (as now, the editor gets marked as "unknown/info" before we get a chance to patch it!)
2018-04-20UI: New Global Top-Bar (WIP)Julian Eisel
== Main Features/Changes for Users * Add horizontal bar at top of all non-temp windows, consisting out of two horizontal sub-bars. * Upper sub-bar contains global menus (File, Render, etc.), tabs for workspaces and scene selector. * Lower sub-bar contains object mode selector, screen-layout and render-layer selector. Later operator and/or tool settings will be placed here. * Individual sections of the topbar are individually scrollable. * Workspace tabs can be double- or ctrl-clicked for renaming and contain 'x' icon for deleting. * Top-bar should scale nicely with DPI. * The lower half of the top-bar can be hided by dragging the lower top-bar edge up. Better hiding options are planned (e.g. hide in fullscreen modes). * Info editors at the top of the window and using the full window width with be replaced by the top-bar. * In fullscreen modes, no more info editor is added on top, the top-bar replaces it. == Technical Features/Changes * Adds initial support for global areas A global area is part of the window, not part of the regular screen-layout. I've added a macro iterator to iterate over both, global and screen-layout level areas. When iterating over areas, from now on developers should always consider if they have to include global areas. * Adds a TOPBAR editor type The editor type is hidden in the UI editor type menu. * Adds a variation of the ID template to display IDs as tab buttons (template_ID_tabs in BPY) * Does various changes to RNA button creation code to improve their appearance in the horizontal top-bar. * Adds support for dynamically sized regions. That is, regions that scale automatically to the layout bounds. The code for this is currently a big hack (it's based on drawing the UI multiple times). This should definitely be improved. * Adds a template for displaying operator properties optimized for the top-bar. This will probably change a lot still and is in fact disabled in code. Since the final top-bar design depends a lot on other 2.8 designs (mainly tool-system and workspaces), we decided to not show the operator or tool settings in the top-bar for now. That means most of the lower sub-bar is empty for the time being. NOTE: Top-bar or global area data is not written to files or SDNA. They are simply added to the window when opening Blender or reading a file. This allows us doing changes to the top-bar without having to care for compatibility. == ToDo's It's a bit hard to predict all the ToDo's here are the known main ones: * Add options for the new active-tool system and for operator redo to the topbar. * Automatically hide the top-bar in fullscreen modes. * General visual polish. * Top-bar drag & drop support (WIP in temp-tab_drag_drop). * Improve dynamic regions (should also fix some layout glitches). * Make internal terminology consistent. * Enable topbar file writing once design is more advanced. * Address TODO's and XXX's in code :) Thanks @brecht for the review! And @sergey for the complaining ;) Differential Revision: D2758
2018-04-18Workspaces: remove workspace engine, use 3D viewport draw mode instead.Brecht Van Lommel
ViewRender was removed, which means we can't get the render engine for files saved in 2.8. We assume that any files saved in 2.8 were intended to use Eevee and set the engine to that. A fix included with this is that .blend thumbails now draw with Clay mode, and never Eevee or Cycles. These were drawn with solid mode in 2.7, and should be very fast and not e.g. load heavy image textures. Differential Revision: https://developer.blender.org/D3156
2018-04-17Removing Blender Game Engine from Blender 2.8Dalai Felinto
Folders removed entirely: * //extern/recastnavigation * //intern/decklink * //intern/moto * //source/blender/editors/space_logic * //source/blenderplayer * //source/gameengine This includes DNA data and any reference to the BGE code in Blender itself. We are bumping the subversion. Pending tasks: * Tile/clamp code in image editor draw code. * Viewport drawing code (so much of this will go away because of BI removal that we can wait until then to remove this.
2018-04-16Depsgraph: remove EvaluationContext, pass Depsgraph instead.Brecht Van Lommel
The depsgraph was always created within a fixed evaluation context. Passing both risks the depsgraph and evaluation context not matching, and it complicates the Python API where we'd have to expose both which is not so easy to understand. This also removes the global evaluation context in main, which assumed there to be a single active scene and view layer. Differential Revision: https://developer.blender.org/D3152
2018-04-13Depsgraph: remove engine type from evaluation context.Brecht Van Lommel
This was only used for viewport rendering, where we can just pass the engine type directly. There is no technical reason why we can't draw the same depsgrpah with different render engines. It also led to some weird things like requiring a render engine for snapping and raycast API functions. Differential Revision: https://developer.blender.org/D3145
2018-04-05Remove workspace object mode, reverts changes w/ 2.8Campbell Barton
This caused too many problems syncing object modes with multiple objects/windows/workspaces, see: D3130 for details.
2018-02-09Cleanup: use workspace for object_mode when possibleCampbell Barton
2018-02-08Object Mode: move to workspace structCampbell Barton
- Read-only access can often use EvaluationContext.object_mode - Write access to go to WorkSpace.object_mode. - Some TODO's remain (marked as "TODO/OBMODE") - Add-ons will need updating (context.active_object.mode -> context.workspace.object_mode) - There will be small/medium issues that still need resolving this does work on a basic level though. See D3037
2018-02-06Use eObjectMode for function argumentsCampbell Barton
2018-02-06Object Mode: pass object mode to CTX_data_mode_enum_exCampbell Barton
2018-02-06Object Mode: Add to EvaluationContext & DRWContextStateCampbell Barton
2018-01-03Static assert for correct strings from context mode enum.Lukas Tönne
Adding new context modes requires adding a string in CTX_data_mode_string, but there is no error when omitting this other than panels using incorrect contexts. The static assert should help detect simple missing strings at least to avoid confusing errors.
2017-12-28Context: Fix scene_collectionDalai Felinto
We now allow for scene collection that is not currently linked to view layer.
2017-12-04WM: message bus replacement for property notifiersCampbell Barton
Use dynamically generated message publish/subscribe so buttons and manipulators update properly. This resolves common glitches where manipulators weren't updating as well as the UI when add-ons exposed properties which hard coded listeners weren't checking for. Python can also publish/scribe changes via `bpy.msgbus`. See D2917
2017-12-01Groups and collection: initial integrationDalai Felinto
Since we are ditching layers from Blender (2.8) we need a replacement to control groups visibility. This commit introduces collections as the building blocks for groups, allowing users to control visibility as well as overrides for groups. Features ======== * Groups now have collections This way you can change the visibility of a collection inside a group, and add overrides which are part of the group and are prioritized over other overrides. * Outliner Groups can inspect their collections, change visibility, and add/remove members. To change an override of a group collection, you need to select an instance of the group, and then you can choose "group" in the collection properties editor to edit this group active collection instead of the view layer one. * Dupli groups overrides We can now have multiple instances of the same group with an original "override" and different overrides depending on the collection the instanced object is part of. Technical ========= * Layers We use the same api for groups and scene as much as possible. Reviewers: sergey (depsgraph), mont29 (read/write and user count) Differential Revision: https://developer.blender.org/D2892
2017-11-28Cleanup: namingSergey Sharybin
2017-11-28Cleanup, naming of engine type variableSergey Sharybin
2017-11-23Cleanup: Rename ViewLayer *sl > ViewLayer *view_layerDalai Felinto
2017-11-23Rename any instance of scene layer or render layer in code with view layerDalai Felinto
The RenderResult struct still has a listbase of RenderLayer, but that's ok since this is strictly for rendering. * Subversion bump (to 2.80.2) * DNA low level doversion (renames) - only for .blend created since 2.80 started Note: We can't use DNA_struct_elem_find or get file version in init_structDNA, so we are manually iterating over the array of the SDNA elements instead. Note 2: This doversion change with renames can be reverted in a few months. But so far it's required for 2.8 files created between October 2016 and now. Reviewers: campbellbarton, sergey Differential Revision: https://developer.blender.org/D2927
2017-11-07Depsgraph: Simplify some workarounds and make API closer to finalSergey Sharybin
2017-10-31Prevent users to be able to override context engineDalai Felinto
We expose engine as a string, yet context is dealing with Pointers. To prevent a crash we may as well just forbid users to override it.
2017-10-16Workspace: Move engines to workspace and Properties Editor cleanupDalai Felinto
Engine is not stored in WorkSpaces. That defines the "context" engine, which is used for the entire UI. The engine used for the poll of nodes (add node menu, new nodes when "Use Nodes") is obtained from context. Introduce a ViewRender struct for viewport settings that are defined for workspaces and scene. This struct will be populated with the hand-picked settings that can be defined per workspace as per the 2.8 design. * use_scene_settings * properties editor: workshop + organize context path Use Scene Settings ================== For viewport drawing, Workspaces have an option to use the Scene render settings (F12) instead of the viewport settings. This way users can quickly preview the final render settings, engine and View Layer. This will affect all the editors in that workspace, and it will be clearly indicated in the top-bar. Properties Editor: Add Workspace and organize context path ========================================================== We now have the properties of: Scene, Scene > Layer, Scene > World, Workspace [Scene | Workspace] > Render Layer > Object [Scene | Workspace] > Render Layer > Object > Data (...) Reviewers: Campbell Barton, Julian Eisel Differential Revision: https://developer.blender.org/D2842
2017-07-26CLeanup: Use utility function in BKESergey Sharybin
2017-07-26Initialize time for evaluation context when creating from bContextSergey Sharybin
2017-07-24Manipulator: Expose Context.manipulator_groupCampbell Barton
Needed for operators run by the manipulator keymap so they can access their selected manipulators.
2017-07-21Pass EvaluationContext argument everywhereLuca Rood
Note that some little parts of code have been dissabled because eval_ctx was not available there. This should be resolved once DerivedMesh is replaced.
2017-07-18Context/Workspace: Get scene layer from workspaceDalai Felinto
2017-07-14Workspace: Fix crash on preview, and sanitize placeholder functionsDalai Felinto
This commit effectively makes workspace switching useless as far as the active scene layer goes. The functions from the scene layer API to get the correct scene layer from "context" were a placeholder to be addressed by the workspace commit. When workspace was merged, however G.main was used as a replacement to pass the correct argument for the functions. As it turned out (surprise!) this leads to crash on render preview. We need to get rid of: * BKE_scene_layer_context_active_ex_PLACEHOLDER * BKE_scene_layer_context_active_PLACEHOLDER And either use SceneLayer explicitly or replace it by: * BKE_scene_layer_from_workspace_get
2017-07-13Depsgraph: Begin work on making depsgraph per-scene-layerSergey Sharybin
This is a first step towards proper depsgraph "ownership", where we would allow scene to be in multiple states dependent on active workspace or scene layer. This commit introduces a basic API to get proper dependency graph for a given scene layer. It also renames scene->depsgraph to depsgraph_legacy, so it's easier to search0-n-replace in the future.
2017-07-11Avoid any possibility of using scene from different main in CTX_data_scene_layerSergey Sharybin
While these functions might be considered a temporary solution, please still be very accurate about data ownership and where data is coming from.
2017-06-13Woarkspace: Remove residue of hidden typeSergey Sharybin
There is no reason to be special for workspace and go against other design decision in Blender. If something like this is going to become a common practice in Blender it should be well thought and well tested, including tests of all supported compilers and configurations. This feature was relying on type re-definition, which is not only confusing but also available in C11 only.
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-05-26Rename BKE_layer_collection_active > BKE_layer_collection_get_activeDalai Felinto
2017-05-12Fix for edit modes (sculpt, weight paint) menus not showing in headerDalai Felinto
But introduced on 2b0f02057f457acec1ed9444ee7d833ab26d0d33
2017-05-02Draw Manager: split DRW_draw_view into 2 functionsCampbell Barton
Needed for offscreen render