Jump to content

  • Log In with Google      Sign In   
  • Create Account

Cairo & SDL Include / Lib problems ;/


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
No replies to this topic

#1 DarkHorseKnight   Members   -  Reputation: 143

Like
0Likes
Like

Posted 22 September 2012 - 06:08 PM

Hello just ran into a problem I don't understand why it is happening?

I'm trying to use cairo with sdl obviously but having issues with the functions that I'm so posed to use mainly because the header / cpp file naming "cairosdl.h" and "cairosdl.c" are full of errors when included in my main.cpp file so I was hoping someone could tell me what these errors mean to help in my quest of fixing this problem thank you ! I don't really understand them.

here is a pastebin too the cmd shell error outputs -> http://pastebin.com/vEuJNfYs

and here are the functions I used below

cairo_surface_t *cairosurf = cairo_image_surface_create_for_data (
static_cast<unsigned char *>(sdlsurf->pixels),
CAIRO_FORMAT_RGB24,
sdlsurf->w,
sdlsurf->h,
sdlsurf->pitch);

cairo_t *cr = cairosdl_create(sdlsurf);

cairo_set_source_rgba(cr, 1,1,0,0.5);

cairo_rectangle(cr, 25,25,50,50);
cairo_fill(cr);

cairosdl_destroy(cr);

cairo_select_font_face (cr, "serif", CAIRO_FONT_SLANT_NORMAL, CAIRO_FONT_WEIGHT_BOLD);
cairo_set_font_size (cr, 32.0);
cairo_set_source_rgb (cr, 0.0, 0.0, 1.0);
cairo_move_to (cr, 10.0, 50.0);
cairo_show_text(cr,"Hello, world");

Edited by DarkHorseKnight, 22 September 2012 - 06:09 PM.


Sponsor:



Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS