Age | Commit message (Collapse) | Author |
|
- Add BM_mesh_debug_print & BM_mesh_debug_info.
- Report flags in Mesh.cd_flag in BKE_mesh_debug_print
- Move custom data printing into customdata.cc (noted as a TODO).
Note that the term "runtime" has been removed from
`BKE_mesh_runtime_debug_print` since these are useful for debugging any
kind of mesh data.
|
|
|
|
MSVC used to warn about const mismatch for arguments passed by value.
Remove these as newer versions of MSVC no longer show this warning.
|
|
- Added space below non doc-string comments to make it clear
these aren't comments for the symbols directly below them.
- Use doxy sections for some headers.
- Minor improvements to doc-strings.
Ref T92709
|
|
When clearing geometry the runtime mutexes of a mesh were freed. This
resulted in crashes afterwards. The clear geometry is an RNA function so
would only effect when using from scripts.
This patch separates init/freeing of the mutexes from other code so they
can be used when needed.
Reviewed By: mont29
Maniphest Tasks: T91518
Differential Revision: https://developer.blender.org/D13142
|
|
As noted in a comment now, these functions only update a cache, so they
don't change the logical state of the mesh, which is "it will have the
data when necessary." Using a const argument will help const correctness
when accessing an object's evaluated mesh.
|
|
Required changes to make it compile with clang tidy:
* Use c++ includes like (e.g. climits instead limits.h).
* Insert type casts when casting from void* to something else.
* Replace NULL with nullptr.
* Insert casts from int to enum.
* Replace designed initializers (not supported in C++ yet).
* Use blender::Vector instead of BLI_array_staticdeclare (does not compile with C++).
* Replace typedef statements.
Ref T83357.
|
|
|
|
Functions `mesh_create_eval_final_view()` and
`mesh_create_eval_final_render()` were doing the exact same thing,
except for a hack introduced in d3eb9dddd6b4 (2012-10-08, Better fix for
T32846: dupligroup messes up particle instancing on rendering) that
appears to be no longer necessary. Besides that, these functions had
confusing names. Their functionality changed over time, and whether to
do for-render or for-viewport evaluation is now actually determined by
the depsgraph evaluation mode. This means that the `..._render` function
could evaluate a mesh with viewport settings, and vice versa.
The functions are now merged into `mesh_create_eval_final()`, and the
hack has been removed. The `OB_NO_PSYS_UPDATE` flag has been removed
entirely (instead of keeping it around as deprecated flag), because it
was always only temporarily set on objects during mesh evaluation and
thus not saved to the blend file.
No expected functional changes as far as users are concerned.
|
|
This replaces header include guards with `#pragma once`.
A couple of include guards are not removed yet (e.g. `__RNA_TYPES_H__`),
because they are used in other places.
This patch has been generated by P1561 followed by `make format`.
Differential Revision: https://developer.blender.org/D8466
|
|
This bug goes back to 2.80 but doesn't seem to have been reported.
|
|
Was introduced earlier today and did not turn out to be very useful
and clear.
|
|
Intention is to be used to create mesh at the state which is an input
to the multires modifier.
|
|
|
|
|
|
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
|
|
|
|
We already have different storages for cddata of verts, edges etc.,
'simply' do the same for the mask flags we use all around Blender code
to request some data, or limit some operation to some layers, etc.
Reason we need this is that some cddata types (like Normals) are
actually shared between verts/polys/loops, and we don’t want to generate
clnors everytime we request vnors!
As a side note, this also does final fix to T59338, which was the
trigger for this patch (need to request computed loop normals for
another mesh than evaluated one).
Reviewers: brecht, campbellbarton, sergey
Differential Revision: https://developer.blender.org/D4407
|
|
While \file doesn't need an argument, it can't have another doxy
command after it.
|
|
More or less same code was being executed twice during ID copying.
Makes no sense to add yet another switch-by-ID-type to handle
specificaly runtime data during ID copying, we already have
BKE_xxx_copy_data() functions for that.
|
|
Move \ingroup onto same line to be more compact and
make it clear the file is in the group.
|
|
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.
|
|
Done using:
source/tools/utils_maintenance/c_sort_blocks.py
|
|
This is a second attempt to get the crash fixed. The original fix
worked, but it was reverted by d3e0d7f0825.
Now the logic goes as:
- All pointers which we can not have shared (the ones which are
owned by the runtime) are cleared.
- The rest of runtime stays untouched.
This seems to be enough to keep particles happy.
|
|
Passing depsgraph instead of scene, since a scene does not fully define the
state of object you want to use for the BVH.
Also, mesh_create_eval_final_view and mesh_create_eval_final_render are pretty
much the same, so mesh_create_eval_no_deform and
mesh_create_eval_no_deform_render are as well.
Issue reported on: T58734
Reviewers: sergey
https://developer.blender.org/D4032
|
|
Seems all the usecases of derived mesh are if-defed already,
so no need to have API for it in place, and definitely no
need to waste CPU ticks on converting evaluated mesh to
derived mesh.
|
|
|
|
The new weight paint drawing code converts weight to color
directly in the shader, so the old CD_PREVIEW_MLOOPCOL based
code is not needed anymore.
|
|
|
|
|
|
Also removed a bunch of unnecessary #include statements from fluidsim.c.
|
|
|
|
|
|
Also deduplicated the 'mesh as shapekey' code, we had kind of two funcs
doing the same thing here...
|
|
|
|
The function definitions still reside in DerivedMesh.c. Once we're done
porting all the DerivedMesh use to Mesh, we'll move the still-relevant
functions to mesh_runtime.c. This move is now cumbersome due to shared
statically-declared utility functions in DerivedMesh.c
|
|
|