ugBASIC 1.18
An isomorphic BASIC language compiler for retrocomputers
Loading...
Searching...
No Matches
screen_vertical_scroll.c File Reference
#include "../../ugbc.h"

Go to the source code of this file.

Functions

void screen_vertical_scroll (Environment *_environment, int _displacement)
 Emit ASM code for SCREEN VERTICAL SCROLL [int]x.
void screen_vertical_scroll_var (Environment *_environment, char *_displacement)
 Emit ASM code for SCREEN VERTICAL SCROLL [expression].

Function Documentation

◆ screen_vertical_scroll()

void screen_vertical_scroll ( Environment * _environment,
int _displacement )

Emit ASM code for SCREEN VERTICAL SCROLL [int]x.

Emit ASM code for SCREEN VERTICAL SCROLL [integer].

This function outputs an assembly code capable of performing a hardware scroll of the screen. The scroll is always in the direction from bottom to up, so with a _displacement of 0 the screen is exactly as it would be without scrolling while with the value 7 you would have a scroll of 7 pixels upwards. This version is used when a direct integer is used.

Parameters
_environmentCurrent calling environment
_displacementVertical offset in pixels (0-7)

Definition at line 53 of file screen_vertical_scroll.c.

◆ screen_vertical_scroll_var()

void screen_vertical_scroll_var ( Environment * _environment,
char * _displacement )

Emit ASM code for SCREEN VERTICAL SCROLL [expression].

This function outputs an assembly code capable of performing a hardware scroll of the screen. The scroll is always in the direction from bottom to up, so with a _displacement of 0 the screen is exactly as it would be without scrolling while with the value 7 you would have a scroll of 7 pixels upwards. This version is used when an expression is used.

Parameters
_environmentCurrent calling environment
_displacementVertical offset in pixels (0-7)

Definition at line 71 of file screen_vertical_scroll.c.