Image projection triggers assert #82545
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#82545
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: Linux-5.4.0-52-generic-x86_64-with-debian-bullseye-sid 64 Bits (Ubuntu 20.04)
Graphics card: GeForce RTX 2060 SUPER/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 450.80.02
Blender Version
Broken: version: 2.92.0 Alpha, branch: master (modified), commit date: 2020-11-09 11:54, hash:
0c4d12986a
Short description of error
When projecting a camera image onto the mesh, I sometimes get an assert. I finally succeeded in creating a .blend which can reliably reproduce the issue.
Exact steps for others to reproduce the error
Open the attached .blend assert_during_projection_painting.blend
In the properties pane click on 'Apply Camera Image' and choose img_101.jpg
backtrace:
Added subscriber: @Baardaap
Added subscriber: @rjg
Changed status from 'Needs Triage' to: 'Confirmed'
I can confirm this assert on a Windows build. The
BLI_assert(ps->pixel_sizeof == project_paint_pixel_sizeof(ps->tool));
is triggered inproject_paint_uvpixel_init
.BLI_assert failed: source/blender/editors/sculpt_paint/paint_image_proj.c:1889, project_paint_uvpixel_init(), at 'ps->pixel_sizeof == project_paint_pixel_sizeof(ps->tool)'to Image projection triggers assertI will try to bisect this tomorrow.
I'll can do a bisect myself. At least I'll test if it already happened in 2.80. My guess is that is has always been there, because I've experienced the crash in 2.80 as well, though I'm of course not completely sure if it was the same, as that was a release build.
@Baardaap Alright, thank you!
I have a good bisecting setup ready to go, and 2.83 doesn't crash. I'll do the bisect now.
Alas. v2.83 already had the assert. It doesn't trigger in release mode of course, so at first I though v2.83 was ok. But a debug build does assert in the same place.
I didn't succeed in building anything older than v2.83 anything older I try to build I get linker errors and I can't figure out how to solve them. (I do checkout the correct precompiled libs from svn, but still I get linker errors).
But my first theory still stands (that this is hard to bisect because it has always been there).
I will take another look at it tomorrow, I'm currently bisecting another issue. Taking a look at the code it seems that
project_paint_uvpixel_init
expects thatproject_state_init
is previously run, since that function setsps->pixel_sizeof
and it should be equal toproject_paint_pixel_sizeof(ps->tool);
.The
ps->tool
is not the same duringproject_state_init
andproject_paint_uvpixel_init
. Therefore, the size retrieved byproject_paint_pixel_sizeof(ps->tool)
is different. However, I'm not familiar enough with the code to be sure if the entire code really needs them to be equal. It might also be that it's fine as long asps->pixel_sizeof >= sizeof(ProjPixel)
as is checked inproject_state_init
.@Baardaap : cannot repro the assert anymore (at least not in current main)
Could you check if this is still an issue?
Is does seem to be fixed. Tried with a few other old projects (where I detected it first back then) and haven't seen the assert anymore.