Changeset 526:feff4c1f2cb2
- Timestamp:
- 04/23/08 15:45:14 (2 years ago)
- Branch:
- default
- Convert:
- svn:1766ff46-f334-0410-ab20-d63176f87757/trunk@591
- File:
-
- 1 edited
-
src/lasheader.cpp (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
src/lasheader.cpp
r522 r526 57 57 p = std::memcpy(m_signature, other.m_signature, eFileSignatureSize); 58 58 assert(p == m_signature); 59 // m_signature = other.m_signature;60 59 p = std::memcpy(m_projectId4, other.m_projectId4, eProjectId4Size); 61 60 assert(p == m_projectId4); 62 61 p = std::memcpy(m_systemId, other.m_systemId, eSystemIdSize); 63 62 assert(p == m_systemId); 64 // m_systemId = other.m_systemId;65 63 p = std::memcpy(m_softwareId, other.m_softwareId, eSoftwareIdSize); 66 64 assert(p == m_softwareId); 67 // m_softwareId = other.m_softwareId;68 65 std::vector<uint32_t>(other.m_pointRecordsByReturn).swap(m_pointRecordsByReturn); 69 66 assert(ePointsByReturnSize >= m_pointRecordsByReturn.size()); … … 78 75 p = std::memcpy(m_signature, rhs.m_signature, eFileSignatureSize); 79 76 assert(p == m_signature); 80 // m_signature = rhs.m_signature;81 77 m_sourceId = rhs.m_sourceId; 82 78 m_reserved = rhs.m_reserved; … … 90 86 p = std::memcpy(m_systemId, rhs.m_systemId, eSystemIdSize); 91 87 assert(p == m_systemId); 92 //m_systemId = rhs.m_systemId;93 88 p = std::memcpy(m_softwareId, rhs.m_softwareId, eSoftwareIdSize); 94 89 assert(p == m_softwareId); 95 //m_softwareId = rhs.m_softwareId;96 90 m_createDOY = rhs.m_createDOY; 97 91 m_createYear = rhs.m_createYear; … … 147 141 std::string LASHeader::GetFileSignature() const 148 142 { 149 return m_signature;143 return std::string(m_signature, eFileSignatureSize); 150 144 } 151 145 … … 215 209 std::string LASHeader::GetSystemId(bool pad /*= false*/) const 216 210 { 217 std::string tmp(m_systemId); 211 // copy array of chars and trim zeros if smaller than 32 bytes 212 std::string tmp(std::string(m_systemId, eSystemIdSize).c_str()); 218 213 219 214 // pad right side with spaces … … 239 234 } 240 235 241 std::string LASHeader::GetSoftwareId(bool pad /*= false*/) const242 { 243 std::string tmp( m_softwareId);236 std::string LASHeader::GetSoftwareId(bool pad /*= false*/) const 237 { 238 std::string tmp(std::string(m_softwareId, eSoftwareIdSize).c_str()); 244 239 245 240 // pad right side with spaces
Note: See TracChangeset
for help on using the changeset viewer.
