<div dir="ltr"><div><div><div><div><div>I have the following very simple code using libLAS-1.7.0:<br><pre><span class="">#include <liblas/liblas.hpp></span>
<span class="">#include <fstream>  </span><span class="">// std::ifstream</span>
<span class="">#include <iostream> </span><span class="">// std::cout</span></pre>int main(){<br>  std::ofstream ofs;<br>  ofs.open("file.las", std::ios::out | std::ios::binary);<br><br>  liblas::Header header;<br>
  header.SetCompressed(true);<br>  header.SetDataFormatId(liblas::ePointFormat1);<br><br>  liblas::Writer writer(ofs, header);<br><br>  liblas::Point point;<br>  point.SetCoordinates(10, 20, 30);<br>  writer.WritePoint(point);<br>
}<br><br></div>It gives me the error:<br><br>libLAS-1.7.0/src/detail/writer/zipwriter.cpp:124: virtual void liblas::detail::ZipWriterImpl::WritePoint(const liblas::Point&): Assertion `data->size() == m_zipPoint->m_lz_point_size' failed.<br>
<br></div>Removing the line:<br><br>  header.SetDataFormatId(liblas::ePointFormat1);<br><br></div>makes it work. <br><br></div><div>Can this be fixed, or perhaps made it more clear what is going on? Thank you.<br><br>Oleg<br>
</div><div><br></div></div><br><div><div><div><div><div><br><br><br></div></div></div></div></div></div>