aboutsummaryrefslogtreecommitdiff
path: root/examples/graphics
diff options
context:
space:
mode:
authorspicyjpeg <thatspicyjpeg@gmail.com>2023-06-20 03:17:34 +0200
committerspicyjpeg <thatspicyjpeg@gmail.com>2023-06-20 03:17:34 +0200
commiteaea5649a0803cc4bfeb6d21ee9f4098d4b493fc (patch)
tree786f6edfae0c6affe0d7c7b222cd12f52578ca01 /examples/graphics
parent7eed71a90bed67e4a987a9db55e15e9403523dca (diff)
downloadpsn00bsdk-eaea5649a0803cc4bfeb6d21ee9f4098d4b493fc.tar.gz
Fix IRQ bugs, PutDispEnv() PAL screen centering
Diffstat (limited to 'examples/graphics')
-rw-r--r--examples/graphics/hdtv/main.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/examples/graphics/hdtv/main.c b/examples/graphics/hdtv/main.c
index 827b096..4d15742 100644
--- a/examples/graphics/hdtv/main.c
+++ b/examples/graphics/hdtv/main.c
@@ -651,13 +651,12 @@ void init() {
SetDefDispEnv( &db[0].disp, 0, 0, 640, SCREEN_YRES );
SetDefDrawEnv( &db[0].draw, 0, 0, SCREEN_XRES, SCREEN_YRES );
- db[0].disp.isinter = 1; // enable interlace, mandatory for hi-res modes
+ // Enable interlace (mandatory for hi-res modes)
+ db[0].disp.isinter = 1;
- db[0].disp.screen.x = -37; // shift left to center the widened picture
-
- db[0].disp.screen.w = 704; // increase the picture width to 704 pixels
- // (this does not strech the picture, it just
- // tells the GPU to output more pixels)
+ // Increase the picture width to 704 pixels
+ // (without stretching it, just tell the GPU to output more pixels)
+ db[0].disp.screen.w = (704 * 256) / 640;
// Enable draw area clear and dither processing
setRGB0( &db[0].draw, 63, 0, 127 );