summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib
diff options
context:
space:
mode:
author Aaron Giles <aaron@aarongiles.com>2008-08-18 04:31:08 +0000
committer Aaron Giles <aaron@aarongiles.com>2008-08-18 04:31:08 +0000
commit284b5a0d95c4740b25fd1d06aecd2cc74eae12f3 (patch)
treeed984f6362decda13c57c168d5d2d18d6e30d06c /src/lib
parentd0eb89399fc684c90330466674470775079ae113 (diff)
Added new generic laserdisc VIDEO_UPDATE handler to the laserdisc code.
This handler works for both disc-only games and those with overlays. For disc-only games, the base macro is sufficient. For games with overlays, an additional set of configuration macros are provided: MDRV_LASERDISC_OVERLAY - specifies update function, width, height, and bitmap format of the overlay MDRV_LASERDISC_OVERLAY_CLIP - specifies the visible area of the overlay bitmap MDRV_LASERDISC_OVERLAY_POSITION - specifies default x,y position MDRV_LASERDISC_OVERLAY_SCALE - specifies default x,y scale factors The update function provided to MDRV_LASERDISC_OVERLAY is identical to a normal VIDEO_UPDATE callback, so a standard one can be used. All existing laserdisc drivers have been updated to support this new rendering mechanism, removing much duplicated code. Added the ability to configure the overlay position and scale parameters at runtime. Added OSD menus to control them. Added logic to save/restore the data in the game's configuration file. Added new macros MDRV_LASERDISC_SCREEN_ADD_NTSC and _PAL, which defines a standard screen with the correct video timing characteristics and update function for laserdiscs. Updated all drivers to use these macros instead of defining their own screens. Added DISK_REGIONS to all laserdisc drivers. Added DISK_IMAGE_READONLY_OPTIONAL to support games (like Cube Quest) where the disk is non-essential to the game's operation. Fixed bug in identifying the custom sound driver for the laserdisc. Updated ldverify to identify blank regions of the disc for post- processing. Fixed rendering 16bpp with alpha using bilinear filters (fixes screenshots of laserdisc games with overlays). Included support for parsing .gdi files in chdman. [ElSemi] Added new driver for Cube Quest. This includes CPU cores for the three bitslice processors, as well as laserdisc support for the hacked laserdisc that was used to drive the games. [Philip Bennett, Joe Magiera, Warren Ondras] Note that the SHA1/MD5 for the laserdisc will likely undergo at least one more change before being finalized.
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/util/avcomp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/util/avcomp.c b/src/lib/util/avcomp.c
index 3441bd12670..779150e5be0 100644
--- a/src/lib/util/avcomp.c
+++ b/src/lib/util/avcomp.c
@@ -354,7 +354,7 @@ avcomp_error avcomp_encode_data(avcomp_state *state, const UINT8 *source, UINT8
/* encode the video data */
if (width > 0 && height > 0)
{
- UINT32 vidlength;
+ UINT32 vidlength = 0;
/* encode the video */
err = encode_video(state, width, height, videostart, videostride, videoxor, dest + dstoffs, &vidlength);
@@ -633,7 +633,7 @@ static avcomp_error encode_video_lossless(avcomp_state *state, int width, int he
huffman_error hufferr;
UINT32 outbytes;
UINT8 *output;
-
+
/* set up the output; first byte is 0x80 to indicate lossless encoding */
output = dest;
*output++ = 0x80;
@@ -800,7 +800,7 @@ static avcomp_error decode_video(avcomp_state *state, int width, int height, con
/* if the high bit of the first byte is set, we decode losslessly */
if (source[0] & 0x80)
return decode_video_lossless(state, width, height, source, complength, dest, dstride, dxor);
- else
+ else
return AVCERR_INVALID_DATA;
}