MCPcopy Create free account
hub / github.com/LAStools/LAStools / chunk_sizes

Method chunk_sizes

LASzip/src/laswriteitemcompressed_v3.cpp:761–887  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

759}
760
761inline BOOL LASwriteItemCompressed_POINT14_v3::chunk_sizes()
762{
763 U32 num_bytes = 0;
764 ByteStreamOut* outstream = enc->getByteStreamOut();
765
766 // finish the encoders
767
768 enc_channel_returns_XY->done();
769 enc_Z->done();
770 if (changed_classification)
771 {
772 enc_classification->done();
773 }
774 if (changed_flags)
775 {
776 enc_flags->done();
777 }
778 if (changed_intensity)
779 {
780 enc_intensity->done();
781 }
782 if (changed_scan_angle)
783 {
784 enc_scan_angle->done();
785 }
786 if (changed_user_data)
787 {
788 enc_user_data->done();
789 }
790 if (changed_point_source)
791 {
792 enc_point_source->done();
793 }
794 if (changed_gps_time)
795 {
796 enc_gps_time->done();
797 }
798
799 // output the sizes of all layer (i.e.. number of bytes per layer)
800
801 num_bytes = (U32)outstream_channel_returns_XY->getCurr();
802 num_bytes_channel_returns_XY += num_bytes;
803 outstream->put32bitsLE(((U8*)&num_bytes));
804
805 num_bytes = (U32)outstream_Z->getCurr();
806 num_bytes_Z += num_bytes;
807 outstream->put32bitsLE(((U8*)&num_bytes));
808
809 if (changed_classification)
810 {
811 num_bytes = (U32)outstream_classification->getCurr();
812 num_bytes_classification += num_bytes;
813 }
814 else
815 {
816 num_bytes = 0;
817 }
818 outstream->put32bitsLE(((U8*)&num_bytes));

Callers

nothing calls this directly

Calls 4

getByteStreamOutMethod · 0.80
getCurrMethod · 0.80
doneMethod · 0.45
put32bitsLEMethod · 0.45

Tested by

no test coverage detected