Commit Graph

2925 Commits

Author SHA1 Message Date
Ceylo
82c2f4c05e All mobile-compatible examples now successfully link 2019-01-19 01:29:12 +01:00
=
b516a3ae2b Fix travis android build to use NDK version r18b 2019-01-18 16:20:56 +00:00
hobby8
7e40f80f52 Fix OpenGL extensions not loading 2019-01-15 23:55:31 +01:00
=
53d8f66d43 Add travis android builds 2019-01-15 20:23:19 +01:00
=
195f5d7409 Removed old android cmake toolchain 2019-01-09 15:22:49 +00:00
EpicCoder
489482a630 Updated the copyright year to 2019 2019-01-08 08:53:33 +01:00
binary1248
ae337952a9
Allow creation of a window without an OpenGL context in order to support use cases where the user wants to render using other graphics APIs. 2019-01-05 23:22:08 +01:00
binary1248
04131e1607 Fixed EGL incorrectly being passed the anti-aliasing level as EGL_SAMPLE_BUFFERS instead of EGL_SAMPLES. Fixes #1533. 2019-01-05 00:54:37 +01:00
binary1248
db80f6a60f
Make sure setActive(false) is called before the surface is destroyed in EglContext. Fixes #1530. 2018-12-29 13:36:01 +01:00
Jonny
b9fdaf487f Add static builds to travis build matrix and give all jobs names 2018-12-08 10:14:49 +00:00
=
1bf3ae77b9 Use Travis for windows builds 2018-12-04 10:11:16 +00:00
Elias Daler
b81de898bf Modify install rpath only if BUILD_SHARED_LIBS is ON 2018-12-03 19:39:19 +01:00
Elias Daler
fbc0f17198 Fix RPATH for installed examples on Linux 2018-12-03 19:39:19 +01:00
cosiek
077af21f37 allow for closing sound files 2018-12-03 19:27:53 +01:00
Dmitry Marakasov
119195ac20 Remove unneeded cast 2018-12-03 18:41:22 +01:00
Lukas Dürrenberger
2be4e54d4a
Fixed example documentation to match the code 2018-11-25 17:23:25 +01:00
Jonny Paton
1159ac5c52 Initial travis and Appveyor configs 2018-11-17 19:35:01 +01:00
Sven Hesse
de0ba77d3b Unix: Filter X visual by X screen
On an X set-up with multiple monitors running separate X screens (as
opposed to merging them into one large X screen using Xinerama), the
selected X visual needs to be one for the screen where the colormap,
window, and other X resources are created. In fact, all these need to
match, and the GL context as well.

Most of the SFML windowing and graphics code uses (X)DefaultScreen()
for that, which is fine. Combined with XOpenDisplay(NULL), this will
create the window on the screen (and monitor) selected by the DISPLAY
enviroment variable. :0.0 will be the first monitor, :0.1 the second,
etc.

However, XGetVisualInfo() will return visuals for *all* screens, not
just the default one. They seem to be ordered by screen number, but I
don't think the standard makes any guarantees there.

If the visual doesn't match up with the screen, this will abort with
an X error. BadMatch, in many cases.

This means that in addition to other filtering,
GlxContext::selectBestVisual() needs to filter the visuals by screen
number, otherwise SFML won't work at all on any screens but the first.

This fixes issue #724.
2018-10-26 21:15:25 +02:00
binary1248
ac98be760b Allow re-creation of the shared context as a core context if the user indicates they want a core profile context. Sharing of compatibility and core profile contexts is not possible on macOS which is why we need to have a way to re-create the shared context as a core context if required in this case. 2018-10-23 21:54:36 +02:00
Lukas Dürrenberger
3f4bc3683b Updated the changelog and version number for 2.5.1 2018-10-15 21:52:40 +02:00
Jonny Paton
d1d788fcb3 Add -ObjC flag to fix static linking on macOS 2018-10-15 21:07:54 +02:00
Lukas Dürrenberger
ae0ec9d552 Disabled the JNI part due to compatibility issues 2018-10-11 21:57:12 +02:00
Maxime Alvarez
a5d45b910f Fixed the error message when the wrong bitmap font size is selected 2018-10-04 22:25:11 +02:00
Lukas Dürrenberger
3aa156c278 Fixed Windows cursor color conversion to be endian safe 2018-10-01 22:42:57 +02:00
binary1248
8554d210df Ensure the proper default framebuffer is bound when activating a RenderWindow. Fixes #1471. 2018-10-01 20:33:59 +02:00
Mario Liebisch
5e10e1f0c9 Windows: Fixed swapped colors for custom cursors
Previously the red and blue color channels were swapped,
since Windows expects a different channel order for DIBs.

This fixes issue #1464.
2018-09-08 19:04:39 +02:00
Bloodsword
46ce05cd9c Use XRRSetCrtcConfig instead of XRRSetScreenConfig, in order to fix issue #1226. It should also fix issue #1224. 2018-09-08 18:56:00 +02:00
Christian Widmer
87aaa9e145 Window/Unix: Fix compilation with glxext header versions >=20180525
When mesa updated their headers, they changed the include guard
from __glxext_h_ to __glx_glxext_h_, which breaks compilation
due to conflicting declarations. This commit modifies the preprocessor
directives to allow for compilation with older and newer mesa header
versions.
Fixes: #1472
2018-08-28 20:36:08 +02:00
Jeff
be3556d76a Fix Deadlock in Android Main Cleanup 2018-08-28 20:24:34 +02:00
Jonny Paton
2bba983f1d Disable autocorrect on iOS for issue #1473 2018-08-27 23:16:21 +02:00
Marco Antognini
aeca3dce41 Improved macOS implementation for Cursor
- remove Wait and SizeAll cursors as they don't look nice
   (Wait is not spining and produces a broken rendering,
    SizeAll is a simple white cursor.)
 - fix memory management for NSCursor.
 - ignore selector warnings.
2018-08-27 21:42:59 +02:00
Jonny Paton
0bcb2992a7 Implemented extra cursors on macOS 2018-08-27 21:42:59 +02:00
Jonny Paton
1cd7ad6a24 Remove reference to unused CMAKE_OSX_DEPLOYMENT_TARGET in cocoa example 2018-08-27 13:36:57 +01:00
Elias Daler
83d05ea822 Fix CMP0072 CMake warning - also allow user to set OpenGL_GL_PREFERENCE 2018-08-14 21:21:01 +02:00
Kwasior
43f0292cb8
Fix audio components linking order 2018-08-14 14:59:57 +02:00
Jonny Paton
e3c65090ea Removed unnecessary cmake osx deployment target value 2018-08-13 23:05:21 +02:00
Lukas Dürrenberger
9712bb1ec8 Fixed the installation of pkg-config files
* Removed duplicated CMake code
* Made it possible to manually specify the pkg-config path
* Install pkg-config files by default on Linux and BSD systems
2018-08-13 22:46:20 +02:00
PKEuS
ff87e1c922 Reduced context locking&unlocking while creating textures 2018-08-13 22:30:44 +02:00
Radek Dutkiewicz
f4f7ef0d70 Fixed glyph cropping on sub-pixel positioning of text
Added 1 pixel padding for glyph uv's  and increased glyph quads boundaries by 1 pixel so the glyphs aren't cropped when text is being scrolled with sub-pixel increments
2018-08-09 23:25:39 +02:00
Mario Liebisch
dc0dfd601a
Squash duplicated sf::Font glyphs to single chars
Before this change, `sf::Font` always rendered/provided one character
per Unicode codepoint, even if that character wasn't represented by the
current font file or duplicated. This caused more texture space to be
used than necessary, which is especially apparent, when trying to render
a large amount of unhandled glyphs (the texture would literally fill up
with empty squares representing missing characters).
2018-08-03 09:58:26 +02:00
assematt
bcb013b45b Fixed bug in sf::Text when applying an outline color/thickness
When applying an outline thickness to sf::Text in combination with a
strikethrough and/or an underlined style, the ensureGeometryUpdate
function adds unwanted vertices if the string contains two consecutive
'\n' charecter.
To fix this we need to add an additional check in the if statements to
check if both the current and previous character it's a new line
character.
2018-07-29 00:48:28 +02:00
Ironbell
44d3e26766 Fixed two conversion warnings (C4267) 2018-07-28 20:00:30 +02:00
Jonny Paton
ac38b17827 Fix config for finding dependencies on iOS 2018-07-28 18:30:25 +02:00
Ceylo
8d96976e4b On iOS, make sure to be notified if you forgot to include <SFML/Main.hpp> 2018-07-28 18:27:37 +02:00
Jonny Paton
bc570b22bf Use default supported rotations when none are specified 2018-07-28 18:22:16 +02:00
Lionel Aimerie (Pixium Digital)
2853b6b629 ANDROID flag fix to SFML_SYSTEM_ANDROID 2018-07-28 18:10:04 +02:00
Bruno Van de Velde
f22b9b7b71 ANativeActivity_onCreate is not exported in sfml-main (fixes #1457) 2018-07-27 20:13:07 +02:00
binary1248
235abae134 Fixed the Unix clipboard implementation causing an abort due to internal data races in Xlib. 2018-07-02 22:39:54 +02:00
Lukas Dürrenberger
b97a5be615 Fixed performance issue with reading WAV files
Calling tell() and thus std::ftell() for every reading iteration ate up
80-90% of the whole read call. By manually tracking the current position
the calls to tell() can be safely removed.
2018-06-10 22:29:46 +02:00
Ceylo
ff011dc51d Modernize iOS toolchain: remove BUILD_ARM64, drop support for Xcode <4.3 and don't pretend defining official CMake variables 2018-06-04 23:22:21 +02:00