I'm having trouble putting chunks into an array.
I've created an array using:
scidb::ArrayID aid = catalog.addArray(*dptr, scidb::psLocalNode); // dptr is a pointer to a scidb::ArrayDesc
It is a one-attribute array.
boost::shared_ptr<scidb::ArrayIterator> ai = array.getIterator(0);
scidb::Chunk& outChunk = ai->newChunk(c); // c is an instance of scidb::Coordinates --> [0,0,0]
outChunk.setSparse(false); // Never sparse
i.readInto(outChunk.getData()); // Write i.byteSize() bytes into outChunk.getData()
Is this a reasonable approach? I ask since I keep getting a segfault during the write, so I wanted to double-check. I haven't ruled out my own faulty code that is supposed to fill the chunk.
The array I am writing to has dimensions and attributes as follows:
Does anything seem obviously wrong?
Thanks for your help,