Commit graph

117 commits

Author SHA1 Message Date
ImJezze
92c2bdf917 Normalized vector attenuation settings
- vector_length_ratio is now independent from screen size
- changed vector_length_ratio range from [0.0, 1000.0] to [0.0, 1.0]
- updated display name and description of vector_length_scale vector_length_ratio
2016-05-22 20:54:30 +02:00
ImJezze
bef70746af Fixed half texel offset of 'source' shadow mask tile mode 2016-05-05 22:46:56 +02:00
ImJezze
07d8b25571 Added "selection" parameter to chain input sampler
- if specified all textures (.png) within the same directoy of the given texture will be selectable via slider in the UI
- also added slider for "shadow mask tile mode" to HLSL chain
2016-04-24 20:36:42 +02:00
ImJezze
dba12a31ad Small fixes (nw)
- fixed not used u_humbar_hertz_rate parameter
- fixed half pixel shift of the shadow mask along the screen diagonal
2016-04-22 13:16:37 +02:00
ImJezze
b1c06acb61 Implemented handling for u_screen_scale and u_screen_offset (nw) 2016-04-21 07:52:29 +02:00
ImJezze
cd4dfca43e Refactored BGFX distortion pass (nw)
- also removed vector hack
2016-04-19 21:18:16 +02:00
ImJezze
8ed3a7d94a Refactored distortion pass
- separated curvature parameter into distortion, cubic_distortion and distort_corner
- distortion and cubic_distortion can be negative, to compensate each other
- distort_corner is intependent from the image distortion
2016-04-19 21:13:20 +02:00
ImJezze
32f0e6efac Removed hacks for vector screens from shaders (nw)
- added handling of texture coordinates for vector screens to core render
- added handling of orientation/rotation for vector screens to D3D renderer
2016-04-13 19:21:57 +02:00
therealmogminer@gmail.com
a4f615a14d Get NTSC working in both bgfx and d3d, nw 2016-03-29 01:56:37 +02:00
ImJezze
fe9dfdbf99 Refactored Bloom
- reduced raster bloom level to 8
- extended vector bloom level to 15
- changed vector bloom to be less blocky
- removed bloom_lvl9_weight and bloom_lvl10_weight options
2016-03-28 20:19:01 +02:00
ImJezze
c731b59cbe Added oversampling option
- and some cleanup
2016-03-25 16:40:32 +01:00
ImJezze
b507dbb5fc Scanline Variation
- added option for scanline variation
2016-03-15 22:15:25 +01:00
ImJezze
c2d4e3c018 Cleanup (nw)
- options are reset to loaded preset when game is closed
- changed default values of options to result in no effects activated
- init_slider_list() does not returns but sets g_slider_list directly
- removed unnecessary oriented_vector_texcoords
2016-03-13 17:11:08 +01:00
ImJezze
b1a392a45f Fixed mask orientation for vector screen 2016-03-12 19:17:57 +01:00
ImJezze
4c7e845498 Fixed rotated source tile mode
- and corrected aperture texture name
2016-03-12 18:59:36 +01:00
ImJezze
7add547602 Refactoring of render targes and vector texture coordinates
- implemented proper texture coordinates for vector quad primitive
- vector screen is now processed in texture coordinates
- revered workaround for raster screen, which is again processed in
texture coordinates
- known issue: cocktail mode for vector screen looks wrong
2016-03-12 16:03:28 +01:00
ImJezze
0e76ce80de Cleanup primary.fx
- split into primary.fx into 3 techniques for vector buffer, screen and
UI pass
- moved register_texture() for shaders outside of texture_info creation
- added render_primitive parameter to register_texture(); currently
unused
- removed other unused register_texture() definition
2016-02-28 18:59:10 +01:00
ImJezze
11395616dd Bloom refactoring
- calculation of bloom dimensions is now done only once, when render
target is created
- reduced blur width for non-vector screens
- implemented shadow u/v option for source tile mode
2016-02-25 20:58:49 +01:00
ImJezze
e57c90084c Quality and Performance improvements
- HLSL now uses NPOT sized target surfaces (breaks compatibility with
graphics cards based on R300/R400/NV30 and older)
- HLSL target surfaces now have the size of the screen canvas
- removed HLSL pre-scale factor
- HLSL now uses a sharp bilinear interpolation to pre-scale textures to
screen canvas size, based on [Themaister's] implementation
- improved overall performance (based on the previously required
pre-scale factor, you might notice a 5-50% speed-up depending on your
graphics card, more if you used a higher pre-scale factor)
- improved shadow mask quality (pixel-perfect) in screen-mode
- fixed half source texel offset of bloom level alignment
- removed ./hlsl/artwork_support folder
- all shaders after pre-scale are now based on screen coordinate
(workaground, till both raster and vector pass can work on texture
coordinates)
- disabled distortion shader for more than one screen and for artworks
in full mode, does not affect artworks in copped mode (workaground, till
both raster and vector pass can work on texture coordinates)
- moved compute_texture_size() from texture_info to texture_manager (nw)
2016-02-20 21:58:56 +01:00
ImJezze
d15d53c728 Fixed Bloom Level Alignment
- fixed target dimensions of bloom levels, which results in a much
better alignment especially for game with very low resolution (therefore
current bloom settings might look a little less intense than before)
- small cleanups (nw)
2016-02-07 13:40:24 +01:00
ImJezze
f5e3032d98 Improved Scanline Simulation
- changed the amount of scanline darkness, a setting of 1.0 now becomes
fully black (to get the same result as before half your current setting)
- scanline height now depends on the brightness of the underlying color
- the amount of the scanline brightness and overdrive now depends on the
scanline darkness
- renamed 'Scanline Screen Height' to 'Scanline Screen Scale' and
'Scanline Indiv. Height' to 'Scanline Height'
2016-02-07 13:32:34 +01:00
ImJezze
8d5848718c Fixed missing const (nw) 2016-01-26 22:24:47 +01:00
ImJezze
a5fb439705 Cleanup (nw) 2016-01-26 22:14:41 +01:00
ImJezze
d516871e6f NTSC Refactoring and Options
- merged YIQ encode and decode pass into one NTSC pass
- added options for most NTSC settings
- reduced sample count to 64
- changed default O value to 0
- fit NTSC signal jitter between a reasonable limit of 0 and 1
- fit A and B value between a reasonable limit of -1 and 1
- fit scanline jitter between a reasonable limit of 0 and 1
- added hum bar simulation based on [MooglyGuy's] GLSL port of the mame
shader pipeline
- added monochrome-chessboard.png
- added slot-mask-aligned.png (to simulate a TFT LCD)
2016-01-25 22:02:24 +01:00
ImJezze
ded9493cb0 Fixed YIQ passes
- fixed half texel offset
- readded usage of A value in encode/decode pass
- readded jitter of B value in encode/decode pass
- readded usage of P value in encode pass
- fixed not set O value uniform for decode pass
- removed duplicate YIQ option definition
- changed default of O value back to 1.0
2016-01-09 16:41:53 +01:00
ImJezze
37b596b7b4 Refactored color converge
- color converge is now independent from ratio
- the radial converge now "translates" the most outer pixel as thay
would be translated by the linar converge with the same amount
- color converge is now limited to a maximum of 10
- added color converge pass to vector rendering
2016-01-09 16:15:45 +01:00
ImJezze
1cacb7d040 Refactoring (nw)
- restructured bloom level size and weight uniforms
2016-01-03 16:20:27 +01:00
ImJezze
a2c7b61daa Refactoring
- replaced shader parameters OrientationSwapXY xor RotationSwapXY by
SwapXY
- made shader parameters SourceDims, SourceRect, TargetDims, ScreenDims,
QuadDims and SwapXY available for all shaders
- color convolution, defocus and phosphor pass will now be skipped if
all influencing parameters are 0
- removed unused bloom_texture and bloom_target arrays from cache_target
class
- fixed half texel offset in prescale.fx
2015-12-31 16:59:23 +01:00
ImJezze
eea40fd0e4 Cleanup (nw)
- removed unused pincushion.fx
2015-12-31 16:32:35 +01:00
ImJezze
ff77b7897b Cleanup (nw)
- renamed shadow_mask_type to shadow_mask_tile_mode
- renamed bloom_type to bloom_blend_mode
- implemented "Source" shadow mask tile mode for artwork_support/post.fx
2015-12-26 12:27:07 +01:00
ImJezze
1b373eb812 Extended Shadow Mask and Bloom functionality
- added shadow mask type option to choose between "Screen" and "Source"
tile mode ("Screen" is the default as before)
- added bloom type option to choose between "Addition" and "Darken"
blend mode ("Addition" is the default as before)
- the alpha channel of a shadow mask is now filled with the background
color of the screen by the amount of the inverted alpha value
- added monochrome-matrix.png which can be used in combination with
"Source" tile mode and "Darken" blend mode to simulate a STN LCD, for
example
2015-12-25 20:02:47 +01:00
ImJezze
099f547d05 Fixed HLSL for LCD screen type
- fixed wrong detection of vector screen, which meant that a LCD screen
was also detected as vector screen
- re-enabled scan-line and other CRT related sliders for LCD screens
2015-12-24 14:06:01 +01:00
ImJezze
b1f1300517 Made defocus strength equal for x/y and independent from screen size
- defocus is now independent from screen size and ratio
- horizontal and vertical defocus now have the same strength
- replaced asymmetric defocus kernel by a symmetric kernel
- defocus is now limited to a maximum of 10
- added shader uniforms for orientation and rotation settings
2015-12-20 13:57:28 +01:00
ImJezze
0095c77163 Cleanup (nw)
- removed some tabs at line ends
2015-11-18 18:09:09 +01:00
ImJezze
d5c6dc78e9 Cleanup
- fixed not used HLSL settings from <custom>.ini if MAME was started
without driver parameter
- removed default values from HLSL sliders, the defaults here are more
like null values to hint when an effect would be disable
- slightly changed default HLSL settings
2015-11-18 18:01:01 +01:00
ImJezze
8be53c28f0 Changed screen adjustment for HLSL
- screen adjustment (scale, offset) can now be handled by the respective
render API itself (default behavior is as before)
- D3D (if HLSL) is activated handles screen adjustment by itself within
the shader, which fixes the odd behavior of some effects (e.g. round
corners) when screen scale and offset is used
2015-11-17 19:37:56 +01:00
ImJezze
2a3bd8b8d0 Cleanup
- removed duplicate prescale fields
- made visibility of HLSL options depending on screen type
- disabled scanlines for LCD screen type
2015-11-07 12:03:36 +01:00
ImJezze
21b577483b Cleanup
- some renamings
- reverted one unwanted change in vector.fx
2015-10-26 19:49:17 +01:00
ImJezze
0ad0e5548e Fixed Vector Intensity and Flicker
- fixed vector intensity in vector.fx
- fixed vector flicker in vector.c
- change range of vector flicker option from 0 - 100 to 0.00 - 1.00
2015-10-25 11:02:52 +01:00
ImJezze
4610935e79 Small Fixes
- fixed position of reflection effect for vector graphics
- fixed size of rounded corners
- fixed very small black border
2015-10-20 20:07:38 +02:00
ImJezze
cd7de43b13 Fixed Aspect Ratios
- fixed aspect ratios in special post.fx shader for artwork support
2015-10-19 19:03:56 +02:00
ImJezze
7eb83c31a5 Artwork Support
- added special post.fx and distortion.fx shader, which support enabled
artworks, but they cannot apply some of the previously implemented
corrections (e.g. bloom staircase artifacts when screen is curved,
elliptic rounded corners when aspect ratio is not 4:3)
2015-10-18 19:16:46 +02:00
ImJezze
2577b29602 Cleanup
- changed default values of curvature, vignetting, reflection, round
corner and smooth border to 0
- reverted compute_size_subroutine() back to non static
- removed some test code
2015-10-18 14:35:46 +02:00
ImJezze
534cd86c17 Bloom Overdrive
- added experimental bloom overdrive effect and options, this effect
allows to overdrive pure colors like red, green and blue to become more
brighter
- added lcd.ini to parse_standard_inis()
2015-10-10 17:02:51 +02:00
ImJezze
81c15decf8 Smooth Borders
- enabled smooth border effect and added option, its amount is limited
by the amount of rounded corners
- added raster.ini to parse_standard_inis()
- merged vector and raster bloom options, use vector.ini or raster.ini
to distinguish
2015-10-09 18:49:39 +02:00
ImJezze
5addcdd2da Small fixes
- fixed defocus strength with difference prescales
- removed default screen ratio of 4:3, ratio is now based on the screen
quad size
- reverted some space to tab changes
2015-10-04 15:57:07 +02:00
ImJezze
062e6e0383 Refactoring, Fixes and Cleanup
- added distortion pass, which is applied after the bloom pass
- moved vignetting, curvature, round corners and reflection effect to
distortion pass
- disabled distortion pass for multi screens and activated artworks due
to not yet fixed misalignments
- disabled scanlines for vector rendering in post pass shader
- removed prescale knowledge from downsample, bloom and post pass shader
- fixed half pixel offset in most shaders
- fixed position of reflection effect when screen is rotated or flipped
- fixed roundness of round corners in any aspect ratio
- fixed shadow mask bleeding (nearly completly)
- added bounds() and screen_bounds() getter to layout_view
- added current_view() getter to render_target
- some cleanup and refactoring
2015-09-26 18:22:51 +02:00
ImJezze
37f6ff0b65 Refactoring and Fixes
- removed position offset in post.fx
- fixed texture offset caused by 0th level of bloom.fx
- fixed texture offset caused by focus.fx
- changed Passthrough parameter in phosphor.fx to boolean
- simplified defocus pass function and calling it twice
- removed CU_PHOSPHOR_IGNORE (Passthrough) uniform, which was only used
in phosphor pass function and is now directly set
- added CU_TARGET_DIMS (TargetDims) uniform based on the current render
target
- fixed missing Prescal parameter in downsample pass function
- some code cleanup
2015-08-02 17:31:54 +02:00
ImJezze
d132946c6f Vector curvature correction
- corrected vector curvature on x-axis when screen dims and render
target dims differ (there is still a difference on y-axis)
2015-07-19 12:28:51 +02:00
ImJezze
9ce2864141 Post Pass effects for Vector rendering
- added support for post pass effects for vector rendering (does not
work properly in full screen mode, yet)
- made texture_info::compute_size_subroutine() function public static
2015-07-12 23:28:38 +02:00