Python API support for element picking (matching selection picking) #86445
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
7 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#86445
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Currently there is no convenient way to pick the object under the mouse cursor.
Motivation
Picking an item (typically an object), under the cursor is useful for interactive tools,
for selecting a target... etc. as is already done in Blender's C code.
Currently methods of doing this are insufficient.
This limits the kinds of interactive tools that can be written (at least easily).
Proposal
For space types that support picking elements, add a method for picking items, example usage:
Since it's common to filter items based on type, or other properties, a filter function should be supported.
BMesh elements could be supported too.
Note that returning multiple values is needed in some cases if the element on it's own doesn't provide enough information. For example, a bone or vertex doesn't give access to the object, which is needed for multi-edit mode support.
Other space types can support this too.
Open Topics
Why limit this to picking? Why not support passing in a bounding box & return it's result, or a polygon and return the lasso result?
This could be handled as a separate step, mentioning it here to note that it's a possibility but not part of this proposal.
We could return an object that stores multiple values, this means if we need to add additional context to the result, it wont break scripts.
Scope
While this need not implement all data-types initially, these are data-types that could be supported.
3D View
Image View
Node Editor
Sequencer
Movie clip editor
Dope Sheet
Graph Editor
NLA
Text Editor
Python Console
Info
Outliner:
File browser
Implementation Details
Changed status from 'Needs Triage' to: 'Confirmed'
Added subscriber: @ideasman42
Added subscriber: @ckohl_art
Added subscriber: @APEC
Added subscriber: @rjg
Added subscriber: @JaumeBellet
As you may noticed I'm interested on allowing add-ons being accessible allowing a good enhancement to blender functionality. So maybe I have a look a this Only issue is having time for all things!
Added subscriber: @wilBr
picking curve samples points beetwen vertices (or 'edge' curve) would be very usefull too.
Added subscriber: @nosaka