Commit Graph

2513 Commits

Author SHA1 Message Date
Gregory Hainaut 8deee6afbc gsdx: include some C++11 define for later 2015-04-17 19:03:21 +02:00
Gregory Hainaut 9ce7f515bc cdvdiso: add stdcall convention 2015-04-17 18:34:05 +02:00
Gregory Hainaut 5c8ea74cb9 null plugins: add stdcall convention 2015-04-17 18:33:10 +02:00
Gregory Hainaut 75a3abc225 lilypad: add stdcall convention 2015-04-17 18:32:39 +02:00
Gregory Hainaut 8e3dab7e11 zzogl: add stdcall convention 2015-04-17 18:32:10 +02:00
Gregory Hainaut e16cb9a00e onepad: add stdcall convention 2015-04-17 18:31:44 +02:00
Gregory Hainaut c456764342 spu2x: declare exported function as stdcall
* Fix a stack buffer overflow on address sanitizer
* Might explain an old clang crash
2015-04-17 18:24:23 +02:00
Gregory Hainaut 545c1d387c gsdx: add an include for MSVC 2015-04-16 22:28:09 +02:00
Gregory Hainaut aff999cf69 gsdx linux: refresh the gui
* Use tooltip for hack
* Update string of previous hack
* Remove unused hack

Note: hack_sprite_check requires 3 states (and potentially others hack too) but
I don't know how to do it. It likely requires a "scale button"
2015-04-16 19:28:55 +02:00
Gregory Hainaut 85cbe285f0 gsdx dialog: move hack info into a separate file
This way it can be reused on linux.
2015-04-16 19:26:33 +02:00
Gregory Hainaut 670bcc1818 gsdx hack: use a dumb implementation for UserHacks_round_sprite_offset = 2
It works as bad as a "clever" implementation.

It seems to be enough for games such as venus/taisho-monoke/FFX

Note: it might creates glitches. Code will never be nice, so it is just
a trade-off
2015-04-16 19:26:33 +02:00
Gregory Hainaut 41e5be0673 gsdx hack: limit range of UserHacks_align_sprite_X
Just an extra check to avoid an overlap (avoid white line in tekken)
2015-04-16 19:26:33 +02:00
Gregory Hainaut e8698a9c0c gsdx hack: hole in vertex position also appears in !FST projection
Fix various black vertical line regression with UserHacks_align_sprite_X
2015-04-15 09:40:06 +02:00
Gregory Hainaut 65a84b9f64 gsdx hack: drop previous filtering hack
superseeded by UserHacks_round_sprite_offset
2015-04-15 09:26:01 +02:00
Gregory Hainaut 2da4a5e6bc gsdx hack: use a 0 offset instead of -1
-1 is annoying because minimum value is 0. Instead to add more logic,
let's try to use 0 which seems to be good enough (fix regressions on DQ8/AT)

Unfortunately it causes a mini regression on taisho-mononoke. Rotation of sprite is done with 2 triangles.
Potentially previous value wrongly recover this section.
2015-04-14 18:39:26 +02:00
Gregory Hainaut cde72300a5 gsdx hack: Correct formulae for reversed texture
It fixes issues on Ace Combat UI
2015-04-13 22:14:36 +02:00
Gregory Hainaut 418f2e69a8 gsdx-ogl: implement the wildhack on the GPU
Likely much faster for opengl and much easier to implement

Note: hopefully UserHacks_round_sprite_offset will replace it
2015-04-13 22:14:36 +02:00
Gregory Hainaut 50bac01d89 gsdx hack: disable upscaling hack at native resolution 2015-04-13 22:14:36 +02:00
Gregory Hainaut 815c99b6e4 gsdx-hack: remove an extra offset + duplicate linear computing
Initially code aligned texture on pixel boundary + 1/16th. It seems to work without it.
2015-04-13 22:14:36 +02:00
Gregory Hainaut 399ddbd74a gsdx hack: reduce complexity of alpha* function
It will help the compiler to make a couple of optimizations (and it will help
a futur porting to GSVector)
2015-04-13 22:14:36 +02:00
Gregory Hainaut 1d0deb5ffe gsdx hack: move round sprite offset into a separate function
Use a boolean template to separate the linear case. I'm afraid it will
cost extra computation but 90% of sprites use nearest.
2015-04-13 22:14:36 +02:00
Gregory Hainaut 1aebca3740 gsdx hack: m_userhacks_round_sprite_offset take precedence over m_userhacks_stretch_sprite
m_userhacks_stretch_sprite is only kept for debugging. Let's avoid bad mixing by users
2015-04-12 11:05:23 +02:00
Gregory Hainaut c4fef0256e gsdx hack: Better rounding fix letter in ace combat and line in tekken
Tekken is broken with setting UserHacks_round_sprite_offset = 2 use 1 instead.
=> game use upscaling internaly so my rounding of coordinate break everything

Yakuza uses float coordinate but this hack only correct the integer coordinate
=> the solution will be to add a dedicated hack for this game.

Colin3 got a regression but I don't know when...
2015-04-12 10:31:04 +02:00
Gregory Hainaut 7e89247bf4 gsdx hack: don't add extra correct for zero length texture
Otherwise t1-t0 is 16 instead of 0
2015-04-11 10:54:30 +02:00
Gregory Hainaut d2156c86eb gsdx: improve previous hack for bilinear sprite
PS2 uses a -0.5 offset before sampling so texels must be rounded to half-pixel boundary

If fixes glitches on Venus and taisho-mononoke

Note: I didn't fixed yet texture render in reverse because I don't have any test for it.
2015-04-10 09:42:39 +02:00
Gregory Hainaut f5eeb2024e gsdx: anti-glitches v3: Tester wanted
UserHacks_round_sprite_offset = 1 <= enable correction of flat sprites
UserHacks_round_sprite_offset = 2 <= enable correction of all sprites (better on a couple of dump but not sure of the consequence)

I completely redo the algorithm. This time I do the projection and
interpolation of the 2 extrem vertex. This way I can compute the min/max
valid texture coordinate.

It gives stronger guarantee that texture sampling will be done inside the texture.

However it might have a performance impact, likely reasonable because it
is limited to sprite vertex.

A big thanks you to all people that provide me GS dump and test reports.
2015-04-09 19:51:50 +02:00
Gregory Hainaut 05eb1641f2 gsdx: add glsl debug capabilities
Useful to debug bad texture sampling
2015-04-08 10:15:25 +02:00
Gregory Hainaut 98d8ad7484 gsdx: new anti-glitches upscaling hack: UserHacks_round_sprite_offset
It is replacement of the previous hack (UserHacks_stretch_sprite). Don't enable both in the same time!

The idea of the hack is to move the sprite to the pixel boundary. It
avoids most of rounding issue. It also rescales verticaly the sprite (avoid horizontal line on ace combat).
I don't like this rescaling maybe we can limit it to only 1 pixels.

On my limited testcase, results are much better with any upscaling factor.

I still have a bad line in Kingdom heart. If you have issue with others
game please provide us a GS dump.
2015-04-07 19:18:24 +02:00
avih 3077de3637 Merge pull request #496 from 3descx9/master
crc hack for Ponkotsu Roman Daikatsugeki: Bumpy Trot ( Steambot Chronicles JP)
2015-04-07 12:04:25 +03:00
ssakash defb57178f crc hack for Ponkotsu Roman Daikatsugeki: Bumpy Trot ( Steambot Chronicles JP) 2015-04-07 14:14:26 +05:30
Blyss Sarania 506648bd6b GSdx: Hacks UI: Add missing BREAK that I left out 2015-04-06 14:39:51 -05:00
Blyss Sarania c6fb098703 Add two new tick boxes and associated description
For Gregory's two new awesome hacks

Also make new hacks obey "Enable HW Hacks"
2015-04-06 13:48:59 -05:00
Gregory Hainaut 3c84e6848b gsdx: don't enable previous hack if m_upscale_multiplier <= 1 2015-04-04 01:21:46 +02:00
Gregory Hainaut 183b5d4def gsdx: improve UserHacks_align_sprite_X hack for ace combat
Game uses 1x1 texture sampling. In this condition we don't care
if texture is correctly aligned.
2015-04-03 23:00:54 +02:00
Gregory Hainaut 53ab390e72 gsdx linux: add a nice gui option for previous hack
I also added two nice tooltips :)
2015-04-03 21:25:34 +02:00
Gregory Hainaut fbaa84e691 gsdx: anti-vertical-line hack UserHacks_align_sprite_X
This ack realign sprite to full pixel coordinate

It solves vertical line in ace combat/tekken/colin mac rally
2015-04-03 21:02:25 +02:00
Gregory Hainaut e40a26be19 gsdx: add some helper to debug openGL renderer 2015-04-03 20:28:44 +02:00
Gregory Hainaut 5269e54f02 gsdx: tune previous hack
Only disable bilinear on the sprite that were forced by the user.
If the PS2 requires a bilinear filtering, there is likely a big enough texture
2015-04-03 20:09:02 +02:00
Gregory Hainaut bb728ea186 gsdx linux: filtering label was in wrong oder
The standard mode is 2
2015-04-03 20:07:50 +02:00
Gregory Hainaut d4b7410e3e gsdx linux: add a checkbox to enable easily previous hack 2015-04-03 18:33:05 +02:00
Gregory Hainaut e1a5736583 gsdx: anti-upscale-glitch hack UserHacks_SkipDraw
2x upscaling is pixel perfects. Bigger upscaling is better but not yet perfect

Feedbacks are welcomes (note it doesn't solve all upscaling issue, only wrong texture sampling)

For the history:
If you have a texture of [0;16[ texels and draws a primitive [0;16[

The formulae to sample last pixels of texture is
0.5 + (16*s-1)/(16*s) * 16
Native (s==1): 15.5 (good)
2x     (s==2): 16 (bad, outside of the texture)
4x     (s==4): 16.25 (bad, really outside of the texure))
2015-04-03 18:33:05 +02:00
Gregory Hainaut 22710d9b44 lilyPad: fix the linux crash if ini doesn't exist
All credits go to Arcum42
2015-04-03 18:33:05 +02:00
Avi Halachmi (:avih) 45e2fd9204 crc hack for Raw Danger! (Zettai Zetsumei Toshi 2 US)
thanks to ssakash for the patch
2015-03-29 15:41:06 +03:00
Gregory Hainaut 45930ecbf3 gsdx: value was wrongly overwritten
Need a lots of tests to ensure at least no regression on cache behavior

Issue #332
2015-03-17 09:39:50 +01:00
Gregory Hainaut 3b5367c5b7 Merge pull request #452 from turtleli/fix-linux-build-avx2-with-tsx-disabled
GSdx: Linux: Fix build failure on AVX2 processor with disabled TSX, enable SSE4.2, SSE4.1, SSSE3 builds
2015-03-01 17:53:21 +01:00
Jonathan Li 1222bcbf6e GSdx: Comment out TransactionScope code
The TransactionScope class is compiled but never used. Comment it out
for now.
2015-03-01 16:40:48 +00:00
Gregory Hainaut c1604c4b38 gsdx🧵 only keep std::mutex/std::condition_variable
Keep pthread for thread until std::thread is really working
2015-03-01 17:29:40 +01:00
3kinox 7f1e907616 + Correct faulty behaviour of std thread by using native posix handle.
+ This is not yet perfect. Really, this standard seems like a load of crap to me in fact...
At least it works now. Should test again when gcc 5 & new c++ libs gets out.. Until then, it will do.
2015-03-01 17:29:39 +01:00
Gregory Hainaut b68270ded1 Merge pull request #448 from PCSX2/lilypad-linux-port
Lilypad linux port
Basic support of Keyboard and Joystick

No gui to configure anything. Not well tested yet.
2015-03-01 16:52:23 +01:00
Jonathan Li 13c0e6f5ef GSdx: Explain TransactionScope changes 2015-02-28 14:21:44 +00:00
3kinox 4211d51f07 64 bits: solve various of type problems 2015-02-27 22:07:13 +01:00
Gregory Hainaut f254d44030 CDVDlinuz: fix gtk header include
It doesn't fix GTK3 build but it allows to see the real error now.
2015-02-27 10:11:38 +01:00
Jonathan Li 329953ebc3 GSdx: Linux: Enable SSE4.2, SSE4.1 and SSE3 builds 2015-02-22 11:18:23 +00:00
turtleli 9b572d2d47 GSdx: Linux: Fix AVX2 CPU build with TSX disabled
On Linux, CPUs with AVX2 instruction sets that have TSX disabled (by
microcode update or otherwise) fail to build GSdx. The __RTM__ macro is
undefined, with leads to the TSX RTM instruction set (_xbegin, _xend,
_xabort, etc.) being unavailable.

Modify the preprocessor check so that the RTM instructions are only used
if available.
2015-02-22 11:18:23 +00:00
Gregory Hainaut 330d14941f gsdx-linux: support dump mode on linux
It could be useful to analyze GS dump. Warning it consumes a lot of
disk space.
2015-02-21 13:51:06 +01:00
Gregory Hainaut 8d76586dec lilypad: fix windows build
I think lilypad used libc instead of libc++
2015-02-21 11:08:45 +01:00
Gregory Hainaut 642371996a lilypad: add joy support based on linux evdev
I wanted to play with linux interface :)

It is far from perfect but joysticks are detected. The biggest issue is the correct generation of the config file!
2015-02-21 11:08:45 +01:00
Gregory Hainaut 3a2e8f38df lilypad: removed old linux/LilyPad.cpp file 2015-02-20 23:05:21 +01:00
Gregory Hainaut 8350dc2c68 lilypad: remove debug printf 2015-02-20 23:05:21 +01:00
Gregory Hainaut 13bb1ae028 lilypad: Keep original KeyboardQueue (more ifdef)
It would be nice if windows support basic std::mutex

The reverse fifo queue is kept in Linux/KeyboardQueue.cpp
2015-02-20 23:05:21 +01:00
Gregory Hainaut 349bb810f0 lilypad: merge LilyPad.cpp (ifdef, ifdef)
Avoid duplication for linux
2015-02-20 23:05:21 +01:00
Gregory Hainaut 42b9932bd0 lilypad: add code to bind key 2015-02-20 23:05:21 +01:00
Gregory Hainaut 3096e94616 lilypad : plug a basic keyboard device
Add a reverse fifo to transfer event from core to plugin

Long story short, on linux there is only one event queue in core
2015-02-20 23:05:21 +01:00
Gregory Hainaut aec43f0bee lilypad: add x11 display pointer
If we move all window management hack into the core it would be useless (for input)
2015-02-20 23:05:21 +01:00
Gregory Hainaut 087f252909 lilypad: add plumbering config
Note: it miss interaction with any dialog
2015-02-20 23:05:21 +01:00
Gregory Hainaut 4f013a2960 lilypad: import common utility to manage config
Based work on spu2x equivalent file. Only convert the file to a CfgHelper object
2015-02-20 23:05:21 +01:00
Gregory Hainaut 156f66ef62 lilypad: make it compile on linux
* Ifdef windows code
* Add a windows crap to linux crap translation layer
2015-02-20 23:05:21 +01:00
Gregory Hainaut 3661f51bcb lilypad: minor c++ fixes
Must be checked on windows
2015-02-20 23:05:21 +01:00
Gregory Hainaut 147353a177 lilypad: add cmake file 2015-02-20 23:05:21 +01:00
Gregory Hainaut 76ff56a4e3 lilypad: add a linux fork
Yes it is bad!
2015-02-20 23:05:21 +01:00
Gregory Hainaut 1655055f61 onepad: update old comment 2015-02-20 23:05:21 +01:00
Gregory Hainaut e0f56282de cmake: no preferred-stack-option in asan
It conflicts with the global definition

I don't remember why this option was set on GSdx. Potentially it could be dropped (or fixed correctly)

Anyway, it will help to enable Address Sanitizer on Linux Build
2015-02-20 19:44:51 +01:00
TheLastRar 80b24f8055 Fix warped read code 2015-01-27 15:16:06 +00:00
Gregory Hainaut 0bdeb8d411 Merge pull request #430 from PCSX2/win-ocl-crash-fix
gsdx ocl: check size of array before access
2015-01-17 12:05:52 +01:00
Gregory Hainaut 6bb945f6c8 Merge pull request #428 from pgert/master
Case Mapping & GitHub instead of GoogleCode.
2015-01-16 21:25:36 +01:00
Gregory Hainaut 70ad09f6ef gsdx ocl: check size of array before access
Potential fix for issue #408 ?
2015-01-16 09:39:50 +01:00
pgert ad8e800aa5 Update Cfg.c 2015-01-12 13:27:09 +01:00
uyjulian 446977d126 GSdx forward compatible bit 2015-01-09 19:39:59 -06:00
Miguel A. Colón Vélez c8c22cf6a0 Notify about cross build option upon failure.
Tell the user to use CMAKE_TOOLCHAIN_FILE upon failure.
.
Cleanup detectOperatingSystem. Should be the same but adding
GNU and kFreeBSD from Debian and filtering out pre OS X Apple.
.
libaio is linux only. Also check for the correct header since
aio.h is the POSIX one. Both are in /usr/include/ anyway.
Only build core if (Linux AND NOT AIO_FOUND) == false.
.
Use Unix for GTK and X11. Macs has gtk-quartzs and xquartz or native X11.
*BSD, linux, etc should have both.
2015-01-03 14:51:04 +01:00
Gregory Hainaut ee34bd724f gsdx ocl: avoid a crash if ocl is selected but not enabled 2014-12-23 19:39:02 +01:00
Gregory Hainaut 767b841fea gsdx ocl: disable it on windows
Until we found a way to fix a couple of crashes
2014-12-22 19:02:35 +01:00
Gregory Hainaut 66d7aa75e2 cmake: move -DNDEBUG to global option 2014-12-20 13:43:25 +01:00
Gregory Hainaut a99f3ea321 cmake: remove duplicate flags
also use the lighter elseif structure to reduce a bit the size of cmakefile
2014-12-20 13:43:25 +01:00
Gregory Hainaut 4773bcf0ea cmake: s/_LINUX/__linux__/ 2014-12-20 10:54:24 +01:00
Gregory Hainaut 4f957feacd onepad: use union instead of stange cast
Nicer this way. Beside it removes the strict aliasing issue.
2014-12-20 10:54:18 +01:00
Gregory Hainaut 43e854fece spu2x: remove duplicated function 2014-12-20 10:54:18 +01:00
Gregory Hainaut ff24a5f702 gsdx linux: disable std::thread
Threads are not killed properly therefore GS crashes on reloading (aka F9)

See issue #392
2014-12-14 12:22:40 +01:00
Gregory Hainaut b9297c6158 Merge pull request #377 from PCSX2/tlb_goemon_v2
goemon gamefix improvement
2014-12-14 11:47:37 +01:00
Gregory Hainaut 63ba78b664 remove zzogl-pg-cg
superseeded by zzogl-pg
2014-12-13 12:28:37 +01:00
Gregory Hainaut 7d21497c11 clang: no support of f-abi-version=6 option 2014-12-13 12:28:37 +01:00
Gregory Hainaut 18405e2598 gsdx: add goemon comment on some assertion
If someone want to trigger them
2014-12-12 22:31:31 +01:00
Gregory Hainaut cebccea81c gsdx: disable some gl extensions when VMware driver is detected
It is likely the Mesa driver, code seems to have the same issue (separate shader)
2014-12-12 20:44:58 +01:00
Gregory Hainaut 35f26f00bc Merge pull request #386 from PCSX2/remove-tls
spu2x:zzogl: disable TLS
2014-12-11 09:55:17 +01:00
Gregory Hainaut 3d071e50ad gtk3: gtk_hscale_new_with_range => gtk_scale_new_with_range 2014-12-10 22:09:21 +01:00
Gregory Hainaut 5d8b2d8044 gtk2: GtkNotebookPage is useless
And not supported by gtk3
2014-12-10 22:09:21 +01:00
Gregory Hainaut e9233f4698 gtk2: use text rather than image
Require by GTK3
2014-12-10 22:09:21 +01:00
Gregory Hainaut 7fb548d7c5 gtk2: GTK_OBJECT is useless 2014-12-10 22:09:21 +01:00
Gregory Hainaut d1389db2f4 gtk2: keyboard macro update 2014-12-10 22:09:21 +01:00
Gregory Hainaut ba9e998ff5 gtk2: port gtk_combo_box to gtk_combo_box_text
The former was deprecated on gtk2.24 (and removed from gtk3)
2014-12-10 22:09:21 +01:00
Gregory Hainaut a52f598369 spu2x:zzogl: disable TLS
builds an Utilies_NO_TLS.a archive of the common Utilities code. It replaces native TLS by a slower reimplementation

Rational: number of TLS slot is very limited by the GLIBc on linux. I hope it doesn't impact performance.
* Zzogl don't requires TLS AFAIK
* spu2x will likely use it for assertions only.

TLS exhaustion creates issue to dlopen plugins
    issue #384 : https://github.com/PCSX2/pcsx2/issues/384

But also for profiled build (-fprofile-generate)
    http://forums.pcsx2.net/Thread-WORKAROUND-build-with-fprofile-generate

If someone have a better idea, please raise your hand!
2014-12-08 22:26:46 +01:00
Gregory Hainaut 0a4f9e43d9 cmake: clean sdl management
* sdl is mandatory for spu2x
* cmake will include either /usr/include/SDL or /usr/include/SDL2 so no
  need to add extra ifdef
2014-12-07 21:06:21 +01:00
Gregory Hainaut 29a14f5667 sed -i -e 's/seperately/separately/'
Thanks micove again
2014-12-07 12:46:16 +01:00
Gregory Hainaut c945aead54 cmake: better support of SDL2
Description: Building with SDL2_API=TRUE is incomplete
 SDL_FOUND does not imply SDL2_FOUND
 Use check_libs for detection
 Only include ${SDL_INCLUDE_DIR} when needed
 Use SDL2_LIBRARIES
Author: Miguel A. Colón Vélez

Gregory: add back SDL_BUILDING_LIBRARY
2014-12-07 12:19:14 +01:00
Gregory Hainaut 16284d0a59 gsdx: fix a couple of typo
From @micove
2014-12-07 12:12:53 +01:00
Gregory Hainaut 070dce4c83 Merge pull request #356 from PCSX2/issue-fixes
various bug-tracker fixes
2014-12-06 19:48:13 +01:00
Gregory Hainaut 1f5fe7a1db Merge pull request #348 from 3kinox/master
GSdx-ogl linux: std::thread
2014-12-02 22:43:29 +01:00
Gregory Hainaut 4238261784 gsdx-cl: update linux menu config
Try to use some id to be more robust

The best will be to sort the array first
2014-12-02 00:16:35 +01:00
Gregory Hainaut 76f719e5d0 gsdx-ocl: Add a ENABLE_OPENCL option
* Allow to compile GSdx on linux without opencl yet.
2014-12-02 00:16:35 +01:00
gabest11 b9b02cf749 implemented opencl program caching on disk under the system default temp folder, needs some additional work on linux 2014-12-02 00:16:35 +01:00
gabest11 7b466a98d0 replaced opencl.def with dynamic dll loading, god bless search and replace 2014-12-02 00:16:35 +01:00
gabest11 e3ba15de94 opencl device selection in settings dialog 2014-12-02 00:16:34 +01:00
gabest11 6f5cd1cd4d joined some tfx kernel calls, general speed up in most games 2014-12-02 00:16:34 +01:00
gabest11 3d2b0e3766 minor opencl kernel optimizations 2014-12-02 00:16:34 +01:00
gabest11 72cfc6a6ef 3rdparty/opencl 2014-12-02 00:16:34 +01:00
gabest11 9e20387595 Modified for opencl 1.1. While it runs on nvidia cards now, you can't use its sdk to compile gsdx, cl.hpp is missing there. Intel or amd is ok. 2014-12-02 00:16:34 +01:00
gabest11 263c097d13 solution for 32-bit z values in opencl and other minor optimizations 2014-12-02 00:16:34 +01:00
gabest11 c64f9ad9b1 squishing opencl bugs, there aren't many left hopefully 2014-12-02 00:16:34 +01:00
gabest11 ba1e522bbb Less opencl bugs, some games are actually playable now, there are still texture errors. 2014-12-02 00:16:34 +01:00
gabest11 881735b562 minor merging errors 2014-12-02 00:16:33 +01:00
gabest11 db7c26cde7 - Experimental OpenCL renderer (missing features: point, line, texture cache, mipmap, aa1, device selection). Needs any OpenCL SDK for the common headers and stub lib to compile, tested with AMD and Intel. Too bad it is not part of the Windows SDK yet.
- Renumbered renderer ids, compatible with old numbering, but it does not follow the mod3 logic anymore.
2014-12-02 00:16:33 +01:00
Gregory Hainaut 1b555ea3b5 gsdx-linux: Fix GSdx internal counter on linux
The issue is that clock gives the total cpu time of the process whereas
we want the cpu time of the rendering thread
2014-11-24 23:44:32 +01:00
3kinox 732cbc3ad5 GSDX-ogl linux:
+ Implement threads/mutex using std::thread/std::mutex/std::condition_variable
+ Old implementation can be used by commenting out the "define _STD_THREAD_ in GSThread.h
+ Commit should be much cleaner than previous one.
2014-11-23 14:33:35 +01:00
Gregory Hainaut 60c0eb7179 gsdx-ogl: windows: properly setup context flags
* Use a core profile context
* Only enable the debug context in debug build

Close issue #353
2014-11-20 22:12:30 +01:00
Gregory Hainaut d21e6ff45f gsdx-ogl: don't declare a sampler variable
Nvidia was complaining on the fxaa shader. In doubt I also replaced it in Asmodean's shader
2014-11-20 22:07:44 +01:00
Asmodean- 8f42b36a42 It might help if I changed this for d3d9 also :p 2014-11-15 21:40:00 +00:00
Asmodean- 5b3867dd60 GSdx: change post-processing directory & name. 2014-11-15 21:33:23 +00:00
Gregory Hainaut 276e3d9d1b gsdx-ogl: always set texture parameter
* Avoid bug after a pause
* Not faster anyway
* keep old method only for gl retracer to reduce debugging noise

Remove some old&useless comment
2014-11-14 11:43:42 +01:00
Gregory Hainaut 3311336d0e gsdx-ogl: disable ARB_bindless_texture
I have a crash when I try to delete some texture (for example when the simulator is paused)
2014-11-11 23:45:41 +01:00
Gregory Hainaut b6a951a9fa gsdx: debug compilation fix
I'm not sure gcc behavior is correct here!
2014-11-11 20:54:34 +01:00
Gregory Hainaut 0ca9bab8b6 Merge pull request #344 from Asmodean-/master
[GSdx] OpenGL PP Updates
2014-11-11 16:14:01 +01:00
Gregory Hainaut ab4eaea757 Merge pull request #346 from 3kinox/master
Linux : GSdx AVX fix
2014-11-11 16:08:23 +01:00
3kinox 06f53b2689 use -fabi_version=6 only for GSdx, solve bug with wxwidget
reenable avx build for GSdx
2014-11-11 15:55:31 +01:00
Gregory Hainaut e73d8f383b gsdx-ogl: compilation fix for old distribution 2014-11-11 15:01:22 +01:00
Kieran Hanrahan b60e5a62fc Rearrange to right spot (I blame github editor ;p) 2014-11-11 00:17:21 +00:00
Kieran Hanrahan 7adc7c4833 Update GSSettingsDlg.cpp
Just add the OGL shader ini params to the file when the user enables post-processing In the options dialog.
2014-11-11 00:01:31 +00:00
Gregory Hainaut e6e534c13a Merge pull request #343 from PCSX2/shader-loading
GSdx ogl: external shader loading + FXAA
2014-11-10 15:43:05 +01:00
Gregory Hainaut 48b3d91768 partially revert previous commit ec1da2805c
It breaks windows...
2014-11-10 12:19:30 +01:00
Gregory Hainaut 8c90e7cafc gsdx-ogl: support latest fxaa version
Only tested on Nvidia, please report any issue with your driver

Note: requires GL4 GPU
2014-11-10 10:39:55 +01:00
Gregory Hainaut ff39dffe23 gsdx-ogl: add a gui option (linux) to select external shader
Note: of course it requires a glsl shader ;)

On windows, you can set the path on the ini file. Here an example with linux path:
shaderfx_conf = /home/gregory/playstation/emulateur/pcsx2_merge/bin/GSdx_FX_Settings.ini
shaderfx_glsl = /home/gregory/playstation/emulateur/pcsx2_merge/bin/shader.fx
2014-11-10 10:38:52 +01:00
Gregory Hainaut 920ac6695f gsdx-ogl: add preliminary support of external shader fx 2014-11-10 10:37:58 +01:00
Gregory Hainaut ec1da2805c pcsx2/GSdx: disable AVX for the moment on linux
I need to check carefully the consequence of ABI change. So far wx is very unhappy!

Fatal Error: Mismatch between the program and library build versions detected.
The library used 2.8 (no debug,Unicode,compiler with C++ ABI 1002,wx containers,compatible with 2.6),
and your program used 2.8 (no debug,Unicode,compiler with C++ ABI 1006,wx containers,compatible with 2.6).
2014-11-09 15:45:54 +01:00
Gregory Hainaut 84f844767c gsdx-ogl: micro optimize PSConstantBuffer cache
Might help to save a cache line on the CPU :)
2014-11-08 21:39:17 +01:00
Gregory Hainaut 58bd645d49 gsdx-ogl: BindBufferBase also bind to the generic binding point 2014-11-08 21:39:13 +01:00
Gregory Hainaut 16377f7249 gsdx-ogl: only call PixelStorei when parameters are updated
It won't improve performance but it would reduce a bit the noise in gl retracer tool
2014-11-08 21:30:14 +01:00
Gregory Hainaut 47f40ed79a gsdx-ogl: reduce pbo complexity
Copy the full line into the pbo. Dma will only take GL_UNPACK_ROW_LENGTH
- increase memcpy size by 2 in the pbo
+ single memcpy will be faster and can use sse

Enable buffer_storage extension:
* GL_CLIENT_STORAGE_BIT was required (it is the duty of TexSubImage to copy data into the GPU mem)
* Enable the extension by default
2014-11-08 21:30:14 +01:00
Gregory Hainaut e62af05496 gsdx-ogl: reduce complexity of clear texture
Null is equivalent to a clear to 0.

Note: Code is not yet used because both stencil and depth are cleared.
Future note: stencil can potentially be replaced by load_store_image
2014-11-08 21:30:14 +01:00
Gregory Hainaut bd9df9a6ec gsdx: Add some comment on GSTextureCache + schematics
Note: docs/TextureCache.odg was created with libreoffice. Not perfect but give a nice overview
2014-11-08 21:30:14 +01:00
ramapcsx2 b7e5e41afe Merge pull request #333 from PCSX2/linux-avx
Support of AVX build for linux
2014-11-08 14:09:06 +01:00
ramapcsx2 8434d6c397 Merge pull request #328 from tlbjr/master
GLDEBUGPROC type cast and postBuild.cmd for GSdx on VS2013
2014-11-08 13:11:07 +01:00
Asmodean df0a9c4683 Some small fixes, that I noticed. 2014-11-06 10:56:33 +00:00
Asmodean 937e475169 [Post-Processing] Update GSdx FX effect suite to latest version. 2014-11-03 07:15:34 +00:00
Gregory Hainaut f25e056914 gsdx: enable AVX with GCC
* Use overloaded function instead of specialized template
=> see http://stackoverflow.com/questions/3052579/explicit-specialization-in-non-namespace-scope

* replace _mm256_slli_si128 by _mm256_slli_si256
  I hope they're equivalent. I didn't find any info on _mm256_slli_si128,
  however srl use _mm256_srli_si256
2014-10-26 14:47:35 +01:00
Gregory Hainaut 679fa65b84 cmake: By default optimize for current arch
Note: it requires GCC 4.7. Otherwise use -DDISABLE_ADVANCE_SIMD=OFF to restore
previous behavior. It will impact Ubuntu precise (12.04)
2014-10-26 14:47:35 +01:00
Tom Burnett a1a1c7d0fb Removed svn rev inc file 2014-10-12 01:43:30 -07:00
Tom Burnett 1f734a69a0 Small VS2013 fixes 2014-10-12 01:40:40 -07:00
Gregory Hainaut fa3db52cf7 partially revert commit 9fd2f3dd8a
No need to add Linux sillyness in Windows file... (Hopefully close #323)
2014-10-04 11:33:34 +02:00
Gregory Hainaut 6fe9ee387d gsdx-ogl: optimize the PS cb cache
* Don't use the stack
* Don't compare MinMax parameter (depends of others)
* Don't store not-compared parameter in the cache (HalfTexel/MinMax)

+0.3fps/46fps (well better than nothing)
2014-10-02 20:44:22 +02:00
Gregory Hainaut a573ce185c gsdx-ogl: mark GL_EXT_shader_io_blocks as mandatory for GLES 2014-10-02 20:44:22 +02:00
Gregory Hainaut ccc1137e12 gsdx-ogl: merge the two vertex buffer format
* Only a single VAO
    => Format is set once
    => Only a single bind at startup
    => GSVertexBufferStateOGL is nearly useless
    => barely faster but better than nothing :)
2014-10-02 20:44:22 +02:00
Gregory Hainaut 10c7be8c50 gsdx-ogl: Use 32B strides for all VBO 2014-10-02 20:44:22 +02:00
Gregory Hainaut d37cc8e1e7 gsdx-ogl: GL_ARB_shading_language_420pack is now mandatory
All API/drivers support it so time to remove the fallback.
2014-10-02 20:44:22 +02:00
Adam Hirst b98e53e059 Minor spelling/punctuation fixes in SPU2-X 2014-10-02 12:35:13 +02:00
Gregory Hainaut 79e8a912cd gsdx-ogl: keep the draw buffer enabled by default
Note: Only DATE requires to disable the draw buffer
2014-09-30 22:18:20 +02:00
Gregory Hainaut f46e8cc6ac gsdx-ogl: bump base requirement to 3.3
A couple of fallbacks were introduced for the Mesa driver that only support 3.0
DSA will require a recent Mesa which already support GL3.3

Require at least SandyBridge for Intel GPU
2014-09-30 22:18:20 +02:00
Gregory Hainaut 594f6c33a2 gsdx-ogl-ES: require GL_EXT_shader_io_blocks + GLES3.1
Allow to use same shader interface for all API

Note: on the GL API it will require GL3.3 (see next commit)
2014-09-30 22:18:01 +02:00
Gregory Hainaut 1c501047f5 gsdx-ogl: refresh the linux gui with latest extension 2014-09-28 12:23:44 +02:00
Gregory Hainaut 8833afc2fa gsdx-ogl: drop GL_ARB_multi_bind
It will be replaced by DSA so let's reduce the complexity of opengl
2014-09-28 12:23:44 +02:00
Gregory Hainaut fa43018d10 gsdx-ogl: no DSA isn't mandatory yet... 2014-09-28 12:11:22 +02:00
Gregory Hainaut 1e86e3cb08 gsdx-ogl: rework callback debug
* use DebugOutputToFile as a callback of gl error. Add a breakpoint to
  find the culprit GL call
* use string instead of char[n]

Note: CheckDebugLog is potentially useless now
2014-09-28 12:00:34 +02:00
Gregory Hainaut b7601a9add gsdx-ogl: Enable various GL4+ extensions
* GL_ARB_clip_control: reduce z fighting
* GL_ARB_clear_texture: no real speed gain (but improve code quality)
* GL_ARB_bindless_texture: +1fps (if you're CPU limited)
2014-09-28 12:00:34 +02:00
Gregory Hainaut 9d8d702aa6 gsdx-ogl: drop GL_NV_depth_clamp extension
superseeded by GL_ARB_clip_control
2014-09-28 12:00:34 +02:00
Gregory Hainaut 4659184cc1 gsdx-ogl: add support of clip_control (depth only)
* replace the [-1;1] depth range of openGL with the DX range [0;1].
2014-09-28 12:00:34 +02:00
Gregory Hainaut 104688e3ee gsdx-ogl: fix ARB_bindless support 2014-09-28 12:00:34 +02:00
Gregory Hainaut cc24da128c gsdx-ogl: fix for gl_clear_texture
Note: Disabled for depth_stencil texture (I'm not sure we can split the two)
2014-09-28 12:00:34 +02:00
Gregory Hainaut d720cc16a6 gsdx-ogl: gl4.5: add plumbering to support direct_state_access and clip_control 2014-09-28 12:00:33 +02:00
Gregory Hainaut 5b3f031654 cmake: fix commit f3a50a01a7
* link common with c lib (required for gold linker)
* fix the macro to properly set the library variable
  => use the variable instead to hardcoded value
2014-09-24 09:02:56 +02:00
Gregory Hainaut 58a8683d7d gsdx-ogl: disable texture compare mode
It seems to be used for depth texture
2014-09-22 09:27:34 +02:00
Gregory Hainaut d51f008c72 gsdx: openglES fix
* require a 3.1 context
* unattach texture of the fbo when they're not used
(avoid to have a texture and depth_stencil with different size)

Note: except minor shader bug it works on Nvidia 340.23.01
2014-09-22 09:27:31 +02:00
Johannes Obermayr 9fd2f3dd8a Don't use build date on openSUSE.
Fixes RPMLINT warning:
pcsx2.i586: W: file-contains-date-and-time /usr/bin/pcsx2
Your file uses  __DATE and __TIME__ this causes the package to rebuild when not needed
2014-09-17 22:37:34 +02:00
Johannes Obermayr 7b1d3ba7ea Do commits 2bc2047 and f287754 the right way ... 2014-09-16 19:11:11 +02:00
Johannes Obermayr 2bc2047770 cmake: Fix RPATH/RUNPATH issue with openSuse wxWidgets libdir.
Gregory: Add an if clause to only change the rpath on openSuse

For me it doesn't follow the FHS => http://www.tldp.org/HOWTO/HighQuality-Apps-HOWTO/fhs.html
2014-09-14 13:12:26 +02:00
ramapcsx2 98d22f8b2e Merge pull request #215 from xsacha/memcpy
Remove some slow, redundant memcpy implementations: memcpy_const/memcpy_...
2014-09-12 19:57:57 +02:00
Gregory Hainaut 2d4b6273f0 Merge pull request #276 from xsacha/defs-cleanup
pcsx2: require C99 standard for stdint
2014-09-12 19:24:08 +02:00
uyjulian f3a50a01a7 cmake: Use previous macros in CMakeLists.txt files
Gregory: add a c lib for zzogl-pg-cg replayer
2014-09-05 20:16:23 +02:00
Sacha 1d116cc23b Remove memcpy_amd usages from plugins. No more custom implementations in plugins. 2014-08-27 13:50:55 +10:00
Sacha ad3b76c4d8 Remove all custom memcpy usage from core pcsx2 and remove memcpy_fast from plugins. 2014-08-27 13:45:23 +10:00
Sacha 90e59b2704 Clean up the type defines in pcsx2.
The non-stdint fallback was not even working which shows that it was never used. No supported platform would not have stdint anyway.
Remove unused code and do not restrict types to Linux and MSVC. Was there a reason for this?
2014-08-25 16:16:34 +10:00
Matteo Beniamino 15c487e547 GSdx: fixed use of separate shader objects for Intel driver. 2014-08-23 17:09:38 +02:00
Sacha f542c7232e Use __builtin_unreachable where possible for non-msvc 2014-08-15 14:43:52 +10:00
Sacha 7568f6f2ec Remove deprecated jASSUME from pcsx2 core. It is still used in some plugins 2014-08-15 14:32:56 +10:00
David Quintana 1facc8efbc Merge pull request #225 from lioncash/ghz-macro
cdvdGigaherz: Remove an unnecessary macro
2014-08-15 02:10:32 +02:00
Lioncash b2d8e7137f cdvdGigaherz: Remove an unnecessary macro define 2014-08-14 20:07:10 -04:00
Pseudonym cb2593f2bb Merge pull request #210 from xsacha:plugin_cleanup
Some cleanup to improve readability.
2014-08-14 20:37:41 +01:00
Pseudonym 66765d827b Merged pull request #199 from xsacha/oldcode
Remove some horrible old code.
2014-08-14 19:12:19 +01:00
Sacha 2ae3dd970a Fix case of 'soundtouch' instead of creating a symlink as a workaround. 2014-08-13 18:54:31 +10:00
Sacha a3bc6a73a3 Remove some horrible old code.
Remove an assert define and instead use the static_assert that all compilers provide.
As an added bonus, assert messages\!
2014-08-13 13:55:32 +10:00
Sacha 9dcaaedf06 Some cleanup to improve readability.
Remove old compiler hacks that are no longer needed.
Fix up some spacing and comments that hid code.
Fix a critical bug in deprecated plugin peopsSPU.
2014-08-13 13:05:33 +10:00
bositman 77599bec1c Added Lord of the Rings The Two Towers (IT) CRC
As seen here (SLES 51255):
http://forums.pcsx2.net/Thread-GSdx?pid=392166#pid392166
2014-08-07 13:01:54 +03:00
Gregory Hainaut a5f54b5ec1 Merge pull request #185 from lioncash/leak
zzogl: Fix a few missing fcloses
2014-08-07 09:08:17 +02:00
Ryan Houdek 3d37a6ce27 Removes the usage of __LINUX__ define
This is defined and set it a ton of different places.
It's checked in a whole lot more
Instead just use __linux__ like a real project should
2014-08-03 13:20:36 -05:00