Commit Graph

168 Commits

Author SHA1 Message Date
Dalai Felinto 2d1cce8331 Cleanup: `make format` after SortedIncludes change 2020-03-19 09:33:58 +01:00
Julian Eisel b2ee1770d4 Cleanup: Rename ARegion variables from ar to region
The old convention was easy to confuse with ScrArea.
Part of https://developer.blender.org/T74432.

This is mostly a batch rename with some manual fixing. Only single word
variable names are changed, no prefixed/suffixed names.

Brecht van Lommel and Campbell Barton both gave me a green light for
this convention change.

Also ran clan clang format on affected files.
2020-03-06 17:19:23 +01:00
Jeroen Bakker 297261eb90 CodeCleanup: Added enums to opengl render functions
Motivation the functions get 3 different kind of flag parameters (ImBuf,
DrawType, OffscreenRendering) the naming of the flags were not clear,
leading to mistakes and unnecessary time spend debugging.
2020-03-06 12:11:55 +01:00
Bastien Montagne 56116bbdf4 Cleanup/refactor: Rename `BKE_library` files to `BKE_lib`.
Note that `BKE_library.h`/`library.c` were renamed to
`BKE_lib_id.h`/`lib_id.c` to avoid having a too generic name here.

Part of T72604.
2020-02-10 13:00:42 +01:00
Julian Eisel 8a7859b9ad Fix T73428: Editor type dropdown menu missing in VSE
Mistake in 6a49161c8c, the tool-header region was not created when
creating a new VSE editor (as opposed to an existing one in some
workspace).

There was also no way to get the tool-header to show in such cases.
2020-01-27 11:21:35 +01:00
Richard Antalik 6a49161c8c VSE: Tool system integration
Add toolbar to sequencer regions.

A bit of refactoring has to be done in RNA space.
Currently there is only cut tool implemented to serve as template for
anybody who would like to add more.
2020-01-22 15:06:18 +01:00
Richard Antalik a4cf2cf2de VSE: Add Adjust Last Operation panel to the video sequencer
Add Adjust Last Operation panel to Sequencer.

`OPTYPE_REGISTER` was removed form some operators and few properties were hidden
So they don't show up on the panel

Author: a.monti

Reviewed By: ISS

Differential Revision: http://developer.blender.org/D6210
2020-01-22 02:07:54 +01:00
Alessio Monti di Sopra dc87d09b8b UI: allow to hide markers region per editor
Instead of having the option to show marker lines,
make the marker region optional.

- Added a Show Markers entry in the View menu of the animation editors.
- If the markers region is not active then the Marker menu gets hidden.
- Removed marker menu from the driver editor
  and don't allow to use marker operators.
2019-11-30 17:08:04 +11:00
Jacques Lucke a1aa4a2597 RNA: Cleanup PointerRNA struct
The old layout of `PointerRNA` was confusing for historic reasons:
```
typedef struct PointerRNA {
  struct {
    void *data;
  } id;

  struct StructRNA *type;
  void *data;
} PointerRNA;
```

This patch updates it to:
```
typedef struct PointerRNA {
  struct ID *owner_id;
  struct StructRNA *type;
  void *data;
} PointerRNA;
```

Throughout the code base `id.data` was replaced with `owner_id`.
Furthermore, many explicit pointer type casts were added which
were implicit before. Some type casts to `ID *` were removed.

Reviewers: brecht, campbellbarton

Differential Revision: https://developer.blender.org/D5558
2019-08-23 09:52:12 +02:00
Campbell Barton 8f565f5a6f WM: reuse visible region calculation
Avoids calculating the visible part of a region whenever
on-screen overlays are drawn.
2019-08-16 06:44:25 +10:00
Brecht Van Lommel 966dbddf3d Fix sequencer sidebar not being wide enough by default to show timecodes 2019-06-20 19:00:51 +02:00
Campbell Barton a9450dbf0d Gizmo: add 2D navigation for image/clip/sequencer views 2019-05-31 21:51:02 +10:00
Brecht Van Lommel 8fdbd1377e Sequencer: ensure Strip is the default active panel 2019-05-22 19:52:41 +02:00
Brecht Van Lommel e39737f166 UI: make sidebars in 3D view and other editors a little wider and consistent 2019-05-15 16:17:23 +02:00
Jacques Lucke 3b9813fe50 UI: Move scrollbars to the right in animation editors
The text, that was in the scrollbars, stays on the left.

Reviewers: brecht, billreynish

Differential Revision: https://developer.blender.org/D4821
2019-05-08 15:16:05 +02:00
Jacques Lucke f2b7582b27 UI: Animation editor scrubbing area
The main reason for this change is to allow setting the
active frame with the left mouse button, while still being
able to select e.g. keyframes with the same mouse button.

The solution is to introduce a new scrubbing region with
a specialized keymap. There are a couple of related todos,
that will be handled in separate commits.
Those are listed in D4654.

This solves T63193.

Differential Revision: https://developer.blender.org/D4654

Reviewers: brecht, billreynish
2019-05-07 15:09:14 +02:00
Richard Antalik 337cac760b VSE: Cache rewrite
This patch implements new cache system.
Aim is to give user more control over cache, so it can be maximally
utilized. This is done through sequencer timeline side panel
in category proxy & cache.
Cached images are also visualized in timeline, controled by
sequencer timeline view->cache menu

Functional changes:
 - NOT use IMB_moviecache API
 - refactor names of cached image types
 - each scene owns 1 sequencer cache
 - merge preprocess cache into per-sequencer cache
 - cache links images rendered per frame in order as they are created
 - add cache content visualization tool
 - add RNA properties to control the cache

More info can be found in design notes in blenkernel/intern/seqcache.c
and in https://developer.blender.org/D4443

Reviewed By: brecht

Differential Revision: https://developer.blender.org/D4443
2019-04-28 14:50:48 -07:00
Jacques Lucke ea80264381 Refactor: allow event handlers to have a poll function
Previously only a fixed bounding box could be used.
This was not flexible enough.
T63193 will benefit from this refactor.

Reviewers: brecht, campbellbarton
2019-04-24 17:34:48 +02:00
Campbell Barton 690ed63eb5 Cleanup: unused region init functions 2019-04-18 20:02:09 +02:00
Campbell Barton e12c08e8d1 ClangFormat: apply to source, most of intern
Apply clang format as proposed in T53211.

For details on usage and instructions for migrating branches
without conflicts, see:

https://wiki.blender.org/wiki/Tools/ClangFormat
2019-04-17 06:21:24 +02:00
Campbell Barton ce3b78c73a Cleanup: style, use braces for editor/spaces 2019-03-26 21:16:47 +11:00
Richard Antalik 005626b8c6 Refactors preview drawing code with few functional modifications:
Fix T61241

 - Changing preview size does not affect drawn image size, only resolution.
 -- Consistent behavior, when changing full-size / proxy / scene render size
 -- Scopes are rendered in *same size* as source image
 -- Over all, user does not have to readjust preview zoom.

Reviewed by: Brecht

Differential revision: https://developer.blender.org/D4315
2019-02-27 13:48:27 -08:00
Campbell Barton 702a2ba0ef Cleanup: quiet undeclared variable warnings 2019-02-23 19:20:20 +11:00
Jacques Lucke 3b3eba6374 Markers: Make marker lines in sequencer and graph editor optional
- Makes it possible to show a vertical line for every marker in the graph editor.
- Makes the marker line visiblity optional in the sequencer and graph editor.

Request from @hjalti.

Reviewers: brecht

Differential Revision: https://developer.blender.org/D4348
2019-02-18 10:42:06 +01:00
Campbell Barton de13d0a80c doxygen: add newline after \file
While \file doesn't need an argument, it can't have another doxy
command after it.
2019-02-18 08:22:12 +11:00
Campbell Barton eef4077f18 Cleanup: remove redundant doxygen \file argument
Move \ingroup onto same line to be more compact and
make it clear the file is in the group.
2019-02-06 15:45:22 +11:00
Campbell Barton 65ec7ec524 Cleanup: remove redundant, invalid info from headers
BF-admins agree to remove header information that isn't useful,
to reduce noise.

- BEGIN/END license blocks

  Developers should add non license comments as separate comment blocks.
  No need for separator text.

- Contributors

  This is often invalid, outdated or misleading
  especially when splitting files.

  It's more useful to git-blame to find out who has developed the code.

See P901 for script to perform these edits.
2019-02-02 01:36:28 +11:00
Richard Antalik a451d4abbc Fix T59644: FPS meter not showing in VSE
Issue caused probably by typo
2018-12-21 16:27:08 -08:00
Campbell Barton 9ea645862c Preferences: add option for header position
Sets the header position for newly created windows with few exceptions
(preferences is always bottom, file-selector is always top).
2018-12-14 09:54:34 +11:00
Brecht Van Lommel c39f34def9 Fix Cycles viewport render info overlapping other text.
Now it shows more compact info below the view/object name. Render time and
memory usage is left out, as in most cases this is not so important. These
could be added back optionally if needed.
2018-11-08 18:31:33 +01:00
Bastien Montagne 64ec05b64d Cleanup: remove some useless BKE_library and BKE_main includes.
Makes it simpler to make some changes...

Also fix order of some includes (use alphabetical please).
2018-11-07 20:58:54 +01:00
Campbell Barton c3d170d538 Sequencer: replace notifier /w message-bus 2018-10-30 11:49:06 +11:00
Brecht Van Lommel 58adc58661 Merge branch 'master' into blender2.8 2018-09-27 15:49:59 +02:00
Brecht Van Lommel a247b53084 Spelling fixes in comments and descriptions, patch by luzpaz.
Differential Revision: https://developer.blender.org/D3732
2018-09-27 15:36:35 +02:00
Campbell Barton 7c6136b35c Merge branch 'master' into blender2.8 2018-08-31 13:40:10 +10:00
Campbell Barton 18d135d05c Cleanup: rename WM_keymap_find -> WM_keymap_ensure 2018-08-31 13:36:46 +10:00
Brecht Van Lommel 74016d73db WM: drag and drop poll functions can now specify a custom tooltip. 2018-08-10 17:53:00 +02:00
Brecht Van Lommel 2bef8ca1b8 Cleanup: pass window to listeners, instead of screen + workspace. 2018-07-04 18:40:33 +02:00
Campbell Barton b076b3853c Merge branch 'master' into blender2.8 2018-07-02 12:03:56 +02:00
Campbell Barton b88e51dd55 Cleanup: use bool for poll functions 2018-07-02 11:51:31 +02:00
Campbell Barton 4d39da1060 Merge branch 'master' into blender2.8 2018-06-28 23:57:00 +02:00
Campbell Barton 46dceefc35 WM: Remove Screen Cast
This feature is better handled by specialized tools.
2018-06-28 23:40:51 +02:00
Campbell Barton 691471fe22 Cleanup: add simplified panel callbacks 2018-06-11 19:31:56 +02:00
Campbell Barton 95011f6d48 Merge branch 'master' into blender2.8 2018-06-04 09:39:04 +02:00
Campbell Barton 44505b38df Cleanup: strip trailing space in editors 2018-06-04 09:31:30 +02:00
Campbell Barton bfe1d0e0dc Merge branch 'master' into blender2.8 2018-06-01 18:26:42 +02:00
Campbell Barton 75fc1c3507 Cleanup: trailing whitespace (comment blocks)
Strip unindented comment blocks - mainly headers to avoid conflicts.
2018-06-01 18:19:39 +02:00
Campbell Barton bcf6cc1f6b Change startup defaults
- Default Lamp increased strength (10x stronger)
- 3D View & Camera Lens = 50mm
- Camera film size = 36x24mm Full Frame
- Render Size Percentage = 100%
- Render Display = New Window
- Scene Units = Metric
- Color Management View = Filmic
- Workbench Object Overlap = ON
- Headers on top for all editors, except the Timeline at the bottom
- Default Properties tab = Object Properties
- Generate UV's = ON

See T47064
2018-05-15 16:14:16 +02:00
Julian Eisel 9a35ad752e Cleanup: Get rid of context in editor 'new' callback
Requiring context means we can't easily create new editors to replace deprecated
ones in versioning code.
Think it's reasonable to give editors access to scene and area data for their
initial setup though. They mostly need it for setting "the view", as in,
scrolling values.

Also did minor cleanup in top-bar creation function.
2018-04-21 19:47:27 +02:00
Joshua Leung b5b4802af6 Fix: Copy and paste error from earlier commit adding message_subscriber callbacks
All of these were previously using the timeline theme, instead of the one
for each respective editor
2018-04-20 18:54:41 +02:00