ÇóÖú!C±à³ÌÎÊÌâ!!
ÇóÖú¸ßÊÖ°ïÎÒ¿´ÏÂÏÂÃæµÄ´úÂë(ÂÒÁ˵ã)[COLOR=#22229c]//client[/COLOR]ZkW%Aaz
[COLOR=#22229c]#include <unistd.h>[/COLOR]
[COLOR=#22229c]#include <netinet/in.h>[/COLOR]
[COLOR=#22229c]#include <arpa/inet.h>[/COLOR]
[COLOR=#22229c]#include <netdb.h>[/COLOR]
[COLOR=#22229c]#include <stdlib.h>[/COLOR]
[COLOR=#22229c]#include <SDL.h>[/COLOR],wO&m'r Vd F[,HX W
[COLOR=#22229c]#include <SDL_image.h>[/COLOR]8oc%c4^&]
[COLOR=#22229c]#define SER_PORT 1500[/COLOR]4j vX,];T'pc;e
[COLOR=#22229c]#define MAX_LEN 261[/COLOR]A8WRl^o(_
[COLOR=#22229c]void ShowJpg(char *file, SDL_Surface *screen, int x, int y)[/COLOR]
[COLOR=#22229c]{[/COLOR]4n+v;Gr Jb8[${
[COLOR=#22229c]SDL_Surface *image;[/COLOR]+w/bj^M$Zl
[COLOR=#22229c]SDL_Rect dest;[/COLOR]T T?axRN
[COLOR=#22229c]image = IMG_Load(file);[/COLOR]0G#Pta}0N)~:~Od
[COLOR=#22229c]if ( image == NULL ) {[/COLOR]
[COLOR=#22229c]fprintf(stderr, "ÎÞ·¨¼ÓÔØ %s: %s\n", file, SDL_GetError());[/COLOR]9tH K:^.ld
[COLOR=#22229c]return;[/COLOR]
[COLOR=#22229c]}[/COLOR]
[COLOR=#22229c]dest.x = x;[/COLOR]
[COLOR=#22229c]dest.y = y;[/COLOR]:l+G/@rcX*o
[COLOR=#22229c]dest.w = image->w;[/COLOR]
[COLOR=#22229c]dest.h = image->h;[/COLOR]