Maniphest T93134

Set Origin causes unexpected offset on Grease Pencil strokes when Curve Editing is enabled
Closed, ResolvedBUG

Assigned To
Antonio Vazquez (antoniov)
Authored By
Sam Brubaker (rocketman)
Nov 16 2021, 5:38 PM
Tags
  • BF Blender
  • Grease Pencil
Subscribers
Antonio Vazquez (antoniov)
Falk David (filedescriptor)
Sam Brubaker (rocketman)
Shen Ciao (ShenCiao)

Description

System Information
Operating system: Linux 64-bit
Graphics card: GTX 1080 ti

Blender Version
3.1 alpha and prior

Short description of error
If you use Origin to 3D Cursor on a Grease Pencil object that uses Curve Editing, the strokes will be offset next time you enter edit mode.


Exact steps for others to reproduce the error

  1. Open attached file
  2. Use Set Origin > Origin to 3D Cursor on selected GP object
  3. Enter Edit Mode

Revisions and Commits

rB Blender
D13273
D13273

Event Timeline

Sam Brubaker (rocketman) renamed this task from Set Origin causes unexpected offset when Curve Editing is enabled to Set Origin causes unexpected offset on Grease Pencil strokes when Curve Editing is enabled.Nov 16 2021, 5:38 PM
Sam Brubaker (rocketman) created this task.
Sam Brubaker (rocketman) added a project: Grease Pencil.
Antonio Vazquez (antoniov) changed the task status from Needs Triage to Confirmed.EditedNov 16 2021, 10:36 PM
Antonio Vazquez (antoniov) claimed this task.
Antonio Vazquez (antoniov) removed Antonio Vazquez (antoniov) as the assignee of this task.
Antonio Vazquez (antoniov) changed the subtype of this task from "Report" to "Bug".
Antonio Vazquez (antoniov) added subscribers: Falk David (filedescriptor), Antonio Vazquez (antoniov).

@Falk David (filedescriptor) An update of Bezier data is missing. Could you add it because you know better than me this part of the code?

I think is missing:

BKE_gpencil_stroke_editcurve_update(gpd, gpl, gps);
   /* Update the selection from the stroke to the curve. */
   BKE_gpencil_editcurve_stroke_sync_selection(gpd, gps, gps->editcurve);
Antonio Vazquez (antoniov) added a comment.Nov 16 2021, 10:43 PM

The section to fix is object_origin_set_execfunction around line 1418

Shen Ciao (ShenCiao) added a subscriber: Shen Ciao (ShenCiao).Nov 19 2021, 3:47 AM
Antonio Vazquez (antoniov) closed this task as Resolved by committing rB52da1afbf67c: Fix T93134: Set origin broken for curve edit mode.Dec 30 2021, 11:39 AM
Antonio Vazquez (antoniov) claimed this task.
Antonio Vazquez (antoniov) added a commit: rB52da1afbf67c: Fix T93134: Set origin broken for curve edit mode.
Philipp Oeser (lichtwerk) added a commit: rBe8a8e953b3d1: Fix T93134: Set origin broken for curve edit mode.Jan 11 2022, 10:38 AM