Whitespace cleanup

svn-id: r38783
This commit is contained in:
Jordi Vilalta Prat 2009-02-22 13:11:43 +00:00
parent ac409a2ab7
commit b5ce8d9320
69 changed files with 718 additions and 742 deletions

View file

@ -230,9 +230,8 @@ int gfxop_set_clip_zone(gfx_state_t *state, rect_t zone);
/******************************/ /******************************/
int gfxop_draw_line(gfx_state_t *state, int gfxop_draw_line(gfx_state_t *state,
Common::Point start, Common::Point end, Common::Point start, Common::Point end, gfx_color_t color,
gfx_color_t color, gfx_line_mode_t line_mode, gfx_line_mode_t line_mode, gfx_line_style_t line_style);
gfx_line_style_t line_style);
/* Renders a clipped line to the back buffer /* Renders a clipped line to the back buffer
** Parameters: (gfx_state_t *) state: The state affected ** Parameters: (gfx_state_t *) state: The state affected
** (Common::Point) start: Starting point of the line ** (Common::Point) start: Starting point of the line
@ -592,9 +591,8 @@ int gfxop_get_text_params(gfx_state_t *state, int font_nr, const char *text,
*/ */
gfx_text_handle_t *gfxop_new_text(gfx_state_t *state, int font_nr, char *text, int maxwidth, gfx_text_handle_t *gfxop_new_text(gfx_state_t *state, int font_nr, char *text, int maxwidth,
gfx_alignment_t halign, gfx_alignment_t valign, gfx_alignment_t halign, gfx_alignment_t valign, gfx_color_t color1,
gfx_color_t color1, gfx_color_t color2, gfx_color_t bg_color, gfx_color_t color2, gfx_color_t bg_color, int flags);
int flags);
/* Generates a new text handle that can be used to draw any text /* Generates a new text handle that can be used to draw any text
** Parameters: (gfx_state_t *) state: The state to use ** Parameters: (gfx_state_t *) state: The state to use
** (int) font_nr: Font number to use for the calculation ** (int) font_nr: Font number to use for the calculation

View file

@ -201,9 +201,7 @@ gfx_bitmap_font_t *gfxr_scale_font(gfx_bitmap_font_t *font, gfx_mode_t *mode, gf
*/ */
text_fragment_t *gfxr_font_calculate_size(gfx_bitmap_font_t *font, int max_width, const char *text, text_fragment_t *gfxr_font_calculate_size(gfx_bitmap_font_t *font, int max_width, const char *text,
int *width, int *height, int *width, int *height, int *lines, int *line_height, int *last_offset, int flags);
int *lines, int *line_height, int *last_offset,
int flags);
/* Calculates the size that would be occupied by drawing a specified text /* Calculates the size that would be occupied by drawing a specified text
** Parameters: (gfx_bitmap_font_t *) font: The font to calculate with ** Parameters: (gfx_bitmap_font_t *) font: The font to calculate with
** (int) max_width: Maximum pixel width allowed for the output ** (int) max_width: Maximum pixel width allowed for the output

View file

@ -202,10 +202,8 @@ void gfxr_antialiase(gfx_pixmap_t *pixmap, gfx_mode_t *mode, gfxr_antialiasing_t
** point corresponding to (dest.x, dest.y) */ ** point corresponding to (dest.x, dest.y) */
int gfx_crossblit_pixmap(gfx_mode_t *mode, gfx_pixmap_t *pxm, int priority, int gfx_crossblit_pixmap(gfx_mode_t *mode, gfx_pixmap_t *pxm, int priority,
rect_t src_coords, rect_t dest_coords, byte *dest, rect_t src_coords, rect_t dest_coords, byte *dest, int dest_line_width,
int dest_line_width, byte *priority_dest, byte *priority_dest, int priority_line_width, int priority_skip, int flags);
int priority_line_width, int priority_skip,
int flags);
/* Transfers the non-transparent part of a pixmap to a linear pixel buffer /* Transfers the non-transparent part of a pixmap to a linear pixel buffer
** Parameters: (gfx_mode_t *) mode: The graphics mode of the target buffer ** Parameters: (gfx_mode_t *) mode: The graphics mode of the target buffer
** (gfx_pixmap_t *) pxm: The pixmap to transfer ** (gfx_pixmap_t *) pxm: The pixmap to transfer

View file

@ -291,8 +291,7 @@ gfxw_view_t *gfxw_new_view(gfx_state_t *state, Common::Point pos, int view, int
*/ */
gfxw_dyn_view_t *gfxw_new_dyn_view(gfx_state_t *state, Common::Point pos, int z, int view, int loop, int cel, int palette, gfxw_dyn_view_t *gfxw_new_dyn_view(gfx_state_t *state, Common::Point pos, int z, int view, int loop, int cel, int palette,
int priority, int control, gfx_alignment_t halign, gfx_alignment_t valign, int priority, int control, gfx_alignment_t halign, gfx_alignment_t valign, int sequence);
int sequence);
/* Creates a new dyn view /* Creates a new dyn view
** Parameters: (gfx_state_t *) state: The graphics state ** Parameters: (gfx_state_t *) state: The graphics state
** (Common::Point) pos: The position to place the dynamic view at ** (Common::Point) pos: The position to place the dynamic view at
@ -438,7 +437,7 @@ gfxw_port_t *gfxw_find_default_port(gfxw_visual_t *visual);
void gfxw_port_set_auto_restore(gfxw_visual_t *visual, gfxw_port_t *window, rect_t auto_rect); void gfxw_port_set_auto_restore(gfxw_visual_t *visual, gfxw_port_t *window, rect_t auto_rect);
/* Sets rectangle to be restored upon port removal /* Sets rectangle to be restored upon port removal
** Parameters: (state_t *) s: The state to operate on ** Parameters: (state_t *) s: The state to operate on
(gfxw_port_t *) window: The affected window ** (gfxw_port_t *) window: The affected window
** (rect_t) auto_rect: The area to restore ** (rect_t) auto_rect: The area to restore
** Returns : (void) ** Returns : (void)
*/ */

View file

@ -498,8 +498,7 @@ exec_stack_t *send_selector(EngineState *s, reg_t send_obj, reg_t work_obj,
#define SCI_XS_CALLEE_LOCALS -1 #define SCI_XS_CALLEE_LOCALS -1
exec_stack_t *add_exec_stack_entry(EngineState *s, reg_t pc, stack_ptr_t sp, reg_t objp, int argc, exec_stack_t *add_exec_stack_entry(EngineState *s, reg_t pc, stack_ptr_t sp, reg_t objp, int argc,
stack_ptr_t argp, selector_t selector, reg_t sendp, int origin, stack_ptr_t argp, selector_t selector, reg_t sendp, int origin, seg_id_t local_segment);
seg_id_t local_segment);
/* Adds an entry to the top of the execution stack /* Adds an entry to the top of the execution stack
** Parameters: (EngineState *) s: The state with which to execute ** Parameters: (EngineState *) s: The state with which to execute
** (reg_t) pc: The initial program counter ** (reg_t) pc: The initial program counter
@ -552,10 +551,8 @@ void vm_handle_fatal_error(EngineState *s, int line, const char *file);
void script_debug(EngineState *s, reg_t *pc, stack_ptr_t *sp, stack_ptr_t *pp, reg_t *objp, void script_debug(EngineState *s, reg_t *pc, stack_ptr_t *sp, stack_ptr_t *pp, reg_t *objp,
int *restadjust, int *restadjust, seg_id_t *segids, reg_t **variables, reg_t **variables_base,
seg_id_t *segids, reg_t **variables, reg_t **variables_base, int *variables_nr, int bp);
int *variables_nr,
int bp);
/* Debugger functionality /* Debugger functionality
** Parameters: (EngineState *) s: The state at which debugging should take place ** Parameters: (EngineState *) s: The state at which debugging should take place
** (reg_t *) pc: Pointer to the program counter ** (reg_t *) pc: Pointer to the program counter

View file

@ -284,8 +284,7 @@ void vocab_free_branches(parse_tree_branch_t *parser_branches);
*/ */
result_word_t *vocab_lookup_word(char *word, int word_len, result_word_t *vocab_lookup_word(char *word, int word_len,
word_t **words, int words_nr, word_t **words, int words_nr, suffix_t **suffices, int suffices_nr);
suffix_t **suffices, int suffices_nr);
/* Looks up a single word in the words and suffixes list /* Looks up a single word in the words and suffixes list
** Parameters: (char *) word: Pointer to the word to look up ** Parameters: (char *) word: Pointer to the word to look up
** (int) word_len: Length of the word to look up ** (int) word_len: Length of the word to look up
@ -299,9 +298,7 @@ result_word_t *vocab_lookup_word(char *word, int word_len,
result_word_t *vocab_tokenize_string(char *sentence, int *result_nr, result_word_t *vocab_tokenize_string(char *sentence, int *result_nr,
word_t **words, int words_nr, word_t **words, int words_nr, suffix_t **suffices, int suffices_nr, char **error);
suffix_t **suffices, int suffices_nr,
char **error);
/* Tokenizes a string and compiles it into word_ts. /* Tokenizes a string and compiles it into word_ts.
** Parameters: (char *) sentence: The sentence to examine ** Parameters: (char *) sentence: The sentence to examine
** (int *) result_nr: The variable to store the resulting number of words in ** (int *) result_nr: The variable to store the resulting number of words in

View file

@ -119,9 +119,7 @@ static int _sci0_read_next_command(sci0_song_iterator_t *self,
static int _sci0_get_pcm_data(sci0_song_iterator_t *self, static int _sci0_get_pcm_data(sci0_song_iterator_t *self,
sfx_pcm_config_t *format, sfx_pcm_config_t *format, int *xoffset, unsigned int *xsize);
int *xoffset,
unsigned int *xsize);
#define PARSE_FLAG_LOOPS_UNLIMITED (1 << 0) /* Unlimited # of loops? */ #define PARSE_FLAG_LOOPS_UNLIMITED (1 << 0) /* Unlimited # of loops? */
#define PARSE_FLAG_PARAMETRIC_CUE (1 << 1) /* Assume that cues take an additional "cue value" argument */ #define PARSE_FLAG_PARAMETRIC_CUE (1 << 1) /* Assume that cues take an additional "cue value" argument */
@ -144,9 +142,8 @@ void _reset_synth_channels(base_song_iterator_t *self, song_iterator_channel_t *
} }
} }
static int _parse_sci_midi_command(base_song_iterator_t *self, unsigned char *buf, int *result, static int _parse_sci_midi_command(base_song_iterator_t *self, unsigned char *buf,
song_iterator_channel_t *channel, int *result, song_iterator_channel_t *channel, int flags) {
int flags) {
unsigned char cmd; unsigned char cmd;
int paramsleft; int paramsleft;
int midi_op; int midi_op;
@ -354,8 +351,7 @@ static int _parse_sci_midi_command(base_song_iterator_t *self, unsigned char *bu
} }
static int _sci_midi_process_state(base_song_iterator_t *self, unsigned char *buf, int *result, static int _sci_midi_process_state(base_song_iterator_t *self, unsigned char *buf, int *result,
song_iterator_channel_t *channel, song_iterator_channel_t *channel, int flags) {
int flags) {
CHECK_FOR_END(0); CHECK_FOR_END(0);
switch (channel->state) { switch (channel->state) {
@ -473,9 +469,7 @@ static inline int _sci0_header_magic_p(unsigned char *data, int offset, int size
static int _sci0_get_pcm_data(sci0_song_iterator_t *self, static int _sci0_get_pcm_data(sci0_song_iterator_t *self,
sfx_pcm_config_t *format, sfx_pcm_config_t *format, int *xoffset, unsigned int *xsize) {
int *xoffset,
unsigned int *xsize) {
int tries = 2; int tries = 2;
int found_it = 0; int found_it = 0;
unsigned char *pcm_data; unsigned char *pcm_data;
@ -1933,8 +1927,7 @@ song_iterator_t *songit_clone(song_iterator_t *it, int delta) {
} }
void song_iterator_add_death_listener(song_iterator_t *it, void song_iterator_add_death_listener(song_iterator_t *it,
void *client, void *client, void (*notify)(void *self, void *notifier)) {
void (*notify)(void *self, void *notifier)) {
if (it->death_listeners_nr >= SONGIT_MAX_LISTENERS) { if (it->death_listeners_nr >= SONGIT_MAX_LISTENERS) {
error("FATAL: Too many death listeners for song iterator"); error("FATAL: Too many death listeners for song iterator");
} }
@ -1945,8 +1938,7 @@ void song_iterator_add_death_listener(song_iterator_t *it,
it->death_listeners_nr++; it->death_listeners_nr++;
} }
void song_iterator_remove_death_listener(song_iterator_t *it, void song_iterator_remove_death_listener(song_iterator_t *it, void *client) {
void *client) {
int i; int i;
for (i = 0; i < it->death_listeners_nr; i++) { for (i = 0; i < it->death_listeners_nr; i++) {
if (it->death_listeners[i].self == client) { if (it->death_listeners[i].self == client) {

View file

@ -208,8 +208,7 @@ struct song_iterator_t {
** in the song-player thread. */ ** in the song-player thread. */
void song_iterator_add_death_listener(song_iterator_t *it, void song_iterator_add_death_listener(song_iterator_t *it,
void *client, void *client, void (*notify)(void *self, void *notifier));
void (*notify)(void *self, void *notifier));
/* Adds a death listener to a song iterator /* Adds a death listener to a song iterator
** Parameters: (song_iterator_t *) it: The iterator to add to ** Parameters: (song_iterator_t *) it: The iterator to add to
** (void *) client: The object wanting to be notified ** (void *) client: The object wanting to be notified
@ -220,8 +219,7 @@ void song_iterator_add_death_listener(song_iterator_t *it,
** Death listeners are NOT cloned. ** Death listeners are NOT cloned.
*/ */
void song_iterator_remove_death_listener(song_iterator_t *it, void song_iterator_remove_death_listener(song_iterator_t *it, void *client);
void *client);
/* Removes a death listener from a song iterator /* Removes a death listener from a song iterator
** Parameters: (song_iterator_t *) it: The iterator to modify ** Parameters: (song_iterator_t *) it: The iterator to modify
** (void *) client: The object no longer wanting to be notified ** (void *) client: The object no longer wanting to be notified

View file

@ -220,8 +220,7 @@ struct tee_song_iterator_t {
sfx_pcm_feed_t *sfx_iterator_make_feed(byte *base_data, int offset, sfx_pcm_feed_t *sfx_iterator_make_feed(byte *base_data, int offset,
int size, int size, sfx_pcm_config_t conf);
sfx_pcm_config_t conf);
/* Generates a feed for a song iterator /* Generates a feed for a song iterator
** Parameters: (byte *) base_data: A refcounted memory chunk containing ** Parameters: (byte *) base_data: A refcounted memory chunk containing
** (among other things) PCM data ** (among other things) PCM data