API, Changing part of evaluated object.original resets all attributes #77008
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
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#77008
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?
System Information
Operating system: Windows-7-6.1.7601-SP1 64 Bits
Graphics card: GeForce GTX 780 Ti/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 442.59
Blender Version
Broken: version: 2.81 (sub 16), branch: master, commit date: 2019-12-04 11:32, hash:
f1aa4d18d4
Worked: (optional)
Short description of error
Changing a part of evaluated object.original during animation resets all object attributes to those of the last visible frame before rendering of animation started.
Exact steps for others to reproduce the error
https://github.com/leomoon-studios/leomoon-textcounter/blob/master/src/leomoon-textcounter.py#L353
I enountered a problem (and possible bug) with API in this add-on. This script alters Font object text (body) on every frame.
This is achived by handler:
Depsgraph is used to get evaluated object for each animation frame. Simply taking object from bpy.context.scene.objects will not work either in viewport or during rendering animation (don't remember which one). To be specific, PropertyGroup text_counter_props, that is part of Font object, will not refresh during animation until it is taken from evaluated object.
Then, new body (text) is assigned to the Font object:
At this moment all other properties of this object (like location, rotation, scale etc.) will reset to those of the last visible frame before rendering of animation started.
I think it is a bug because, in my understanding, only body attribute should be changed by this code.
To reproduce:
Edit. I messed up file attachments. textcouer-test.blend
Added subscriber: @theres1
Added subscriber: @LeoMoon
Added subscriber: @iss
Changed status from 'Needs Triage' to: 'Needs User Info'
Is it possible to create simple .blend file with a minimalistic script that would reproduce this issue?
From your description it sounds that you are using keyframes as well. Please have a look at #71908 and check if this isn't actually duplicate report.
I made a bare bones version of the script.
textcounter-test1.blend
It looks similar to #71908 but I don't know Blender's internals deep enough to tell them apart. The couse might be the same but symptoms are a little different. In my case, I can read and use animated custom property but other standard properties reset when done so.
Thanks for update. this looks like duplicate of report I have mentioned, so I will merge it
Closed as duplicate of #71908