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
2022-04-11merge to masterFabian Schempp
2022-04-11Fix: Build issue with MSVCRay Molenkamp
draw_common.h was included in a C++ file leading to the linker looking for the decorated name for `G_draw` which lead to a linker error. adding an extern "C" for C++ fixes the issue.
2022-04-11Add a utility for sampling segment indices and factors from arbitraryHans Goudey
lengths along a set of points. This can be used for the sample curves node, or finding new points along a curve when extending or shrinking it. This commit uses it in the snake hook brush as an example. The logic is similar to the uniform length sampling, but the next sample length is retrieved from the input instead of multiplication. For the sample node in the future, though this sort of sampling can be potentially done more efficiently for specific curve types besides poly curves, it's simpler, at least as a start, to work on a set of evaluated points that can be treated like a poly curve. Differential Revision: https://developer.blender.org/D14571
2022-04-11install_deps: only install codecs libs if building ffmpeg.Bastien Montagne
Avoid installing all the ogg, theora, xvid etc. codec lib dev packages unless we actually build ffmpeg itself. Otherwise they are not necessary for Blender build itself.
2022-04-11Curves edit mode: show dots for pointsKévin Dietrich
This adds support to show dots for the curves points when in edit mode, using a specific overlay. This also adds `DRW_curves_batch_cache_create_requested` which for now only creates the point buffer for the newly added `edit_points` batch. In the future, this will also handle other edit mode overlays, and probably also replace the current curves batch cache creation. Maniphest Tasks: T95770 Differential Revision: https://developer.blender.org/D14262
2022-04-11GPencil: Fix unreported missing Sculpt popover menuAntonio Vazquez
The menu with the options was not visible because the tool checked must be the sculpt, not draw. This was broken in old version, but I cannot determine when or if never worked at expected.
2022-04-11install_deps: Add pystring and libwebp.Bastien Montagne
Re. {T95206}.
2022-04-11Cleanup: quiet a couple more compilation warnings on MSVCKévin Dietrich
2022-04-11Alembic: fix clamping of frame offset during exportsKévin Dietrich
The `frame_offset` used for creating `TimeSamplings` when exporting was being clamped, which would make subframe sampling potentially fail, or get out of sync.
2022-04-11Cleanup: CacheFile, use double precision for timeKévin Dietrich
Both the Alembic and USD libraries use double precision floating point numbers internally to store time. However the Alembic I/O code defaulted to floats even though Blender's Scene FPS, which is generally used for look ups, is stored using a double type. Such downcasts could lead to imprecise lookups, and would cause compilation warnings (at least on MSVC). This modifies the Alembic exporter and importer to make use of doubles for the current scene time, and only downcasting to float at the very last steps (e.g. for vertex interpolation). For the importer, doubles are also used for computing interpolation weights, as it is based on a time offset. Although the USD code already used doubles internally, floats were used at the C API level. Those were replaced as well. Differential Revision: https://developer.blender.org/D13855
2022-04-11Painting: Canvas switcher for painting brushes/tools.Jeroen Bakker
This patch adds color attributes to TexPaintSlot. This allows an easier selection when painting color attributes. Previously when selecting a paint tool the user had to start a stroke, before the UI reflected the correct TexPaintSlot. Now when switching the slot the active tool is checked and immediate the UI is drawn correctly. In the future the canvas selector will also be used to select an image or image texture node to paint on. Basic implementation has already been done inside this patch. A limitation of this patch is that is isn't possible anymore to rename images directly from the selection panel. This is currently allowed in master. But as CustomDataLayers aren't ID fields and not owned by the material supporting this wouldn't be easy. {F12953989} In the future we should update the create slot operator to also include color attributes. Sources could also be extended to use other areas of the object that use image textures (particles, geom nodes, etc... ). Reviewed By: brecht Maniphest Tasks: T96709 Differential Revision: https://developer.blender.org/D14455
2022-04-11NLA: Remove Hold resetting between Hold_Forward BehaviorSybren A. Stüvel
Avoid Blender overwriting artist's choices. The automatic change from "Hold" (i.e. bidirectional extrapolation) to "Hold Forward" (i.e. only extrapolate forward in time) has been removed. This patch does not change strip evaluation. Between two strips, the first with `None` extrapolation and the next with `Hold`, neither strip will evaluate, which matches previous behavior. A future patch can change the evaluation behavior. Reviewed By: RiggingDojo, sybren Maniphest Tasks: T82230 Differential Revision: https://developer.blender.org/D14230
2022-04-11install_deps: Update OpenEXR to 3.1.4, Add Imath 3.1.4.Bastien Montagne
This has been... painful to get working.
2022-04-11Fix: accidentally swapped value with itselfJacques Lucke
Found in T96889.
2022-04-11install_deps: proper update of OpenVDB to 9.0.Bastien Montagne
Previous commit (rBrB59681a7ccdcf) was effectively doing nothing, due to weird hacks we had to do with OpenVDB 8.0 to 'integrate' NanoVDB. Now OpenVDB 9.0 natively includes NanoVDB, which allows us to greatly simplify that part of the code in install_deps.
2022-04-11I/O tests: change all_geometry scene to not have subd surface, and always ↵Aras Pranckevicius
print obj failure output diff details The all_objects.blend test scene (in subversion tests repo) contained an object with a subdivision surface. Which changes vertex positions slightly, depending on used OpenSubDiv version and the compile flags. It seems that the intent of the test was "test export of meshes that use modifiers", so I changed that object to be a cube with a simple "taper" modifier instead. While at it, changed OBJ exporter test code to always print the "expected and what we got" text difference details, when a test fails. Much easier to see than just "the files are different" output. The code to print that was behind an off by default flag for some reason. This diff should get comitted together with updated all_objects templates in subversion tests repo. Reviewed By: Sebastian Parborg Differential Revision: https://developer.blender.org/D14597
2022-04-11Fix T97150: Export GPencil to PDF or SVG crashes blenderAntonio Vazquez
The problem was the original file had some vertex weight information, but the weights array was empty, so the duplication was not done and the free memory crashed. To avoid this type of errors, now before duplicate weights the function checks the pointer and also the number of weights elements in the array to avoid the duplicatiopn of empty data.
2022-04-11Fix lightgroup creation without a specified nameLukas Stockner
2022-04-11Fix prefix used for display OCIO shaderSergey Sharybin
Didn't notice this to have real harmful behavior, but is still best to do things properly.
2022-04-11Curves: expose convert to particle system operator in sculpt modeJacques Lucke
Ref T96889.
2022-04-11PyAPI: use keyword only arguments for Text.region_{from/to} stringCampbell Barton
This is the convention for most parts of Blender Python API.
2022-04-11Cleanup: separate format-units for Python argument parsingCampbell Barton
With the increased use of multi-character format units and keyword-only arguments these are increasingly difficult to make sense of. Split the string onto multiple lines, one per argument. While verbose it's easier to understand and add new arguments.
2022-04-11Cleanup: Define new curves normal mode in DNAHans Goudey
Don't include the tangent mode for now, since that was never implemented for geometry nodes curves.
2022-04-11Cycles: Support adding Lightgroups from the object/world propertiesLukas Stockner
Currently, only Lightgroups that exist in the current view layer can be selected from object or world properties. The internal UI code already has support for search fields that accept unknown input, so I just added that to the API and use it for lightgroups. When a lightgroup is entered that does not exist in the current view layer (e.g. because it's completely new, because the view layer was switched or because it was deleted earlier), a new button next to it becomes active and adds it to the view layer when pressed. Differential Revision: https://developer.blender.org/D14540
2022-04-11Fix T97144 Overlay: Illegal recursive expansion of macrosClément Foucault
Was caused by the shaderCreateInfo port.
2022-04-11Fix Clang/Linux build error after line primitive parallelizationBrecht Van Lommel
2022-04-11Fix Cycles build error after recent changesBrecht Van Lommel
2022-04-11Cycles: various Linux build fixes related to Hydra render delegateBrecht Van Lommel
* Add missing GLEW and hgiGL libraries for Hydra * Fix wrong case sensitive include * Fix link errors by adding external libs to static Hydra lib * Work around weird Hydra link error with MAX_SAMPLES * Use Embree by default for Hydra * Sync external libs code with standalone * Update version number to match Blender * Remove unneeded CLEW/GLEW from test executable None of this should affect Cycles in Blender. Ref T96731
2022-04-11Cleanup: remove unused mface tesselation code from modifier stackBrecht Van Lommel
This seems to serve no purpose anymore, I don't see anywhere that CD_MFACE is requested for modifier evaluation, and it's confusing to have this in this final normals computation function. Found while looking into D14579. Differential Revision: https://developer.blender.org/D14580
2022-04-11Fix T97035: crash transferring face corner dataBrecht Van Lommel
The mechanism to instance meshes when there are no modifiers did not take into account that modifiers might get re-evaluated from an operator that requests loop normals. Now check for that case and no longer use the instance then. In the future, a better solution may be to compute loop normals on demand as is already done for poly and vertex normals, but that would be a big change. Differential Revision: https://developer.blender.org/D14579
2022-04-11Cleanup: Return early in metaball tessellation codeHans Goudey
Also declare variables where initialized and use const.
2022-04-11BLI: inline fast path of IndexRange::as_spanJacques Lucke
This frequently showed up in profiling but shouldn't. This also updates the code to use atomics for more correctness and adds multi-threading for better performance.
2022-04-11Functions: optimize simple generated multi-functionsJacques Lucke
This implements two optimizations: * Reduce virtual function call overhead when a non-standard virtual array is used as input. * Use a lambda in `type_conversion.cc`. In my test setup, which creates a float attribute filled with the index, the running time drops from `4.0 ms` to `2.0 ms`. Differential Revision: https://developer.blender.org/D14585
2022-04-11Geometry Nodes: Parallelize mesh line nodeHans Goudey
I observed a 4-5x performance improvement (from 50ms to 12ms) with five million points, though obviously the change depends on the hardware. In the future we may want to disable the parallelization in `parallel_invoke` when there is a small amount of points. Differential Revision: https://developer.blender.org/D14590
2022-04-11GPencil: Add skip option to envelope modifierHenrik Dick
This patch adds an option to only use every n-th segment of the envelope result. This can be used to reduce the complexity of the result. Differential Revision: http://developer.blender.org/D14503
2022-04-11Cleanup: Compilation warning about virtual functionsSergey Sharybin
Method which overrides a base class's virtual methods are expetced to be marked with `override`. This also gives better idea to the developers about what is going on.
2022-04-11Fix T97123: Applying modifier to multi-user: other objects were also convertedDalai Felinto
The first element of the iterator was not being tested against the flag. So in some cases it would lead to more objects been made into single-user than the active (or selected) ones.
2022-04-11Cleanup: add clarifying comment to `bpy_app_getsets`Sybren A. Stüvel
No functional changes.
2022-04-11Curves: improve Add menu for new curves objectJacques Lucke
The goal is to make the Add menu more convenient for the new curves object. The following changes are done: * Add `curves` submenu. * Add an `Empty Hair` operator that also sets the surface object. * Rename the old operator to `Random`. It's mostly for testing at this point. Differential Revision: https://developer.blender.org/D14556
2022-04-11Curves: operator to snap curves to surfaceJacques Lucke
This operator snaps the first point of every curve to the corresponding surface object. The shape of individual curves or their orientation is not changed. There are two different attachment modes: * `Nearest`: Move each curve so that the first point is on the closest point on the surface. This should be used when the topology of the surface mesh changed, but the shape generally stayed the same. * `Deform`: Use the existing attachment information that is stored for curves to move curves to their new location when the surface mesh was deformed. This generally does not work when the topology changed. The purpose of the operator is to help setup the "ground truth" for how curves are attached to the surface. When the ground truth surface changed, the original curves have to be updated as well. Deforming curves based on an animated surface will be done with geometry nodes independent of the operator. In the UI, the operator is currently exposed in curves sculpt mode in the `Curves > Snap Curves to Surface` menu. Differential Revision: https://developer.blender.org/D14515
2022-04-11Cleanup: make CustomMF_* implementations more similarJacques Lucke
2022-04-11Pose Library: avoid errors in the legacy panel when the add-on is disabledSybren A. Stüvel
Avoid errors in the legacy Pose Library panel (in Armature properties) when the Pose Library add-on is disabled. It's unfortunate that a built-in panel now has knowledge of an add-on. Then again, it's temporary (one or two Blender releases), and it now uses feature detection instead of just assuming the add-on is enabled.
2022-04-11Pose Library: use the right icon for the "More Info" buttonSybren A. Stüvel
2022-04-11Cleanup: remove incorrect commentSybren A. Stüvel
No functional changes.
2022-04-11Fix T96888: data transfer operator crash in certain situationPhilipp Oeser
The operator could crash in case the context "object" was overridden from python, but the "active_object" wasnt (and the active object was not a mesh). Reason for the crash is a mismatch in the operators poll function `data_transfer_poll` vs. `dt_layers_select_src_itemf` -- in the former, the overriden "object" was respected (and if this was a mesh, the poll was permissive), in the later it wasnt and only the "active_object" was used (if this was not a mesh, a crash would happen trying to get an evaluated mesh). Now rectify how the object which is used is being fetched -> use `ED_object_active_context` everywhere (see also rBe560bbe1d584). Maniphest Tasks: T96888 Differential Revision: https://developer.blender.org/D14552
2022-04-11BLI: add missing materialize methods for virtual arraysJacques Lucke
This does two things: * Introduce new `materialize_compressed` methods. Those are used when the dst array should not have any gaps. * Add materialize methods in various classes where they were missing (and therefore caused overhead, because slower fallbacks had to be used).
2022-04-11Functions: parallelize materializing arrays after field evaluationJacques Lucke
This improves performance e.g. when creating an integer attribute based on an index field. For 4 million vertices, I measured a speedup from 3.5 ms to 1.2 ms.
2022-04-11Geometry Nodes: avoid data copy in store named attribute nodeJacques Lucke
2022-04-11BLI: add CPPType utility to copy elements to a shorter arrayJacques Lucke
2022-04-11Cleanup: pass the buffer length into `txt_insert_buf`Campbell Barton
Also remove redundant NULL check.