Actions
Bug #883
closedAce 2 does not properly write the MRC header file
Start date:
09/17/2010
Due date:
% Done:
100%
Estimated time:
Affected Version:
Pre-2.0
Show in known bugs:
No
Workaround:
Description
I ran into this when writing a 3D file using the same code and then reading it into PyMOL. PyMOL rejects the file as not being an MRC file because of the missing 'MAP ' string.
source:trunk/programs/ace2/MRC.m#L224
When ACE2 writes the MRC header it sets four-byte 53 to 0, when it should equal 'MAP '. Documentation here: http://emg.nysbc.org/software/mrctools/mrc_specification.php
Old code:
header->map = 0;
Suggested replacement:
// "MAP " from ascii to little-endian integer: // ord('M')=77, ord('A')=65, ord('P')=80, ord(' ')=32 // reverse order and powers of 256 // 32*(256**3) + 80*(256**2) + 65*(256) + 77 header->map = 542130509;
I have fixed and tested the code, but I do not want to commit until given approval, because of the code freeze.
Actions