Page MenuHomePhabricator

SceneIORewrite: Handle Properties optimally
Closed, WontfixPublic

Description

Description:
we need to find a sensible ways to handle properties in Scenes and in general.

Use-Case: Properties are currently serialized inside SceneIO. a more general way should be found.

Practical Implementation:
the easiest would be to reuse the current system.
1)Reader/Writer may write a subset of Basedata known to them into their respective file. In RAM, this set of properties will be held in a list of properties inside the Basedata itself.

  1. an arbitrary number of properties may exist per render window. all of these are serialized into a separate property file.

Effort: Low, mostly reusable

Ideal Implementation:
Rethink property design and develop a writer for them. Think about a sidecar-comcept that allows to write sidecar files for files that contain all relevant properties and use that inside and outside of MITk Scene-Files.
Estimated Effort: Relatively low

Open Questions:
Do we want/need Sidecar files outside of MITK Scene files?
Is the old property concept still adequate or do we need a complete overhaul?

Related Objects

Event Timeline

Additionally, Ingmar mentioned a problem with Properties that are added in new iterations of a writer. We may need to think about a mechanism to handle absent/expected properties gracefully.

Quoting Ingmar's Mail:

I just debugged into the serialization because all images within our project files that we created before moving to the 2015.05.0 release show up in rainbow color, not in gray values.

I found out that there has been a change in the serialization. Now there is an additional property "LookupTable" in the properties file.
During loading an mitk file the default behavior is to add a rainbow LUT. I guess that is to support other image types from the diffusion application?
But as the "old" project files don't contain the property the images get also drawn in rainbow color.
Then if you go into the DataManager plugin and want to reset the colormap it automatically switches to "grayscale" once the context menu opens up.

(In reply to Keno März from comment #1)

Additionally, Ingmar mentioned a problem with Properties that are added in
new iterations of a writer. We may need to think about a mechanism to handle
absent/expected properties gracefully.

This problem is annoying to some users and I have a local fix ready that seems legit to me. I opened T19354.

kislinsk claimed this task.
kislinsk added a subscriber: kislinsk.
This task was automatically closed because it wasn't updated at least since July 2016 (over 2 years). Please re-open this task if you think that it is still relevant. This most probably means that you will resolve it.