diff options
Diffstat (limited to 'vcl/source/filter/jpeg')
-rw-r--r-- | vcl/source/filter/jpeg/JpegReader.cxx | 10 | ||||
-rw-r--r-- | vcl/source/filter/jpeg/JpegWriter.cxx | 10 | ||||
-rw-r--r-- | vcl/source/filter/jpeg/jpegc.cxx | 2 |
3 files changed, 11 insertions, 11 deletions
diff --git a/vcl/source/filter/jpeg/JpegReader.cxx b/vcl/source/filter/jpeg/JpegReader.cxx index 0450bc602b4d..03c3ce918b30 100644 --- a/vcl/source/filter/jpeg/JpegReader.cxx +++ b/vcl/source/filter/jpeg/JpegReader.cxx @@ -147,7 +147,7 @@ extern "C" void term_source (j_decompress_ptr) void jpeg_svstream_src (j_decompress_ptr cinfo, void* input) { SourceManagerStruct * source; - SvStream* stream = (SvStream*)input; + SvStream* stream = static_cast<SvStream*>(input); /* The source object and input buffer are made permanent so that a series * of JPEG images can be read from the same file by calling jpeg_stdio_src @@ -159,11 +159,11 @@ void jpeg_svstream_src (j_decompress_ptr cinfo, void* input) if (cinfo->src == NULL) { /* first time for this JPEG object? */ - cinfo->src = (jpeg_source_mgr *) - (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_PERMANENT, sizeof(SourceManagerStruct)); + cinfo->src = static_cast<jpeg_source_mgr *>( + (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_PERMANENT, sizeof(SourceManagerStruct))); source = reinterpret_cast<SourceManagerStruct *>(cinfo->src); - source->buffer = (JOCTET *) - (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_PERMANENT, BUFFER_SIZE * sizeof(JOCTET)); + source->buffer = static_cast<JOCTET *>( + (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_PERMANENT, BUFFER_SIZE * sizeof(JOCTET))); } source = reinterpret_cast<SourceManagerStruct *>(cinfo->src); diff --git a/vcl/source/filter/jpeg/JpegWriter.cxx b/vcl/source/filter/jpeg/JpegWriter.cxx index 179d3533fe45..45fd8ceceb41 100644 --- a/vcl/source/filter/jpeg/JpegWriter.cxx +++ b/vcl/source/filter/jpeg/JpegWriter.cxx @@ -43,8 +43,8 @@ extern "C" void init_destination (j_compress_ptr cinfo) DestinationManagerStruct * destination = reinterpret_cast<DestinationManagerStruct *>(cinfo->dest); /* Allocate the output buffer -- it will be released when done with image */ - destination->buffer = (JOCTET *) - (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_IMAGE, BUFFER_SIZE * sizeof(JOCTET)); + destination->buffer = static_cast<JOCTET *>( + (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_IMAGE, BUFFER_SIZE * sizeof(JOCTET))); destination->pub.next_output_byte = destination->buffer; destination->pub.free_in_buffer = BUFFER_SIZE; @@ -82,7 +82,7 @@ extern "C" void term_destination (j_compress_ptr cinfo) void jpeg_svstream_dest (j_compress_ptr cinfo, void* output) { - SvStream* stream = (SvStream*) output; + SvStream* stream = static_cast<SvStream*>(output); DestinationManagerStruct * destination; /* The destination object is made permanent so that multiple JPEG images @@ -93,8 +93,8 @@ void jpeg_svstream_dest (j_compress_ptr cinfo, void* output) */ if (cinfo->dest == NULL) { /* first time for this JPEG object? */ - cinfo->dest = (jpeg_destination_mgr*) - (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_PERMANENT, sizeof(DestinationManagerStruct)); + cinfo->dest = static_cast<jpeg_destination_mgr*>( + (*cinfo->mem->alloc_small) (reinterpret_cast<j_common_ptr>(cinfo), JPOOL_PERMANENT, sizeof(DestinationManagerStruct))); } destination = reinterpret_cast<DestinationManagerStruct *>(cinfo->dest); diff --git a/vcl/source/filter/jpeg/jpegc.cxx b/vcl/source/filter/jpeg/jpegc.cxx index 0aed0f2b4a1c..2d171d839876 100644 --- a/vcl/source/filter/jpeg/jpegc.cxx +++ b/vcl/source/filter/jpeg/jpegc.cxx @@ -290,7 +290,7 @@ bool WriteJPEG( JPEGWriter* pJPEGWriter, void* pOutputStream, if( pScanline ) { - jpeg_write_scanlines( &cinfo, (JSAMPARRAY) &pScanline, 1 ); + jpeg_write_scanlines( &cinfo, reinterpret_cast<JSAMPARRAY>(&pScanline), 1 ); } if( status.is() ) |