You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
final S src = ( S ) ( ( ArrayDataAccess< ? > ) cellAccess.get().getData().createView( this ) ).getCurrentStorageArray();
Alternatively, we should make sure that createView() is called when getting the BufferAccess from an image. (For example, for ArrayImg that should be already the case.)
Even better would be to move to Java 9+, where absolute bulk put/get methods are available in Buffer and we can avoid the stateful API in MemCopy.
The text was updated successfully, but these errors were encountered:
MemCopy
implementations that copy from/toBuffer
s currently use the statefulBuffer
APIs, e.g.imglib2/src/main/java/net/imglib2/blocks/MemCopy.java
Lines 477 to 484 in 4f41d20
To make sure this works in multi-threaded scenarios, new
Buffer
views should be used in everyPrimitiveBlocks
instance.For example, this
imglib2/src/main/java/net/imglib2/blocks/CellImgRangeCopier.java
Line 221 in 4f41d20
should be something like
Alternatively, we should make sure that
createView()
is called when getting theBufferAccess
from an image. (For example, forArrayImg
that should be already the case.)Even better would be to move to Java 9+, where absolute bulk put/get methods are available in
Buffer
and we can avoid the stateful API inMemCopy
.The text was updated successfully, but these errors were encountered: