// Marth Lab, Department of Biology, Boston College\r
// All rights reserved.\r
// ---------------------------------------------------------------------------\r
-// Last modified: 24 June 2009 (DB)\r
+// Last modified: 1 October 2009 (DB)\r
// ---------------------------------------------------------------------------\r
// The BGZF routines were adapted from the bgzf.c code developed at the Broad\r
// Institute.\r
std::string AlignedBases; //!< 'Aligned' sequence (includes any indels, padding, clipping) \r
std::string Qualities; //!< FASTQ qualities (ASCII characters, not numeric values)\r
std::string TagData; //!< Tag data (accessor methods will pull the requested information out)\r
- unsigned int RefID; //!< ID number for reference sequence\r
- unsigned int Position; //!< Position (0-based) where alignment starts \r
+ //unsigned int RefID; //!< ID number for reference sequence\r
+ //unsigned int Position; //!< Position (0-based) where alignment starts \r
+ signed int RefID; //!< ID number for reference sequence (-1)\r
+ signed int Position; //!< Position (0-based) where alignment starts (-1) \r
unsigned int Bin; //!< Bin in BAM file where this alignment resides\r
unsigned int MapQuality; //!< Mapping quality score \r
unsigned int AlignmentFlag; //!< Alignment bit-flag - see Is<something>() methods for available queries\r
std::vector<CigarOp> CigarData; //!< CIGAR operations for this alignment\r
- unsigned int MateRefID; //!< ID number for reference sequence where alignment's mate was aligned\r
- unsigned int MatePosition; //!< Position (0-based) where alignment's mate starts\r
+ //unsigned int MateRefID; //!< ID number for reference sequence where alignment's mate was aligned\r
+ //unsigned int MatePosition; //!< Position (0-based) where alignment's mate starts\r
//unsigned int InsertSize; //!< Mate-pair insert size\r
- signed int InsertSize; //!< Mate-pair insert size\r
+ signed int MateRefID; //!< ID number for reference sequence where alignment's mate was aligned (-1)\r
+ signed int MatePosition; //!< Position (0-based) where alignment's mate starts (-1)\r
+ signed int InsertSize; //!< Mate-pair insert size(0)\r
\r
// Alignment flag query constants\r
private:\r
unsigned int numCigarOperations;
unsigned int querySequenceLength;
- bAlignment.RefID = BgzfUnpackUnsignedInt(&x[0]);
- bAlignment.Position = BgzfUnpackUnsignedInt(&x[4]);
+ //bAlignment.RefID = BgzfUnpackUnsignedInt(&x[0]);
+ //bAlignment.Position = BgzfUnpackUnsignedInt(&x[4]);
+ bAlignment.RefID = BgzfUnpackSignedInt(&x[0]);
+ bAlignment.Position = BgzfUnpackSignedInt(&x[4]);
tempValue = BgzfUnpackUnsignedInt(&x[8]);
bAlignment.Bin = tempValue >> 16;
numCigarOperations = tempValue & 0xffff;
querySequenceLength = BgzfUnpackUnsignedInt(&x[16]);
- bAlignment.MateRefID = BgzfUnpackUnsignedInt(&x[20]);
- bAlignment.MatePosition = BgzfUnpackUnsignedInt(&x[24]);
+ //bAlignment.MateRefID = BgzfUnpackUnsignedInt(&x[20]);
+ //bAlignment.MatePosition = BgzfUnpackUnsignedInt(&x[24]);
//bAlignment.InsertSize = BgzfUnpackUnsignedInt(&x[28]);
+ bAlignment.MateRefID = BgzfUnpackSignedInt(&x[20]);
+ bAlignment.MatePosition = BgzfUnpackSignedInt(&x[24]);
bAlignment.InsertSize = BgzfUnpackSignedInt(&x[28]);
// calculate lengths/offsets