@@ -191,7 +191,7 @@ namespace lsp
191191 vFloatBuf = ptr;
192192 nFloatHead = 0 ;
193193 nFloatSize = 0 ;
194- nFloatCap = float_cap;
194+ nFloatCap = uint32_t ( float_cap) ;
195195 nFloatBits = uint32_t (hdr.float_bits );
196196
197197 return STATUS_OK;
@@ -234,7 +234,7 @@ namespace lsp
234234 return (nread < 0 ) ? status_t (-nread) : STATUS_CORRUPTED;
235235
236236 // Convert subcommand + group to event code
237- cmd = ( group << 2 ) | cmd;
237+ cmd = uint32_t (( group << 2 ) | cmd) ;
238238 if (cmd >= sizeof (event_codes))
239239 return STATUS_CORRUPTED;
240240
@@ -283,7 +283,7 @@ namespace lsp
283283 return res;
284284
285285 // Compute floating-point value
286- int32_t dvalue = zigzag_decode (delta);
286+ int32_t dvalue = zigzag_decode (int32_t ( delta) );
287287 const int32_t image = vIntBuf[(base - index) % nFloatCap] + dvalue;
288288 value = bin_to_float (image);
289289 }
@@ -374,14 +374,14 @@ namespace lsp
374374 status_t res = read_varint_icount (&value);
375375 if (res != STATUS_OK)
376376 return res;
377- dst[0 ] = zigzag_decode (value);
377+ dst[0 ] = zigzag_decode (int32_t ( value) );
378378
379379 for (size_t i=1 ; i<count; ++i)
380380 {
381381 status_t res = read_varint_icount (&value);
382382 if (res != STATUS_OK)
383383 return res;
384- dst[i] = dst[0 ] + zigzag_decode (value);
384+ dst[i] = dst[0 ] + zigzag_decode (int32_t ( value) );
385385 }
386386
387387 return STATUS_OK;
@@ -425,7 +425,7 @@ namespace lsp
425425 if ((res == STATUS_OK) && (coords > 3 ))
426426 res = read_float (&w);
427427 if (res == STATUS_OK)
428- res = handler->add_vertex (x, y, z, w);
428+ res = status_t ( handler->add_vertex (x, y, z, w) );
429429
430430 return res;
431431 }
@@ -442,7 +442,7 @@ namespace lsp
442442 if ((res == STATUS_OK) && (coords > 3 ))
443443 res = read_float (&w);
444444 if (res == STATUS_OK)
445- res = handler->add_param_vertex (x, y, z, w);
445+ res = status_t ( handler->add_param_vertex (x, y, z, w) );
446446
447447 return res;
448448 }
@@ -459,7 +459,7 @@ namespace lsp
459459 if ((res == STATUS_OK) && (coords > 3 ))
460460 res = read_float (&nw);
461461 if (res == STATUS_OK)
462- res = handler->add_normal (nx, ny, nz, nw);
462+ res = status_t ( handler->add_normal (nx, ny, nz, nw) );
463463
464464 return res;
465465 }
@@ -474,7 +474,7 @@ namespace lsp
474474 if ((res == STATUS_OK) && (coords > 2 ))
475475 res = read_float (&w);
476476 if (res == STATUS_OK)
477- res = handler->add_texture_vertex (u, v, w);
477+ res = status_t ( handler->add_texture_vertex (u, v, w) );
478478 return res;
479479 }
480480
@@ -513,7 +513,7 @@ namespace lsp
513513 }
514514
515515
516- return handler->add_face (vv, vn, vt, count);
516+ return status_t ( handler->add_face (vv, vn, vt, count) );
517517 }
518518
519519 status_t Decompressor::parse_line (IObjHandler *handler, bool texcoords)
@@ -534,7 +534,7 @@ namespace lsp
534534 if ((res = read_indices (vt, count, texcoords)) != STATUS_OK)
535535 return res;
536536
537- return handler->add_line (vv, vt, count);
537+ return status_t ( handler->add_line (vv, vt, count) );
538538 }
539539
540540 status_t Decompressor::parse_points (IObjHandler *handler)
@@ -552,7 +552,7 @@ namespace lsp
552552 if ((res = read_indices (vv, count, true )) != STATUS_OK)
553553 return res;
554554
555- return handler->add_points (vv, count);
555+ return status_t ( handler->add_points (vv, count) );
556556 }
557557
558558 status_t Decompressor::parse_object (IObjHandler *handler)
0 commit comments