1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-30 21:49:25 +00:00
freebsd-ports/graphics/mpegedit/files/patch-ac
R. Imura f4001e4a49 Fix new compiler error in -current.
Submitted by:		Alexander Langer <alex@big.endian.de>
All no response from:	maintainer
2000-02-12 19:17:21 +00:00

48 lines
1.7 KiB
Plaintext

--- editor/2x2_window.C.orig Mon May 8 16:08:35 1995
+++ editor/2x2_window.C Thu Feb 3 21:24:19 2000
@@ -25,6 +25,8 @@
#include <iostream.h>
#include <stdlib.h>
+extern "C" int XShmGetEventBase(Display *);
+
DblWindow::DblWindow(UI_Globals *parent, world_c x, world_c y,
unsigned int height, unsigned int width, void (*cb)(void) )
: YUV_Window(parent,x,y,height*2,width*2,this, ButtonPressMask |
@@ -139,7 +141,7 @@
ximage = XCreateImage(DispPointer(),None,8,ZPixmap,0,&dummy,width*2,
height*2,8,0);
- ximage->data = new byte[ximage->bytes_per_line*height*2];
+ ximage->data = (char *) new byte[ximage->bytes_per_line*height*2];
assert(ximage->data!=NULL);
#ifdef SH_MEM
@@ -160,7 +162,7 @@
for(int j = 0; j < ncolors; j ++)
{
tmp_pixel = col_array[j];
- XFreeColors(DispPointer(), Colourmap, &tmp_pixel, 1, 0);
+ XFreeColors(DispPointer(), Colourmap, (long unsigned int *) &tmp_pixel, 1, 0);
}
#ifdef SH_MEM
@@ -259,7 +261,7 @@
for(int j = 0; j < i; j ++)
{
tmp_pixel = col_array[j];
- XFreeColors(DispPointer(), Colourmap, &tmp_pixel, 1, 0);
+ XFreeColors(DispPointer(), Colourmap, (long unsigned int *) &tmp_pixel, 1, 0);
}
cerr << "Unable to allocate the colours required to make the\n"
<< "colour window. Please re-run with the option -private cols\n";
@@ -363,7 +365,7 @@
{
assert(Frame.width()==ximage->width/2);
assert(Frame.height()==ximage->height/2);
- DitherImage(Frame.lum_ptr(),Frame.Cr_ptr(),Frame.Cb_ptr(),ximage->data,
+ DitherImage(Frame.lum_ptr(),Frame.Cr_ptr(),Frame.Cb_ptr(),(unsigned char *)ximage->data,
Frame.width(),Frame.height());
if(nicely)
{