Bug 363212 - Reading Multilayer EXR Files from blender crashes or doesn't work
Summary: Reading Multilayer EXR Files from blender crashes or doesn't work
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: File formats (other bugs)
Version First Reported In: 3.0 Beta
Platform: Microsoft Windows Microsoft Windows
: NOR crash
Target Milestone: ---
Assignee: Krita Bugs
URL: http://download.creamsurfer.de/krita_...
Keywords:
Depends on:
Blocks:
 
Reported: 2016-05-18 10:45 UTC by Manuel Albert
Modified: 2018-06-27 19:24 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
exr_converter.cc patch (1.35 KB, patch)
2016-05-27 16:15 UTC, schwarzeralptraum
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Manuel Albert 2016-05-18 10:45:34 UTC
For professional work we create Multilayer OpenEXRs (half float) for animations and stills. None of the files created could yet be opened in Krita. 
Some files are really HighResolution (6480x4484 with lot's of layer). Opening those files just shows loading progress until it crashes. 
Smaller Animation Frames do load, but before the image is displayed the App-Crashes.

Windows 7 64bit, 24 Gig RAM, 2x GTX 980 (non SLI)
Krita Version tested after short twitter (user: manuelalbertcom) conversation: 
krita-3.0-RC-1-master-6f75b0f-x64.zip (64 bits) 

Reproducible: Always

Steps to Reproduce:
1. Open the File

Actual Results:  
Nothing or Crash

Expected Results:  
Open the file and display the layers

For better investigation I uploaded a sample file:
http://download.creamsurfer.de/krita_bugreport/samplefile.exr (this is a production file/testrender)
Comment 1 Halla Rempt 2016-05-18 11:06:49 UTC
Hi Manuel,

Thanks for your report. I can confirm the crash with your samplefile, it's really useful to have access to that!. How were the files created?

Notes:

* The actual OS doesn't matter. 
* It's not a regression from Krita 2.9: that crashes as well on these files.
Comment 2 Halla Rempt 2016-05-18 11:07:28 UTC
The backtrace from Krita 3: (From 2.9 is similar, also happens in allocating tile data)

malloc (
    this=0x7ffff6ca8648 <boost::singleton_pool<KisTileData, 32768u, boost::default_user_allocator_new_delete, boost::mutex, 128u, 2048u>::storage+40>) at /usr/include/boost/pool/pool.hpp:432
#1  malloc () at /usr/include/boost/pool/singleton_pool.hpp:137
#2  KisTileData::allocateData (pixelSize=<optimized out>) at /home/boud/dev/krita/libs/image/tiles3/kis_tile_data.cc:127
#3  0x00007ffff68278d5 in KisTileData::KisTileData (this=0x541d540, rhs=..., checkFreeMemory=<optimized out>)
    at /home/boud/dev/krita/libs/image/tiles3/kis_tile_data.cc:77
#4  0x00007ffff6829f11 in KisTileDataStore::duplicateTileData (
    this=0x7ffff6ca86e0 <_ZZN12_GLOBAL__N_116Q_QGS_s_instance13innerFunctionEvE6holder>, rhs=0x6806b60)
    at /home/boud/dev/krita/libs/image/tiles3/kis_tile_data_store.cc:165
#5  0x00007ffff68265ef in clone (this=<optimized out>) at /home/boud/dev/krita/libs/image/tiles3/kis_tile_data.h:88
#6  KisTile::lockForWrite (this=0x686ae80) at /home/boud/dev/krita/libs/image/tiles3/kis_tile.cc:187
#7  0x00007ffff683e944 in lockTile (this=<optimized out>, tile=...)
    at /home/boud/dev/krita/libs/image/tiles3/kis_base_iterator.h:40
#8  KisHLineIterator2::fetchTileDataForCache (this=this@entry=0x68c0620, kti=..., col=col@entry=1, row=row@entry=1)
    at /home/boud/dev/krita/libs/image/tiles3/kis_hline_iterator.cpp:207
#9  0x00007ffff683ef58 in KisHLineIterator2::KisHLineIterator2 (this=0x68c0620, dataManager=<optimized out>, 
    x=<optimized out>, y=64, w=<optimized out>, offsetX=<optimized out>, offsetY=0, writable=true, 
    __in_chrg=<optimized out>, __vtt_parm=<optimized out>)
    at /home/boud/dev/krita/libs/image/tiles3/kis_hline_iterator.cpp:63
#10 0x00007ffff692ff52 in KisPaintDevice::Private::KisPaintDeviceStrategy::createHLineIteratorNG (this=<optimized out>, 
    dataManager=0x5cd96c0, x=0, y=64, w=1920, offsetX=0, offsetY=0)
    at /home/boud/dev/krita/libs/image/kis_paint_device_strategies.h:93
#11 0x00007ffff692b896 in KisPaintDevice::createHLineIteratorNG (this=<optimized out>, x=x@entry=0, y=y@entry=64, 
    w=w@entry=1920) at /home/boud/dev/krita/libs/image/kis_paint_device.cc:1448
#12 0x00007fffb7ebd9b5 in exrConverter::Private::decodeData4<float> (this=0x66b0840, file=..., info=..., layer=..., 
    width=width@entry=1920, xstart=xstart@entry=0, ystart=ystart@entry=0, height=height@entry=1080, 
    ptype=ptype@entry=Imf_2_1::FLOAT) at /home/boud/dev/krita/plugins/impex/exr/exr_converter.cc:397
#13 0x00007fffb7eb1436 in exrConverter::decode (this=this@entry=0x7fffffffc9a0, filename=...)
    at /home/boud/dev/krita/plugins/impex/exr/exr_converter.cc:831
#14 0x00007fffb7eb1fb5 in exrConverter::buildImage (this=this@entry=0x7fffffffc9a0, filename=...)
    at /home/boud/dev/krita/plugins/impex/exr/exr_converter.cc:869
#15 0x00007fffb7eab23f in exrImport::convert (this=0x66ae5b0, to=...)
    at /home/boud/dev/krita/plugins/impex/exr/exr_import.cc:68
#16 0x00007ffff790ae94 in CalligraFilter::ChainLink::invokeFilter (this=0x630ac60)
    at /home/boud/dev/krita/libs/ui/KisFilterChainLink.cpp:87
#17 0x00007ffff790a1a8 in KisFilterChain::invokeChain (this=this@entry=0x66b8f70)
    at /home/boud/dev/krita/libs/ui/KisFilterChain.cpp:92
#18 0x00007ffff79111ba in KisImportExportManager::importDocument (this=0x654ce80, location=..., documentMimeType=..., 
    status=@0x7fffffffcd40: 100372496) at /home/boud/dev/krita/libs/ui/KisImportExportManager.cpp:156
#19 0x00007ffff78fc0f3 in KisDocument::openFile (this=0x5fb9010) at /home/boud/dev/krita/libs/ui/KisDocument.cpp:1217
#20 0x00007ffff78fc6dd in openFile (this=0x5facc30) at /home/boud/dev/krita/libs/ui/KisDocument.cpp:372
#21 openLocalFile (this=0x5facc30) at /home/boud/dev/krita/libs/ui/KisDocument.cpp:389
#22 KisDocument::openUrlInternal (this=this@entry=0x5fb9010, url=...) at /home/boud/dev/krita/libs/ui/KisDocument.cpp:2218
#23 0x00007ffff78fcba0 in KisDocument::openUrl (this=this@entry=0x5fb9010, _url=..., 
    flags=flags@entry=KisDocument::OPEN_URL_FLAG_NONE) at /home/boud/dev/krita/libs/ui/KisDocument.cpp:1149
#24 0x00007ffff7915b90 in KisMainWindow::openDocumentInternal (this=this@entry=0x5ab3050, url=..., 
    newdoc=newdoc@entry=0x5fb9010) at /home/boud/dev/krita/libs/ui/KisMainWindow.cpp:797
#25 0x00007ffff78ec520 in KisApplication::start (this=this@entry=0x7fffffffd5a0, args=...)
    at /home/boud/dev/krita/libs/ui/KisApplication.cpp:451
#26 0x0000000000404c7f in main (argc=2, argv=<optimized out>) at /home/boud/dev/krita/krita/main.cc:220
(gdb)
Comment 3 Manuel Albert 2016-05-18 11:19:40 UTC
(In reply to Boudewijn Rempt from comment #1)
> Hi Manuel,
> 
> Thanks for your report. I can confirm the crash with your samplefile, it's
> really useful to have access to that!. How were the files created?
> 
> Notes:
> 
> * The actual OS doesn't matter. 
> * It's not a regression from Krita 2.9: that crashes as well on these files.

The files were created in blender (the version number should be 2.76 but we work with latest version most of the time and none of them produced something useful).
Comment 4 Halla Rempt 2016-05-18 11:39:49 UTC
Thanks -- this is what exrheader sees,

boud@thinkstation:~/src/openexr_viewers-2.2.0> exrheader ~/samplefile.exr 

/home/boud/samplefile.exr:

file format version: 2, flags 0x0
BlenderMultiChannel (type string): "Blender V2.55.1 and newer"
Camera (type string): "Cam"
Date (type string): "2015/10/21 19:20:42"
File (type string): "\\user-pc\Render_JOBS\TIGUAN\Test_File\SCN_TS_SHOT_TS_01_A.blend"
Frame (type string): "18"
RenderTime (type string): "06:54.53"
Scene (type string): "Scene"
Time (type string): "00:00:00:18"
channels (type chlist):
    BACKGROUND.AO.B, 16-bit floating-point, sampling 1 1
    BACKGROUND.AO.G, 16-bit floating-point, sampling 1 1
    BACKGROUND.AO.R, 16-bit floating-point, sampling 1 1
    BACKGROUND.Combined.A, 16-bit floating-point, sampling 1 1
    BACKGROUND.Combined.B, 16-bit floating-point, sampling 1 1
    BACKGROUND.Combined.G, 16-bit floating-point, sampling 1 1
    BACKGROUND.Combined.R, 16-bit floating-point, sampling 1 1
    BACKGROUND.Depth.Z, 32-bit floating-point, sampling 1 1
    BACKGROUND.GlossDir.B, 16-bit floating-point, sampling 1 1
    BACKGROUND.GlossDir.G, 16-bit floating-point, sampling 1 1
    BACKGROUND.GlossDir.R, 16-bit floating-point, sampling 1 1
    BACKGROUND.Shadow.B, 16-bit floating-point, sampling 1 1
    BACKGROUND.Shadow.G, 16-bit floating-point, sampling 1 1
    BACKGROUND.Shadow.R, 16-bit floating-point, sampling 1 1
    BACKGROUND.Vector.W, 16-bit floating-point, sampling 1 1
    BACKGROUND.Vector.X, 16-bit floating-point, sampling 1 1
    BACKGROUND.Vector.Y, 16-bit floating-point, sampling 1 1
    BACKGROUND.Vector.Z, 16-bit floating-point, sampling 1 1
    CAR.AO.B, 16-bit floating-point, sampling 1 1
    CAR.AO.G, 16-bit floating-point, sampling 1 1
    CAR.AO.R, 16-bit floating-point, sampling 1 1
    CAR.Combined.A, 16-bit floating-point, sampling 1 1
    CAR.Combined.B, 16-bit floating-point, sampling 1 1
    CAR.Combined.G, 16-bit floating-point, sampling 1 1
    CAR.Combined.R, 16-bit floating-point, sampling 1 1
    CAR.Depth.Z, 32-bit floating-point, sampling 1 1
    CAR.DiffCol.B, 16-bit floating-point, sampling 1 1
    CAR.DiffCol.G, 16-bit floating-point, sampling 1 1
    CAR.DiffCol.R, 16-bit floating-point, sampling 1 1
    CAR.DiffDir.B, 16-bit floating-point, sampling 1 1
    CAR.DiffDir.G, 16-bit floating-point, sampling 1 1
    CAR.DiffDir.R, 16-bit floating-point, sampling 1 1
    CAR.DiffInd.B, 16-bit floating-point, sampling 1 1
    CAR.DiffInd.G, 16-bit floating-point, sampling 1 1
    CAR.DiffInd.R, 16-bit floating-point, sampling 1 1
    CAR.Emit.B, 16-bit floating-point, sampling 1 1
    CAR.Emit.G, 16-bit floating-point, sampling 1 1
    CAR.Emit.R, 16-bit floating-point, sampling 1 1
    CAR.GlossDir.B, 16-bit floating-point, sampling 1 1
    CAR.GlossDir.G, 16-bit floating-point, sampling 1 1
    CAR.GlossDir.R, 16-bit floating-point, sampling 1 1
    CAR.IndexMA.X, 16-bit floating-point, sampling 1 1
    CAR.Mist.Z, 16-bit floating-point, sampling 1 1
    CAR.TransCol.B, 16-bit floating-point, sampling 1 1
    CAR.TransCol.G, 16-bit floating-point, sampling 1 1
    CAR.TransCol.R, 16-bit floating-point, sampling 1 1
    CAR.TransDir.B, 16-bit floating-point, sampling 1 1
    CAR.TransDir.G, 16-bit floating-point, sampling 1 1
    CAR.TransDir.R, 16-bit floating-point, sampling 1 1
    CAR.TransInd.B, 16-bit floating-point, sampling 1 1
    CAR.TransInd.G, 16-bit floating-point, sampling 1 1
    CAR.TransInd.R, 16-bit floating-point, sampling 1 1
    CAR.Vector.W, 16-bit floating-point, sampling 1 1
    CAR.Vector.X, 16-bit floating-point, sampling 1 1
    CAR.Vector.Y, 16-bit floating-point, sampling 1 1
    CAR.Vector.Z, 16-bit floating-point, sampling 1 1
    Composite.Combined.A, 16-bit floating-point, sampling 1 1
    Composite.Combined.B, 16-bit floating-point, sampling 1 1
    Composite.Combined.G, 16-bit floating-point, sampling 1 1
    Composite.Combined.R, 16-bit floating-point, sampling 1 1
    GLASSES.AO.B, 16-bit floating-point, sampling 1 1
    GLASSES.AO.G, 16-bit floating-point, sampling 1 1
    GLASSES.AO.R, 16-bit floating-point, sampling 1 1
    GLASSES.Combined.A, 16-bit floating-point, sampling 1 1
    GLASSES.Combined.B, 16-bit floating-point, sampling 1 1
    GLASSES.Combined.G, 16-bit floating-point, sampling 1 1
    GLASSES.Combined.R, 16-bit floating-point, sampling 1 1
    GLASSES.Depth.Z, 32-bit floating-point, sampling 1 1
    GLASSES.IndexMA.X, 16-bit floating-point, sampling 1 1
    GLASSES.Mist.Z, 16-bit floating-point, sampling 1 1
    GLASSES.TransCol.B, 16-bit floating-point, sampling 1 1
    GLASSES.TransCol.G, 16-bit floating-point, sampling 1 1
    GLASSES.TransCol.R, 16-bit floating-point, sampling 1 1
    GLASSES.TransDir.B, 16-bit floating-point, sampling 1 1
    GLASSES.TransDir.G, 16-bit floating-point, sampling 1 1
    GLASSES.TransDir.R, 16-bit floating-point, sampling 1 1
    GLASSES.TransInd.B, 16-bit floating-point, sampling 1 1
    GLASSES.TransInd.G, 16-bit floating-point, sampling 1 1
    GLASSES.TransInd.R, 16-bit floating-point, sampling 1 1
    GLASSES.Vector.W, 16-bit floating-point, sampling 1 1
    GLASSES.Vector.X, 16-bit floating-point, sampling 1 1
    GLASSES.Vector.Y, 16-bit floating-point, sampling 1 1
    GLASSES.Vector.Z, 16-bit floating-point, sampling 1 1
compression (type compression): zip, multi-scanline blocks
dataWindow (type box2i): (0 0) - (1919 1079)
displayWindow (type box2i): (0 0) - (1919 1079)
lineOrder (type lineOrder): increasing y
pixelAspectRatio (type float): 1
screenWindowCenter (type v2f): (0 0)
screenWindowWidth (type float): 1
type (type string): "scanlineimage"
Comment 5 Halla Rempt 2016-05-18 11:41:08 UTC
Attribute:  BlenderMultiChannel  type:  string
Attribute:  Camera  type:  string
Attribute:  Date  type:  string
Attribute:  File  type:  string
Attribute:  Frame  type:  string
Attribute:  RenderTime  type:  string
Attribute:  Scene  type:  string
Attribute:  Time  type:  string
Attribute:  channels  type:  chlist
Attribute:  compression  type:  compression
Attribute:  dataWindow  type:  box2i
Attribute:  displayWindow  type:  box2i
Attribute:  lineOrder  type:  lineOrder
Attribute:  pixelAspectRatio  type:  float
Attribute:  screenWindowCenter  type:  v2f
Attribute:  screenWindowWidth  type:  float
Checking for ARGB channels, they can occur in single-layer _or_ multi-layer images:
Channel name =  BACKGROUND.AO.B  type =  1
Channel name =  BACKGROUND.AO.G  type =  1
Channel name =  BACKGROUND.AO.R  type =  1
Channel name =  BACKGROUND.Combined.A  type =  1
Channel name =  BACKGROUND.Combined.B  type =  1
Channel name =  BACKGROUND.Combined.G  type =  1
Channel name =  BACKGROUND.Combined.R  type =  1
Channel name =  BACKGROUND.Depth.Z  type =  2
Channel name =  BACKGROUND.GlossDir.B  type =  1
Channel name =  BACKGROUND.GlossDir.G  type =  1
Channel name =  BACKGROUND.GlossDir.R  type =  1
Channel name =  BACKGROUND.Shadow.B  type =  1
Channel name =  BACKGROUND.Shadow.G  type =  1
Channel name =  BACKGROUND.Shadow.R  type =  1
Channel name =  BACKGROUND.Vector.W  type =  1
Channel name =  BACKGROUND.Vector.X  type =  1
Channel name =  BACKGROUND.Vector.Y  type =  1
Channel name =  BACKGROUND.Vector.Z  type =  1
Channel name =  CAR.AO.B  type =  1
Channel name =  CAR.AO.G  type =  1
Channel name =  CAR.AO.R  type =  1
Channel name =  CAR.Combined.A  type =  1
Channel name =  CAR.Combined.B  type =  1
Channel name =  CAR.Combined.G  type =  1
Channel name =  CAR.Combined.R  type =  1
Channel name =  CAR.Depth.Z  type =  2
Channel name =  CAR.DiffCol.B  type =  1
Channel name =  CAR.DiffCol.G  type =  1
Channel name =  CAR.DiffCol.R  type =  1
Channel name =  CAR.DiffDir.B  type =  1
Channel name =  CAR.DiffDir.G  type =  1
Channel name =  CAR.DiffDir.R  type =  1
Channel name =  CAR.DiffInd.B  type =  1
Channel name =  CAR.DiffInd.G  type =  1
Channel name =  CAR.DiffInd.R  type =  1
Channel name =  CAR.Emit.B  type =  1
Channel name =  CAR.Emit.G  type =  1
Channel name =  CAR.Emit.R  type =  1
Channel name =  CAR.GlossDir.B  type =  1
Channel name =  CAR.GlossDir.G  type =  1
Channel name =  CAR.GlossDir.R  type =  1
Channel name =  CAR.IndexMA.X  type =  1
Channel name =  CAR.Mist.Z  type =  1
Channel name =  CAR.TransCol.B  type =  1
Channel name =  CAR.TransCol.G  type =  1
Channel name =  CAR.TransCol.R  type =  1
Channel name =  CAR.TransDir.B  type =  1
Channel name =  CAR.TransDir.G  type =  1
Channel name =  CAR.TransDir.R  type =  1
Channel name =  CAR.TransInd.B  type =  1
Channel name =  CAR.TransInd.G  type =  1
Channel name =  CAR.TransInd.R  type =  1
Channel name =  CAR.Vector.W  type =  1
Channel name =  CAR.Vector.X  type =  1
Channel name =  CAR.Vector.Y  type =  1
Channel name =  CAR.Vector.Z  type =  1
Channel name =  Composite.Combined.A  type =  1
Channel name =  Composite.Combined.B  type =  1
Channel name =  Composite.Combined.G  type =  1
Channel name =  Composite.Combined.R  type =  1
Channel name =  GLASSES.AO.B  type =  1
Channel name =  GLASSES.AO.G  type =  1
Channel name =  GLASSES.AO.R  type =  1
Channel name =  GLASSES.Combined.A  type =  1
Channel name =  GLASSES.Combined.B  type =  1
Channel name =  GLASSES.Combined.G  type =  1
Channel name =  GLASSES.Combined.R  type =  1
Channel name =  GLASSES.Depth.Z  type =  2
Channel name =  GLASSES.IndexMA.X  type =  1
Channel name =  GLASSES.Mist.Z  type =  1
Channel name =  GLASSES.TransCol.B  type =  1
Channel name =  GLASSES.TransCol.G  type =  1
Channel name =  GLASSES.TransCol.R  type =  1
Channel name =  GLASSES.TransDir.B  type =  1
Channel name =  GLASSES.TransDir.G  type =  1
Channel name =  GLASSES.TransDir.R  type =  1
Channel name =  GLASSES.TransInd.B  type =  1
Channel name =  GLASSES.TransInd.G  type =  1
Channel name =  GLASSES.TransInd.R  type =  1
Channel name =  GLASSES.Vector.W  type =  1
Channel name =  GLASSES.Vector.X  type =  1
Channel name =  GLASSES.Vector.Y  type =  1
Channel name =  GLASSES.Vector.Z  type =  1
Extra layers: 30
layer name =  BACKGROUND.AO
        channel  BACKGROUND.AO.B  type =  1
        channel  BACKGROUND.AO.G  type =  1
        channel  BACKGROUND.AO.R  type =  1
layer name =  BACKGROUND.Combined
        channel  BACKGROUND.Combined.A  type =  1
        channel  BACKGROUND.Combined.B  type =  1
        channel  BACKGROUND.Combined.G  type =  1
        channel  BACKGROUND.Combined.R  type =  1
layer name =  BACKGROUND.Depth
        channel  BACKGROUND.Depth.Z  type =  2
layer name =  BACKGROUND.GlossDir
        channel  BACKGROUND.GlossDir.B  type =  1
        channel  BACKGROUND.GlossDir.G  type =  1
        channel  BACKGROUND.GlossDir.R  type =  1
layer name =  BACKGROUND.Shadow
        channel  BACKGROUND.Shadow.B  type =  1
        channel  BACKGROUND.Shadow.G  type =  1
        channel  BACKGROUND.Shadow.R  type =  1
layer name =  BACKGROUND.Vector
        channel  BACKGROUND.Vector.W  type =  1
        channel  BACKGROUND.Vector.X  type =  1
        channel  BACKGROUND.Vector.Y  type =  1
        channel  BACKGROUND.Vector.Z  type =  1
layer name =  CAR.AO
        channel  CAR.AO.B  type =  1
        channel  CAR.AO.G  type =  1
        channel  CAR.AO.R  type =  1
layer name =  CAR.Combined
        channel  CAR.Combined.A  type =  1
        channel  CAR.Combined.B  type =  1
        channel  CAR.Combined.G  type =  1
        channel  CAR.Combined.R  type =  1
layer name =  CAR.Depth
        channel  CAR.Depth.Z  type =  2
layer name =  CAR.DiffCol
        channel  CAR.DiffCol.B  type =  1
        channel  CAR.DiffCol.G  type =  1
        channel  CAR.DiffCol.R  type =  1
layer name =  CAR.DiffDir
        channel  CAR.DiffDir.B  type =  1
        channel  CAR.DiffDir.G  type =  1
        channel  CAR.DiffDir.R  type =  1
layer name =  CAR.DiffInd
        channel  CAR.DiffInd.B  type =  1
        channel  CAR.DiffInd.G  type =  1
        channel  CAR.DiffInd.R  type =  1
layer name =  CAR.Emit
        channel  CAR.Emit.B  type =  1
        channel  CAR.Emit.G  type =  1
        channel  CAR.Emit.R  type =  1
layer name =  CAR.GlossDir
        channel  CAR.GlossDir.B  type =  1
        channel  CAR.GlossDir.G  type =  1
        channel  CAR.GlossDir.R  type =  1
layer name =  CAR.IndexMA
        channel  CAR.IndexMA.X  type =  1
layer name =  CAR.Mist
        channel  CAR.Mist.Z  type =  1
layer name =  CAR.TransCol
        channel  CAR.TransCol.B  type =  1
        channel  CAR.TransCol.G  type =  1
        channel  CAR.TransCol.R  type =  1
layer name =  CAR.TransDir
        channel  CAR.TransDir.B  type =  1
        channel  CAR.TransDir.G  type =  1
        channel  CAR.TransDir.R  type =  1
layer name =  CAR.TransInd
        channel  CAR.TransInd.B  type =  1
        channel  CAR.TransInd.G  type =  1
        channel  CAR.TransInd.R  type =  1
layer name =  CAR.Vector
        channel  CAR.Vector.W  type =  1
        channel  CAR.Vector.X  type =  1
        channel  CAR.Vector.Y  type =  1
        channel  CAR.Vector.Z  type =  1
layer name =  Composite.Combined
        channel  Composite.Combined.A  type =  1
        channel  Composite.Combined.B  type =  1
        channel  Composite.Combined.G  type =  1
        channel  Composite.Combined.R  type =  1
layer name =  GLASSES.AO
        channel  GLASSES.AO.B  type =  1
        channel  GLASSES.AO.G  type =  1
        channel  GLASSES.AO.R  type =  1
layer name =  GLASSES.Combined
        channel  GLASSES.Combined.A  type =  1
        channel  GLASSES.Combined.B  type =  1
        channel  GLASSES.Combined.G  type =  1
        channel  GLASSES.Combined.R  type =  1
layer name =  GLASSES.Depth
        channel  GLASSES.Depth.Z  type =  2
layer name =  GLASSES.IndexMA
        channel  GLASSES.IndexMA.X  type =  1
layer name =  GLASSES.Mist
        channel  GLASSES.Mist.Z  type =  1
layer name =  GLASSES.TransCol
        channel  GLASSES.TransCol.B  type =  1
        channel  GLASSES.TransCol.G  type =  1
        channel  GLASSES.TransCol.R  type =  1
layer name =  GLASSES.TransDir
        channel  GLASSES.TransDir.B  type =  1
        channel  GLASSES.TransDir.G  type =  1
        channel  GLASSES.TransDir.R  type =  1
layer name =  GLASSES.TransInd
        channel  GLASSES.TransInd.B  type =  1
        channel  GLASSES.TransInd.G  type =  1
        channel  GLASSES.TransInd.R  type =  1
layer name =  GLASSES.Vector
        channel  GLASSES.Vector.W  type =  1
        channel  GLASSES.Vector.X  type =  1
        channel  GLASSES.Vector.Y  type =  1
        channel  GLASSES.Vector.Z  type =  1
File has 30 layer(s)
Image type =  2
Colorspace:  "RGBA (32-bit floating/channel)"
Decoding  "Vector"  with  4  channels, and color space  "XYZAF16"
krita.core: Missing name attribute for tag  "date"
Decoding  "TransInd"  with  3  channels, and color space  "RGBAF16"
Segmentation fault
Comment 6 schwarzeralptraum 2016-05-27 16:15:20 UTC
Created attachment 99217 [details]
exr_converter.cc patch

I found out that layers can have their own colorspaces. The converter appears to use the colorspace for the entire document rather than the colorspace for the layer, so they are not loaded properly and we get those errors. I put the check for the colorspace in the layer instead of the document in this patch, but there are other issues. It gets to loading a "Vector" layer (possibly GLASSES) and stalls completely. I think it has something to do with the while loop in the unmultiplyAlpha call because it gets stuck while processing a pixel, returns no error messages and doesn't crash.
Comment 7 wolthera 2016-05-27 21:58:50 UTC
beelzy, please use phabricator for review requests, we lose them here :) (You just use your forum account in the ldap area and then submit the patch via differential)
Comment 8 Halla Rempt 2016-05-28 14:15:09 UTC
Git commit e252eb3a0230785a3de5ab733f9e7ad238e010e7 by Boudewijn Rempt.
Committed on 28/05/2016 at 14:14.
Pushed by rempt into branch 'master'.

Use the layer's not the image's type when reading pixel data

Patch by Beelzy

M  +2    -2    plugins/impex/exr/exr_converter.cc

http://commits.kde.org/krita/e252eb3a0230785a3de5ab733f9e7ad238e010e7
Comment 9 Halla Rempt 2016-05-30 09:55:33 UTC
Git commit 5f02b6cf33b5bb87889d40e2bad4115f4575e357 by Boudewijn Rempt.
Committed on 30/05/2016 at 09:53.
Pushed by rempt into branch 'krita/3.0'.

Make sure the alpha value is positive when unmultiplying

Otherwise the loop will never end. The image in the
referenced bug now loads.

M  +1    -1    plugins/impex/exr/exr_converter.cc

http://commits.kde.org/krita/5f02b6cf33b5bb87889d40e2bad4115f4575e357
Comment 10 Manuel Albert 2016-05-30 10:10:55 UTC
Thank you for the fixes. If you need other files to test, I can supply you other samples.
Comment 11 Halla Rempt 2016-05-30 10:20:09 UTC
I'm still not sure Krita really loads the files correctly, though :-)
Comment 12 Manuel Albert 2016-05-30 15:27:23 UTC
I prepared a few samples today and uploaded them to my webspace: http://download.creamsurfer.de/krita_bugreport/samples_openEXR.7z
http://download.creamsurfer.de/krita_bugreport/16bitfloat_zip_singlelayer_CC_Multipass.exr (this was created using different colormanagement options and contains only one Renderlayer but multiple passes)

I don't know if they're helpful, yet I tried to put together a few different cases (e.g. like 16bit float and 32bit float options).

If I can help out in any way, please tell me what you need. 

Thank you. You guys rock!
Comment 13 Antti Savolainen 2018-06-27 19:24:02 UTC
This has been fixed.