MCPcopy Create free account
hub / github.com/LASzip/LASzip / init

Method init

src/laswriteitemcompressed_v2.cpp:104–137  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

102}
103
104BOOL LASwriteItemCompressed_POINT10_v2::init(const U8* item, U32& context)
105{
106 U32 i;
107
108 /* init state */
109 for (i=0; i < 16; i++)
110 {
111 last_x_diff_median5[i].init();
112 last_y_diff_median5[i].init();
113 last_intensity[i] = 0;
114 last_height[i/2] = 0;
115 }
116
117 /* init models and integer compressors */
118 enc->initSymbolModel(m_changed_values);
119 ic_intensity->initCompressor();
120 enc->initSymbolModel(m_scan_angle_rank[0]);
121 enc->initSymbolModel(m_scan_angle_rank[1]);
122 ic_point_source_ID->initCompressor();
123 for (i = 0; i < 256; i++)
124 {
125 if (m_bit_byte[i]) enc->initSymbolModel(m_bit_byte[i]);
126 if (m_classification[i]) enc->initSymbolModel(m_classification[i]);
127 if (m_user_data[i]) enc->initSymbolModel(m_user_data[i]);
128 }
129 ic_dx->initCompressor();
130 ic_dy->initCompressor();
131 ic_z->initCompressor();
132
133 /* init last item */
134 memcpy(last_item, item, 20);
135
136 return TRUE;
137}
138
139inline BOOL LASwriteItemCompressed_POINT10_v2::write(const U8* item, U32& context)
140{

Callers

nothing calls this directly

Calls 2

initCompressorMethod · 0.80
initSymbolModelMethod · 0.45

Tested by

no test coverage detected