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
path: root/intern
AgeCommit message (Collapse)Author
2020-10-31Cleanup: rename functions for consistency with other process*Events functions.Nicholas Rishel
2020-10-31Cleanup: Use C style comments, punctuation, and capitalization.Nicholas Rishel
Added missing function documentation.
2020-10-31Remove Wintab logging.Nicholas Rishel
2020-10-31Add Wintab debug logging as a CMake option WITH_WINTAB_DEBUG.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Finish the comment's thought explaining pessimistic button ups events forNicholas Rishel
Wintab.
2020-10-31Return of the Wintab refactor.Nicholas Rishel
Previously Wintab was handled by saving the most recent tablet pressure and tilt information and deferred appending tablet infromation to Windows mouse events. This caused synchronization issues evident at the beginning and ending of strokes where pressure and tilt were either ahead or behind in time from mouse button up or down events. This also dicarded swaths of data which resulted in blockly grease pencil lines most apparent when a context switch resulted in several coalesced mouse events. This patch changes the behavior of Wintab to instead rely entirely on Wintab information for pressure, tilt, position, and button input. Wintab has several design decisions and conventions which complicate relying soley on it's input while retaining current workflows reliant on non-API behavior. For example, many device optionally allow the user to map barrel buttons to non-mouse actions. These mappings may or may not modify the intended behavior when touching the stylus down, such as scroll vs alt mappings. This behavior is not exposed in the Wintab API, but Wintab will continue updating button state sans this necessary context. To work around the problem, this refactor synchronizations tablet input to Windows mouse down and up events, this captures events which should result in pen input while allowing events such as pen scrolling. Until a Windows mouse down event fires Wintab input is left unprocessed; when a Windows up event occurs Wintab is processed until a corresponding button up event is found. Wintab allows for either button state or changes to be reported, but not both. An earlier refactor tried to use button changes to let state to be managed by Wintab. This was replaced when it was found that button change events were unreliable at corner cases such as switching windows. It was also found that with Wacom drivers Wintab peek functions would modify events in the queue causing errant and loss of button events. For the latter stated reason this patch opts to read all Wintab events into a queue as they arrive, removing events as they become stale. This was chosen over using Wintab peek functions due to the afformentioned issue. As a bonus this seems to work better as it prevents the queue in Wintab from filling, thus neither a flood of events need to be handled when Wintab processing begins and a Wintab implementation need not be trusted to overwrite old events in it's queue. Maniphest Tasks: T75566 Differential Revision: https://developer.blender.org/D7840
2020-10-31Before a wintab button event is generated, generate a GHOST mouse moveNicholas Rishel
event to the button down location as this should be a more accurate point of contact than the last mouse move event. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Adding explanitory comment to explain why tablet API check is necessaryNicholas Rishel
for Pointer input even when Wintab should be preventing Pointer events. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31When there are not associated button events, assume there is no buttonNicholas Rishel
events until one is found. This prevents errant cursor moves that occur before the Wintab button event is reported. We need to skip these events because if no button event exists, we generate one assuming it will either arrive later in the Wintab queue or that the button was from a non-Wintab device. For the case that this was generated by a non-wintab device, such as buttons mapped to mouse on the tablet pad, these cursor move events can significantly move the cursor from the intended click position. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Clarify comment to be more specific so that in the future someone knowsNicholas Rishel
the issue with Wintab button events are more significant than simply setting what buttons should receive button up/down events during context initialization. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Save Wintab packets to a local queue as WT_PACKET events arrive or whenNicholas Rishel
handling mouse input. This Wintab to mouse synchronization issues, and likely prevents queue exhaustion for some Wintab implmenetations. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Correcting the type for indexing Wintab buttons.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Change updateWintab interface to include whether window is visible so thatNicholas Rishel
window intitialization can specify whether it will be visible regardless of whether it is yet visible. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Revert "Mask all button down/up and switch back to using relative button input."Nicholas Rishel
This reverts commit 045aaf6f78f1fbb6e2bbefd234b7bae04844d42b.
2020-10-31Fix type for physicalButton in wintabMouseToGhost.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Fix return value of WTPacketsGet.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Move assignments into initializer list for GHOST_EventButtonNicholas Rishel
and GHOST_EventCursor. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Mask all button down/up and switch back to using relative button input.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Document inline that PACKETDATA and PACKETMODE modify external headers toNicholas Rishel
discourage reducing their scope to the only place they're used internally. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Allow double button up, otherwise there may be a trailing 0 pressure line.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Fix T75566Nicholas Rishel
Button events now include tabletdata, so move is unnecessary. Generate mouse button events when the system has an event but Wintab did not find a correlated event. Only filter mouse button events, not Win32 Pointer events. Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com> Maniphest Tasks: T75566 Differential Revision: https://developer.blender.org/D7404
2020-10-31Button events now include tabletdata, so move is unnecessary.Nicholas Rishel
Signed-off-by: Nicholas Rishel <rishel.nick@gmail.com>
2020-10-31Revert "Revert "Windows: support high resolution tablet pen events for Wintab""Nicholas Rishel
This reverts commit e90d8422d0ed38743390f2184fde27550d7b48a7.
2020-10-30Fluid: Removed binary_python from fluid scriptSebastián Barschkis
This hack is no longer required. It was fixed in rB52b38d9c3d84 and temporarily disabled in rBa877248ac203.
2020-10-30Merge branch 'blender-v2.91-release'Brecht Van Lommel
2020-10-30Fix T82027, T81718: Cycles crash with volume animation playbackBrecht Van Lommel
2020-10-30Fluid: Switch to binary_pythonSebastián Barschkis
This change is required since rB52b38d9c3d84. Why a bpy reference is there in the first place is to be investigated.
2020-10-30Merge branch 'blender-v2.91-release'Brecht Van Lommel
2020-10-30Fix Cycles map range node missing clamp socketBrecht Van Lommel
No effect on the Blender integration yet, but needs to be solved for the upcoming change to encapsulate sockets.
2020-10-30Merge remote-tracking branch 'origin/blender-v2.91-release'Dalai Felinto
2020-10-30Fluid: Added APIC simulation methodSebastián Barschkis
Basic support for velocity updates with the APIC method. This commit adds APIC to the already existing dropdown menu for the simulation method. The APIC plugin within Mantaflow has been updated to the latest version.
2020-10-30Fix macOS mouse positions inaccuracyBrecht Van Lommel
Don't use the current mouse position at the time the event is handled, but rather the position at the time of the event. This should make e.g. brush stroke paths more accurate. In addition, this may solve issues with other software that does mouse position smoothing. Ref T82143. Use of the current mouse position was added in 12b642062c6f as part of a large commit that also made continuous grab work. But it appears to still work getting the mouse position from the event.
2020-10-29Cycles: silence unused variable warningDalai Felinto
2020-10-29Merge branch 'blender-v2.91-release'Kévin Dietrich
2020-10-29Fix T82129: Cycles "Persistent Images" incorrectly retains scene dataKévin Dietrich
The issue stems from the fact that scene arrays are not cleared when rendering is done. This was not really an issue before the introduction of the ownership system (rB429afe0c626a) as the id_map would recreate scene data arrays based on their new content. However, now that the id_maps do not have access to the scene data anymore the arrays are never created. Another related issue is that the BlenderSync instance is never freed when the persistent data option is activated. To fix this, we delete nodes created by the id_maps in their destructors, and delete the BlenderSync instance before creating a new one, so the id_maps destructors are actually called. Reviewed By: brecht Maniphest Tasks: T82129 Differential Revision: https://developer.blender.org/D9378
2020-10-29Cycles: abort rendering when --cycles-device not foundBrecht Van Lommel
Rather than just printing a message and falling back to the CPU. For render farms it's better to avoid a potentially slow render on the CPU if the intent was to render on the GPU. Ref T82193, D9086
2020-10-29Libmv: Fix clang inconsistent-missing-override warnings.Ivan Perevala
Reviewed By: sergey, ankitm Differential Revision: https://developer.blender.org/D9377
2020-10-28Cycles: internal support for alpha output for attribute nodeAlexander Gavrilov
Not exposed in Blender yet. Ref D2057
2020-10-28Cycles: internal support for per-instance and per-geometry attributesAlexander Gavrilov
The existing code for this was incomplete. Each instance can now have a set of attributes stored separately from geometry attributes. Geometry attributes take precedence over instance attributes. Ref D2057
2020-10-28Cycles: refactor to make attribute lookup slightly more efficientBrecht Van Lommel
Ref D2057
2020-10-28Cycles: internal support for float4 geometry attributesAlexander Gavrilov
Previously only float3 and byte4 was supported. Ref D2057
2020-10-28Cycles: refactor to split surface and volume attribute lookup moreBrecht Van Lommel
This avoids OpenCL inlining heavy volume interpolation code once for every data type, which could cause a performance regression when we add a float4 data type in the next commit. Ref D2057
2020-10-28Tracking: Simplify configuration of intrinsics to refineSergey Sharybin
Previously, only predefined and limited set of intrinsics combinations could have been refined. This was caused by a bundle adjustment library used in the early days of the solver. Now it is possible to fully customize which intrinsics are to be refined during camera solving. Internally solver supports per-parameter settings but in the interface they are grouped as following: * Focal length * Optical center * Radial distortion coefficients (which includes k1, k2, k3, k4) * Tangential distortion coefficients (which includes p1, p2) Differential Revision: https://developer.blender.org/D9294
2020-10-28Libmv: Fix typo in packed intrinsicsSergey Sharybin
Was using doing an implicit cast of floating point value to boolean. Was not noticed before because the boolean value was never never used.
2020-10-27Cleanup: use over-line for doxy commentsCampbell Barton
Follow our code style for doxygen sections.
2020-10-27Revert "Cycles API: encapsulate Node socket members"Brecht Van Lommel
This reverts commit 527f8b32b32187f754e5b176db6377736f9cb8ff. It is causing motion blur test failures and crashes in some renders, reverting until this is fixed.
2020-10-27Cycles API: encapsulate Node socket membersKévin Dietrich
This encapsulates Node socket members behind a set of specific methods; as such it is no longer possible to directly access Node class members from exporters and parts of Cycles. The methods are defined via the NODE_SOCKET_API macros in `graph/ node.h`, and are for getting or setting a specific socket's value, as well as querying or modifying the state of its update flag. The setters will check whether the value has changed and tag the socket as modified appropriately. This will let us know how a Node has changed and what to update, which is the first concrete step toward a more granular scene update system. Since the setters will tag the Node sockets as modified when passed different data, this patch also removes the various `modified` methods on Nodes in favor of `Node::is_modified` which checks the sockets' update flags status. Reviewed By: brecht Maniphest Tasks: T79174 Differential Revision: https://developer.blender.org/D8544
2020-10-26Cycles: Add support for OptiX 7.2 SDKPatrick Mours
2020-10-26Merge branch 'blender-v2.91-release'Philipp Oeser
2020-10-26Fix T69911: Adaptive subdivision offscreen dicing does not work correctly if ↵Philipp Oeser
the camera is shifted Code was assuming frustrum planes are symmetrical which is not the case for shifting. This lead to a shrinking region if shift was negative (and a growing region if shift was positive) So instead of only keeping track of plane on one side (and mirroring over in code) get the actual planes after shifting and use these instead. This code corrects this for ortho and perspective cameras, it does not touch panoramic cameras. Reviewed By: brecht Maniphest Tasks: T69911 Differential Revision: https://developer.blender.org/D9342