Skip to content

Conversation

@sbesson
Copy link
Member

@sbesson sbesson commented Nov 23, 2012

Same as #236 rebased onto origin/develop

Roger Leigh and others added 30 commits August 7, 2012 18:06
setSeries and getSeries work by using coreIndex to compute the correct
value (replaces series), while getCoreIndex and setCoreIndex use the
coreIndex directly.  Readers using series directly have been fixed to
use getSeries.

toSeries and toCoreIndex methods convert between series and core index
numbers, and handle resolution flattening.  All functions dealing with
series numbering use these to handle conversion.
Allow use of both the
  http://www.leica-microsystems.com/scn/2010/03/10 and
  http://www.leica-microsystems.com/scn/2010/10/01
schemas.

- In order to handle both schemas identically, the pixels element
  sizeR/sizeZ/sizeC/firstIFD attributes are no longer parsed; instead
  the sizes for R, Z and C are computed from the dimensions elements.
  We do require that the dimensions are a non-sparse array.
- Fix data order as XYCZT (this matches the existing test cases).
- Thumbnails:
  + Correct IFD mapping for thumbnails
  + Get thumbnail size from correct image
  + Use flattened resolutions when getting thumbnails
Warn if the schema is unsupported, but otherwise try to read it.
This required adding toSeries and toCoreIndex to IFormatReader
(and hence ImageReader).
Subresolutions are not supported.  This removes the need for
series ↔ coreIndex conversion, since they are always the same.
These override the ReaderWrapper implementation, and return their
argument (since subresolutions are not supported).
This enables getSeries to be O(1) in addition to coreIndex.
seriesToCoreIndex and coreIndexToSeries are also O(1) when
the current series/coreIndex matches their arguments.

FileStitcher also has a series member, but this is currently
unused; it was added purely to match the FormatReader behaviour.
The existing constructor using a reader and series number has
two problems:
- it's unsuitable when using non-flattened resolutions since
  one can't directly specify the subresolution
- getSeriesCount will fail if the core[] array is not yet
  fully initialised, making this unusable when using during
  initialisation and strictly validating core[]

Here, a new (simple) copy contructor that does a simple copy
of the CoreMetadata is provided, and this is used directly
in all readers.  This is safe since they are copying their
own metadata, so avoiding the reader interface is not a problem
here.

We also update the existing constructor to use a core index
instead of series, so that it will work for all readers,
whether flat or nonflat, and internally we use setCoreIndex
and getCoreIndex.
Noticed while looking for a dataset that contains masks.
This is a continuation of what 5e5e99b
was trying to accomplish.
Conflicts:
	ant/toplevel.xml
	components/legacy/ome-editor/build.properties
	components/legacy/ome-editor/pom.xml
	components/legacy/ome-notes/build.properties
	components/legacy/ome-notes/pom.xml
@sbesson
Copy link
Member Author

sbesson commented Nov 23, 2012

Temporarily closing since final layout is still undecide (see comments of #236 vs ome/omero-documentation#150)

@sbesson sbesson closed this Nov 23, 2012
@sbesson sbesson reopened this Nov 29, 2012
@sbesson sbesson closed this Nov 29, 2012
hflynn pushed a commit to hflynn/bioformats that referenced this pull request Oct 11, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants