]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/gpe-bootsplash/files/cairofix.patch
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / gpe-bootsplash / files / cairofix.patch
1 --- /tmp/splash.c       2005-10-06 14:45:21.463681488 +0200
2 +++ gpe-bootsplash-1.14/splash.c        2005-10-06 14:45:29.480462752 +0200
3 @@ -118,7 +118,8 @@
4  
5    tty = open ("/dev/tty0", O_RDWR);
6    if (tty < 0)
7 -    perror ("open");
8 +    tty = open ("/dev/vc/0", O_RDWR);
9 +  if (tty < 0)    perror ("open");
10    else
11      {
12        write (tty, cursoff, strlen (cursoff));
13 @@ -176,6 +177,7 @@
14    double scale, xscale, yscale;
15    svg_cairo_status_t status;
16    int width, height;
17 +  cairo_surface_t *surface;
18      
19    status = svg_cairo_create (&svgc);
20    if (status) 
21 @@ -201,17 +203,17 @@
22    xsize = (double)width * scale + 0.5;
23    ysize = (double)height * scale + 0.5;
24  
25 -  cr = cairo_create ();
26 -  cairo_scale (cr, scale, scale);
27  
28    pix = malloc (xsize * ysize * 4);
29    stride = xsize * 4;
30    has_alpha = TRUE;
31    
32 -  cairo_set_target_image (cr, pix, CAIRO_FORMAT_ARGB32, xsize, ysize, xsize * 4);
33 -
34 +  surface = cairo_image_surface_create_for_data(pix, CAIRO_FORMAT_ARGB32, xsize, ysize, stride);
35 +  cr = cairo_create (surface);
36 +  cairo_scale (cr, scale, scale);
37 +  
38    /* XXX: This probably doesn't need to be here (eventually) */
39 -  cairo_set_rgb_color (cr, 1, 1, 1);
40 +  cairo_set_source_rgb (cr, 1, 1, 1);
41  
42    svg_cairo_render (svgc, cr);
43