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
73b55a5508
Cleanup: style, use braces for draw
2019-03-28 01:14:03 +11:00
9d309b7978
Cleanup: quiet undeclared variable warning
...
Also move view_ubo into G_draw.
2019-02-23 19:20:20 +11:00
53b484d081
DNA: rename select_color -> select_id
...
The term color is misleading, it's an integer id that happens to be
written to a color in some cases, then converted back to an integer.
2019-02-19 09:45:48 +11:00
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
0b6dbbc306
Cleanup: move clipping shader lib & define into struct
...
Also compare clipping with the draw context instead of
accessing the RegionView3D, currently they're matching
but this might not always be the case.
2019-02-10 11:16:31 +11:00
16d7967c2b
Cleanup: use shorter name for shader config
...
The struct name is descriptive,
this isn't going to be confused with other variables.
2019-02-10 11:02:06 +11:00
e8292466bc
DRW: Support edit-metaball clipping
2019-02-07 00:07:30 +11:00
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
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
19b5f5493c
Cleanup: draw manager headers
2019-01-26 20:08:52 +11:00
dc3b5024be
Cleanup: add BEGIN/END to GPL headers
2019-01-23 11:32:43 +11:00
7f40d553f9
Cleanp: use single global for draw manager
...
Add 'G_draw' for all draw manager globals,
avoids adding extern to each file.
Connection between `ts` and `globals_ubo` wasn't obvious,
now called `G_draw.block` & `G_draw.block_ubo`.
2019-01-22 12:09:27 +11:00
Dalai Felinto
221d078641
Multi-Objects Metaball: Selection refactor - fix pick and box selection
...
This is inspired/based on the code we use for armature bone selection.
Both pick selection, and box selection should be working now.
2018-11-09 16:40:43 -02:00
ae57383648
Cleanup: comment blocks
2018-09-02 18:28:27 +10:00
8b24f45e6b
Object Modes: only use selection for mode switch
...
Selection is no longer needed for an object to be considered in a mode.
Part of T55246 design task, fixes T55187
2018-05-29 14:21:18 +02:00
6ebcf98943
Cleanup: whitespace, long lines, duplicate include
2018-05-26 11:05:23 +02:00
4bbb1d4e5e
DRW: Rename some DRW_STATE_* for more consistency.
2018-05-20 19:17:11 +02:00
Dalai Felinto
e51bf11b15
Remove ViewLayer settings - cleanup 1/2
2018-05-16 23:13:28 +02:00
e4774c0b2d
Metaball: pointers used in DRW_shgroup_call_dynamic_add don't need to hold the reference.
2018-05-02 21:26:43 -03:00
bfc9d426bb
Multi-Object Editing
...
This adds initial multi-object editing support.
- Selected objects are used when entering edit & pose modes.
- Selection & tools work on all objects however many tools need porting
See: T54641 for remaining tasks.
Indentation will be done separately.
See patch: D3101
2018-04-16 17:56:50 +02:00
fa0e89b9e8
Metalball drawing: rename mball helpers to handles
...
and also rename some related functions
2018-02-16 02:01:09 -02:00
dacc6d4b02
Object Mode: remove Scene.obedit in draw manager
...
Part of larger change to remove this variable entirely.
2018-02-13 18:15:47 +11:00
b6dbd8723c
DRW / Render: Add support for render pipeline in drawmanager.
...
For simplicity we choose to execute the rendering of Opengl engines in the main thread and block the interface.
This might be addressed in the future at least for video rendering.
A drawmanager wrapper (DRW_render_to_image) is called by the render pipeline to set up the Opengl state and then call the specific draw_engine->render_to_image function.
2018-01-29 22:00:15 +01:00
dc4c9de91a
Draw manager: Cleanup, naming
...
Similar to previous commit in Eevee.
2017-11-29 11:01:08 +01:00
88c88c4610
Fix T51210: Draw Manager: Support for Metaball Drawing
...
Differential Revision: D2914
2017-11-16 15:12:32 -02:00
198c7d3687
DRW : Add new view_update mechanism.
...
This makes updates for the viewport cleaner and also add the possibility to add a new callback called when the scene is updated.
2017-09-25 20:14:42 +02:00
b4d053efc7
Gawain API naming refactor
...
Use consistent prefix for gawain API names as well as
some abbreviations to avoid over-long names, see: D2678
2017-06-19 20:18:04 +10:00
90aff807ab
Draw Manager: Texture Memory usage improvement.
...
-Use 11_11_10 buffers for hdr content.
-Eevee compositing share 1 buffer if bloom and DOF are both activated.
-Fix slowdown when resizing EEVEE viewport.
-Removed DRW_BUF_*** enums causing confusion.
2017-05-16 20:30:17 +02:00
8f028ec840
Cleanup: rename struct for private engine data
...
Also remove from pass list (there were some duplicate unused entries).
2017-04-29 16:52:12 +10:00
f1fb605ec9
GPUFramebuffer: Allow to bind a specific texture mip to framebuffer.
2017-04-18 12:52:29 +02:00
64660b902c
Use 'safe' macros for common free operation
...
Same as MEM_SAFE_FREE macro,
checks for NULL, runs free then sets NULL.
Blocks of code that do this many times are noisy and likely
errors here wouldn't be noticed immediately.
Also NULL's static vars which were being left set.
2017-04-13 13:37:27 +10:00
0c9a2def8b
Draw Engine: remove hard coded limit on array sizes
...
This removes MAX_STORAGE, MAX_BUFFERS, MAX_TEXTURES, MAX_PASSES limits.
Actual memory saving isn't so important, it just means we don't need to
manually bump these based on changes to engines.
2017-04-12 19:51:14 +10:00
cc0c5dbd91
Cleanup: use DRW_cache_mesh prefix w/ mesh objects
...
Avoid confusion for non mesh types where verts/wire/surface might apply.
Other object types use this convention already.
2017-04-12 18:11:10 +10:00
0811d089b4
Draw Manager: Use Texture flag in Framebuffer init.
2017-04-10 12:36:32 +02:00
4a8aaab0b2
Draw Manager: Use engine type pointer instead of engine name.
...
Faster search
2017-04-03 21:52:42 +02:00
deda6a43fc
Draw Engines: Make g_data struct part of the viewport storage
...
This makes viewport cache construction independant from each others and will allow multithread down the road.
2017-03-27 14:01:47 +02:00
e54d8eeab2
Draw Manager: Make Viewport Data passed by the manager call.
2017-03-27 14:01:47 +02:00
fc72a2ff4b
Draw module: code style, encapsulate static vars
2017-03-20 15:19:03 +01:00
91837cd5b0
Cleanup: warnings
2017-03-14 18:40:23 +11:00
ecce1fabca
Mode Engines: Fix MSVC compilation error.
2017-03-13 11:39:41 +01:00
9c6b9e889c
Clay Engine: Mode engine templates.
...
Standard Engine layout easy to extend.
Note that most of the work will also happen in mesh_render.c to create geometry batches.
2017-03-12 21:16:03 +01:00