background.h

来自「Linux游戏编程源码」· C头文件 代码 · 共 19 行

H
19
字号
#ifndef BACKGROUND_H#define BACKGROUND_H#include <SDL/SDL.h>void InitBackground(void);/* Initializes the background drawing system. */void DrawBackground(SDL_Surface *dest, int camera_x, int camera_y);/* Draws the background on the screen, with respect to the global   "camera" position. The camera marks the 640x480 section of the   world that we can see at any given time. This is usually in the   vicinity of the player's ship. */void DrawParallax(SDL_Surface *dest, int camera_x, int camera_y);/* Same as above, but draws the upper (parallaxing) layer of the background. */#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?