NAME
	mame.exe - the AdvanceMAME emulator

DESCRIPTION
	AdvanceMAME is an unofficial MAME version with an advanced
	video support for helping the use with TVs, Arcade Monitors,
	Fixed Frequencies Monitors and also with normal PC Monitors.

	These are the major features:

	) Possibility for the user to create new VGA/VBE tweaked
	video modes with any size and frequencies

	) A lot of video boards supported for direct hardware registers 
	programming (see the card.txt file)

	) Automatic creation of `perfect' video modes with the correct 
	size and frame rate.

	) Software video image stretching by fractional factors, for
	example to play vertical games like PacMan with horizontal
	Arcade Monitors or TVs.

	) Special `blit' effects to improve the image quality in
	stretching.
	
	) Special `rgb' effects to simulate the aspect of a real 
	Arcade Monitor.

	) Rotation supported also at blit level to play games that
	don't rotate correctly.

	) Change of the video mode and other options at runtime.

	) Automatic exit after some time of inactivity.

	) Various utilities to help the configuration process and the
	use with Arcade Cabinets.

VIDEO MENU
	AdvanceMAME add a new `Video' menu to change the video options.

	You can select the desiderated video mode, the resize type and
	the video effects.

	The option selected is displayed in the right side of the menu,
	the effective value used for the option is displayed in `[]'.
	Sometime these may differs.

	There are some limitations :
	) For vector games you can't change the screen size at runtime
	) If you enable the `sync' (not the `waitvsync') option you
		can't change the video mode at runtime

	When you have selected the best options you can save them for
	the current game or for all the games that have the same
	resolution. These options are saved in your `mame.cfg' file.

VIDEO RESIZE OPTION
	The `resize' option suggests the software stretching factor
	used when the video configuration is selected automatically.
	There are four options: 'no', 'integer', 'mixed', 'fractional'.

	The 'no' option simply disable any type of stretching.

	The 'integer' option allow only integer stretching in the
	horizontal and vertical directions. For example 1x2, 2x1, 2x2.

	The 'mixed' option allow integer stretching in the horizontal
	direction and fractional stretching in the vertical direction.
	For example 1x1.23, 2x1.18.

	The 'fractional' option allow fractional stretching in any
	directions. For example 1.08x1.08, 1.34x1.78.

	Usually the best choice is the `mixed' option. It's very fast
	and the quality of the image doesn't suffer too much.

	Please note that the `resize' option works only if you choose
	the `auto' item for the `Video config' option.
	This happens because the list of video configuration already
	contains implicitly this information.

BLIT EFFECT OPTION
	The video effects can be used to improve the image quality when
	the image is stretched. If the image is displayed without
	stretching the video effects are not useful.

	There are five type of video effects: `no', `max', `mean', 
	`filter' and `scale2x'.

	The `no' effect simply duplicates and removes rows and lines
	when the image is stretched.

	The `max' effect tries to save the image details displaying the
	most lighting pixels when some rows are removed.

	The `mean' effect tries to save the image details displaying the
	mean color of the pixels in the rows that need to be reduced.

	The `filter' effect apply a generic blur filter computing the
	mean color in the horizontal and vertical directions. The best
	results are when the image is stretched almost by a double factor.
	When the image is enlarged the filter is applied after the
	stretching, when it's reduced it's applied before.

	The `scale2x' effect add the missing pixels trying to match the
	image patterns. This effect works like the Eagle library.

	There are some limitations :

	) The `mean' and `filter' options work only in rgb video modes
		(not palettized).
	) The `max' effect works with games with a static palette or if
		the selected video mode is rgb
	) The `scale2x' effect works only if the image is magnified by a
		factor of 2. To enable it you should also use the 
		`magnify' option.

	Please note that 8 bits modes can be rbg or palettized modes.
	Usually they are used as palettized if the emulated game requires
	less than 256 colors. Instead 16 bits modes are always rgb modes.

VIDEO CONFIG OPTION
	In the `Video Config' submenu you can select the favorite
	video configuration.

	If you choose the `auto' item the best configuration
	that follow your `resize' option is automatically selected.

	For every video configuration these information are displayed:

	SIZEX x SIZEY BITS DISPLAY% FACTORX x FACTORY RESIZE

		SIZEX,SIZEY - size
		BITS - color depth
		DISPLAY - % of the displayed game screen, 100% it's ok.
		FACTORX,FACTORY - expansion factor
		RESIZE - one of the `integer', `mixed', `fractional'

	You can also change the active video configuration pressing `,'
	and `.' during the game play.

STARTUP VIDEO MODE AND VIDEO CONFIGURATION
	At startup the program tries to select the best video mode
	available. Only video modes present in the file `mame.cfg' are
	evaluated. 

	For any video modes a set of possible video configurations are
	created. For video configuration is intended a video mode
	plus the possible sizes of the game/video screen.

	The video configurations are named as MODENAME-GAMESIZE-VIDEOSIZE,
	where MODENAME is the video mode name, GAMESIZE is the part
	of the game screen visualized and VIDEOSIZE if the part of the
	video screen used for the visualization.

	From all the created video configurations the best is selected and
	used. In this case the value of the option `resize' is evaluated.

	You can force a video configuration with the option `video'.

	To display this process use the `-log' option of `mame' and read
	the file `error.log'. All the possible video configurations are
	displayed in reverse order of preference.

CONFIGURATION (new or modified options)
	These are the new or modified options supported in the
	file `mame.cfg' and used by the program `mame'.

	All the `[config]' options in the `mame.cfg' file are read
	in three different sections. This is the order of preference:

		[GAME] - the short game name, like [pacman]
		[RESOLUTION] - the resolution of the game, like [244x288]
			for raster games or [vector] for vector games
		[config] - the default section

	You can override also the options in other sections using
	the format :

		SECTION_OPTION =

	For example:

		[pacman]
		video = my_video_mode
		script_emulation = on(kdb,1);
		directory_rom = C:\PACROM

    "[config] video"
	Select a specific video mode or video configuration by his name.
	For a better explanation of video modes and video configurations
	see the dedicated section below.

	video = auto | MODE_NAME | CONFIG_NAME

	Options:
		MODE_NAME - specific video mode, as named in the
			`mv' utility
		CONFIG_NAME - specific video configuration, as named
			in the file error.log as result of running 
			`mame' with the `-log' argument
		auto - automatically choose the best video
			configuration available (default)

	If you select `auto' or `MODENAME' the option `resize' is
	used to choose the best video configuration available.
	If you select `CONFIGNAME' the `resize' information is
	implicit in the video configuration selected.

	Example for using the automatic detection :
		video=auto

	Example for using the default vga mode :
		video=bios_vga_320x200x8

    "[config] videogenerate"
	Select if and how to generate a `perfect' video mode for the
	game emulated. A correct use of this option remove the need
	of any software stretching improving a lot the game image.

	videogenerate = no | adjustx | generate

	Options:
		no - no automatic video mode creation. Use only the
			video modes on the modeline list. (default)
		adjustx - use the video modes on the list but try to
			stretch them horizontally. The strecthed video
			mode maintains the same vertical and horizontal
			clock of the original mode.
			Also all other video mode attributes, like
			doublescan and interlace, are maintained.
			This option is useful if you use the monitor
			control memory to store the adjustement of video
			modes.
		generate - create a completly new video mode using the
			format specified on the `[video] format' option.
			Check the `mv.txt' file for other explanation or
			simply use the `cfg' utility to setup it correctly.
			If the `[video] format' option isn't specified a
			default value for a standard VGA monitor is used.

	The `generate' option is the most powerful, you don't need to
	create a list of modelines with the `mv' utility.
	This is the option setup by the `cfg' utility.

	If you can't get good result with the `generate' you should
	create a list of modelines and try with the `adjustx' option.
	The horizontal resolution of the modelines isn't important
	because the video mode are stretched in any case.
	Instead you should create a wide set of different vertical
	resolutions on witch the video mode can be choosen.
	A good choice is to create all the resolutions with a step of
	16 rows.

	If you use the `generate' or the `adjustx' options (with
	a wide range of vertical resolutions) you can set the option
	`resize=integer' for a MultiSync Monitor or `resize=mixed' for an
	Arcade/TV to disable the software stretching.

    "[config] resize"
	Used to suggest the desiderated software image stretch type.
	This option don't have any effect for vector games or
	if you select a specific video configuration with the
	`video' option.

	resize = no | integer | mixed | fractional

	Options:
		no - original size
		integer - integer stretch, i.e. x2, x3, x4,...
		mixed - integer horizontal stretch and fractional
			vertical stretch (default)
		fractional - fractional stretch

	The `fractional' option involve a big slowdown, so the `mixed' 
	option is suggested.
	If `fractional' or `mixed' is selected the dirty buffer is
	disabled.
	This option change the way how a video configuration is selected.
	If you force a specific video configuration this option is ignored.

	Example :
		resize = mixed

    "[config] magnify"
	Used to suggest the use of double resolution video mode.
	This option don't have any effect for vector games or
	if you select a specific video configuration with the
	`video' option.

	magnify = yes | no

    "[config] rgb"
	Used to suggest the use of a RGB video mode.
	This option don't have any effect if you select a specific
	video configuration with the `video' option.

	rgb = yes | no

	Note that also if you set it to `no' a rgb mode can be
	selected if required by the game. This option is useful to
	force a RGB mode for the other `blit' and `rgb' effects.

    "[config] scanline"
	Used to suggest the use of hardware scanlines.
	This option don't have any effect if you select a specific
	video configuration with the `video' option.

	scanlines = yes | no

    "[config] triplebuffer"
	Activate the video image buffering.

	triplebuffer = yes | no | auto

	Options:
		auto - use the best buffering available
		yes - use the best buffering available
		no - don't use any buffering (default)

	The suggested choice is to enable the buffering.

	The video buffering method is very different than the official mame.
	The official mame stacks the image horizontally and use always 3
	video memory buffers. Advance Mame stacks the image vertically
	with an alignment of 64K and use 3 video memory buffers if
	a synchronous page set function is present, and 2 video memory
	buffers if only the asynchronous page set function is available.
	The latter is the most common case.

	Example:
		triplebuffer = yes

    "[config] blitrotate"
	Select where the rotation is done. At core level or at blit level.
	This solves problems with all games that don't rotate correctly if 
	used with a vertical monitor. For example all NeoGeo games.

	blitrotate = yes | no | auto

	Options:
		yes - use the rotation at blit level
		no - use the rotation at core level
		auto - select automatically the best mode. (default)
			This selection is list based, and may be a lot
			incomplete.

	Because this options may involve a slowdown it's suggested
	to use it only for games that require it. However if no rotation
	is done, no performance degradation is present. So the
	suggested choice is `auto'.

	Example:
		blitrotate = auto

    "[config] bliteffect"
	When a video mode is smaller or bigger than the original arcade
	screen, the `bliteffect' option controls the type of the
	transformation applied.

	bliteffect = auto | no | max | mean | filter 
		| filterx | filtery | scale2x

	Options:
		auto - Select automatically the best effect. (default)
			This selection is list based, and may be a lot
			incomplete.
			The 'filter' effect is used when the game is
			strecthed by a factor greather or equal of 2.
			On the other cases the 'mean' or 'max' effect
			is selected.
		no - Simply removes or duplicates lines as required.
		max - In vertical reduction merges consecutive lines
			using the lightest pixels versus the darkest.
			In vertical expansion simply duplicates lines.
			Supported only in games with a static palette
			or in rgb modes.
			It works best for the games with black background 
			or without scrolling. Like "pacman".
		mean - In vertical reduction merges lines using the
			mean color of the pixels. In vertical expansion 
			adds lines which are the mean of the previous and 
			the next.
			Supported only in rgb (not palettized) video modes.
			It works best for the games with very high 
			resolution. Like "1941".
		filter - In vertical reduction and expansion removes or
			duplicates lines and applies a low pass 
			filter in the x and the y directions. 
			It's a simple FIR filter with two points of 
			equal value.
			Supported only in rgb (not palettized) video modes.
		filterx - like `filter' but only in the x direction
		filtery - like `filter' but only in the y direction
		scale2x - It works only in expansion by a factor of 2.
			It tryes to add the missing pixels matching the
			original bitmap pattern.

	Example:
		bliteffect = auto

    "[config] rgbeffect"
	This option select a special effect to simulate the aspect of
	an Arcade Monitor with a PC monitor. The resulting images is
	better when you use a big video mode.
	These effects require a RGB video mode to work.

	rgbeffect = no | triad3dot | triad6dot | triad16dot
		| triadstrong3dot | triadstrong6dot | triadstrong16dot
		| scan2vert | scan3vert | scan2horz | scan3horz.

	Options:
		no - no effect (default)
		triad3dot - RGB triad of 3 pixels
		triad6dot - RGB triad of 6 pixels
		triad16dot - RGB triad of 16 pixels
		triadstrong3dot - RGB strong triad of 3 pixels
		triadstrong6dot - RGB strong triad of 6 pixels
		triadstrong16dot - RGB strong triad of 16 pixels
		scan2vert - Scanline of 2 vertical lines
		scan3vert - Scanline of 3 vertical lines
		scan2horz - Scanline of 2 horizontal lines
		scan3horz - Scanline of 3 horizontal lines

	Example:
		rgbeffect = triad3dot

    "[config] vsync_adjust"
	Enable the adjustement of the video 'vbeline' modes to match
	the exact frame rate of the emulated games.

	This option makes sense only with a PC multisync monitor which can
	accept a wide range of vertical and horizontal frequencies.

	You must also activate the original `vsync' option to
	enable the vsync. If the `vsync' option is set to `no'
	this option doesn't have any effects.

	If you enable this option ONLY the `vbeline' modes are used. Any
	other modes are ignored. So obviously you need to have some
	`vbeline' modes available.

	sync_adjust = yes | no

	Options:
		yes - activate the vsync adjustment
		no - disable it (default)

	Example:
		vsync = yes
		vsync_adjust = yes

	Please note that when vsync is enabled you are very
	limited in the video mode change at runtime.

    "[config] vsync_correction_factor"
	Select a correction factor of the measured frame rate of
	the video mode.
	You should use this option ONLY if when playing with `vsync'
	active and in `auto frameskip' mode, the frameskip increase
	too much. If this happen you should decrease the default
	value. Generally this value should be in the range 0.99
	and 1.

	vsync_correction_factor = VALUE

	Options:
		VALUE - float value from 0.99 to 1. (default 0.999)

	Example:
		vsync_correction_factor = 0.995

    "[config] turbospeed"
	Select the speed factor used when the `turbo' button is pressed.
	The default `turbo' button is the num pad `*'.

	turbospeed = FACTOR

	Example:
		turbospeed = 3.0

    "[config] turbostartuptime"
	Select the time in seconds of the duration of the startup speed up.

	turbostartuptime = TIME

	Example:
		turbostartuptime = 8

    "[config] idleexit"
	Activate the automatic exit after some time of inactivity.

	idleexit = TIME

	Options:
		TIME - number of seconds to wait, if 0 (default)
			never exit automatically

	Example:
		idle_exit = 400

    "[config] safeexit"
	Activate the safe exit mode. If enabled to stop the
	emulation you need to confirm on a simple menu.

	safeexit = yes | no

    "[config] brightness"
	Select the desiderated image brightness

	brightness = FACTOR

	Options:
		factor - multiplicative factor, 1.0 is the default

	Example:
		brightness = 0.8

    "[config] skiplines"
    "[config] skipcolumns"
	Select the centering of the visible area.

	skiplines = auto | SKIPLINES
	skipcolumns = auto | SKIPCOLUMNS

	Options:
		auto - auto center (default)
		SKIPLINES - lines to skip
		SKIPCOLUMNS - columns to skip

    "[config] video_mode_reset"
	Select if to reset the default text mode at the emulator exit.

	video_mode_reset = yes | no

	Options:
		yes - reset to text mode (default)
		no - don't change the video mode

    "[config] video_factor_*"
	Control how the automatic video mode choice is done. They are
	weight factors for the various video mode properties. A greater
	value does more importance at the relative property.
	You can see the complete evaluation process using the `-log' option
	and check the resulting `error.log' file.

	video_factor_game_visible = VALUE
	video_factor_game_stretch = VALUE
	video_factor_screen_visible = VALUE
	video_factor_mode_size = VALUE
	video_factor_frequency = VALUE
	video_factor_aspect = VALUE
	
	Options:
		game_visible - The part of the game display visible. The
			whole game display is considered better.
		game_stretch - How much the game display is stretched to
			fit the video mode size. No stretch is considered 
			better.
		screen_visible - The part of the monitor screen used to
			display the game. Bigger is considered better.
		mode_size - The size of the video mode. Smaller is better.
		frequency - How much the video mode frequency match the 
			original game framerate.
		aspect - How much the video mode aspect match the 
			original game aspect.

	Note that the `game_visible' and the `game_stretch' option are
	used alternatively when the video mode size is smaller than the
	game display. If the video mode supports the game stretching
	the game display is always completely visible. If the video mode 
	doesn't support the game stretching the game display is only
	partially visible.

	Example: (suggested and default options)
		video_factor_game_visible = 8.0
		video_factor_game_stretch = 4.0
		video_factor_screen_visible = 1.0
		video_factor_mode_size = 1.0
		video_factor_frequency = 0.0
		video_factor_aspect = 1.0
		
    "[config] recordtime"
	This option controls the maximum length in seconds of the sound
	recording feature.
	
	recordtime = SECONDS
	
	To start the sound recording press `left_ctrl+enter'. To end
	and to save the sound press `enter'. If you press the start key
	more than one time the recording starts from the last press.
	
	The sounds are saved in the `snap' directory like the snapshot 
	images.


CONFIGURATION (suggested values)
	These are the suggested values for the new options :

	[config]
	resize = mixed
	brightness = 1.0
	video = auto
	blitrotate = auto
	bliteffect = auto
	rgbeffect = no
	skiplines = auto
	skipcolumns = auto
	depth = auto

CONFIGURATION (removed options)
	These are the options not supported in the `mame.cfg' file. 

	"vesamode", "vesa" - use `mv' instead
	"ntsc", "monitor" - use the "hclock,vclock" options instead
	"resolution" - use the "video" option instead
	"vgafreq" - use `mv' instead
	"tweak" - use `mv' instead
	"centerx", "centery" - use `mv' instead
	"stretch" - use the "resize" option instead
	"mmx" - the pentium II and k6 versions always uses the mmx,
		the pentium only if detected
	"alwayssynced" - not supported
	"waitinterlace" - not supported

