Page MenuHome

Spreadsheet: Support showing data from original/unevaluated object.
ClosedPublic

Authored by Jacques Lucke (JacquesLucke) on Mar 12 2021, 11:54 AM.

Diff Detail

Repository
rB Blender
Branch
spreadsheet-context (branched from master)
Build Status
Buildable 13477
Build 13477: arc lint + arc unit

Event Timeline

Jacques Lucke (JacquesLucke) requested review of this revision.Mar 12 2021, 11:54 AM
Jacques Lucke (JacquesLucke) created this revision.

Working great, I didn't find any fundamental issues.
For the Original state this dropdown doesn't really make sense, right? Right now we can only have a single geometry type in an object's original data. I think it should maybe be removed but instead the mesh/volume/etc. data-block should move to the breadcrumbs.
Not sure that this is the best solution, but I think this should probably work differently than it does right now.

I don't know if in the Original option we should show evaluated data. (e.g., vertex_normal). What do you think?

@Simon Thommes (simonthommes) the dropdown you mentioned will be replaced by the "outliner" navigation anyways. I don't think it matters in this case.

Now, since this is going to be the same "dropdown" menu where users will pick Object, Node, Modifier, Scene, Collection, ... I don't think the current name/tooltip is correct (Object State Eval).

Yes, we could hide the geometry component type dropdown in this case and detect it automatically. Should I do this change or not?

Not sure about the normals. It's data that is automatically derived and could be useful. It's a bit different from user generated attributes which are only added when the object is evaluated.

I mean if this change is going to be redundant soon it doesn't really matter, @Dalai Felinto (dfelinto) has a point.
But once we have the navigation in the side panel, I think it would still make sense to hide the ones that have no data by design, or gray them out. So I think if this will be easier already addressing it in the current version and doesn't create unnecessary work, it could still be done now.

  • automatically detect geometry component type from original object
source/blender/editors/space_spreadsheet/spreadsheet_from_geometry.cc
337–338

Looks like you can just pass SpaceSpreadsheet *sspreadsheet rather than retrieving it from the context again. Since this function already has the object to use, I think it's working at a lower level than bContext

368–369

This is potentially a heavy operation to do on every single redraw.
I wonder if there's another way to retrieve the Mesh before modifier evaluation when there are modifiers.

And there's probably no way to cache this since the data could be changed in edit mode... hmm

source/blender/makesrna/intern/rna_space.c
7319

I'd use the full "Evaluation" rather than "Eval"

  • don't pass context
  • change eval to evaluation
  • add comment

The commit should make it clear that editing original data will come in a next step.

source/blender/editors/space_spreadsheet/spreadsheet_from_geometry.cc
368–369

"Later", right ;)
But yeah, that's something that could be a modeling module task or something

This revision is now accepted and ready to land.Mar 13 2021, 4:19 PM