sfml.js 0.0.1-preview.9 → 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +56 -7
- package/binding.gyp +118 -17
- package/index.d.ts +1 -0
- package/lib/clock.d.ts +2 -4
- package/lib/clock.js +3 -1
- package/lib/color.d.ts +2 -2
- package/lib/color.js +58 -3
- package/lib/common.js +33 -7
- package/lib/drawable/circle_shape.d.ts +2 -2
- package/lib/drawable/circle_shape.js +3 -3
- package/lib/drawable/convex_shape.d.ts +5 -0
- package/lib/drawable/convex_shape.js +35 -0
- package/lib/drawable/drawable.d.ts +6 -0
- package/lib/drawable/{base.js → drawable.js} +7 -4
- package/lib/drawable/plugin_package.d.ts +31 -0
- package/lib/drawable/plugin_package.js +102 -0
- package/lib/drawable/rectangle_shape.d.ts +6 -3
- package/lib/drawable/rectangle_shape.js +14 -2
- package/lib/drawable/shape.d.ts +8 -32
- package/lib/drawable/shape.js +16 -115
- package/lib/drawable/sprite.d.ts +17 -0
- package/lib/drawable/sprite.js +53 -0
- package/lib/drawable/text.d.ts +26 -0
- package/lib/drawable/text.js +88 -0
- package/lib/drawable/transformable.d.ts +28 -0
- package/lib/drawable/transformable.js +113 -0
- package/lib/drawable/vertex_array.d.ts +40 -0
- package/lib/drawable/vertex_array.js +128 -0
- package/lib/font.d.ts +24 -0
- package/lib/font.js +137 -0
- package/lib/image.d.ts +26 -0
- package/lib/image.js +147 -0
- package/lib/joystick.d.ts +21 -0
- package/lib/joystick.js +72 -0
- package/lib/keyboard.d.ts +113 -0
- package/lib/keyboard.js +17 -0
- package/lib/mouse.d.ts +6 -0
- package/lib/mouse.js +39 -0
- package/lib/poll_event.d.ts +72 -10
- package/lib/rect.d.ts +2 -2
- package/lib/rect.js +29 -9
- package/lib/render_window.d.ts +54 -15
- package/lib/render_window.js +137 -7
- package/lib/sensor.d.ts +12 -0
- package/lib/sensor.js +34 -0
- package/lib/sfml.d.ts +32 -0
- package/lib/sfml.js +26 -9
- package/lib/sound/base.d.ts +33 -0
- package/lib/sound/base.js +109 -0
- package/lib/sound/music.d.ts +15 -0
- package/lib/sound/music.js +65 -0
- package/lib/sound/sound.d.ts +16 -0
- package/lib/sound/sound.js +55 -0
- package/lib/sound/sound_buffer.d.ts +14 -0
- package/lib/sound/sound_buffer.js +78 -0
- package/lib/texture.d.ts +21 -0
- package/lib/texture.js +127 -0
- package/lib/time.d.ts +2 -2
- package/lib/touch.d.ts +7 -0
- package/lib/touch.js +34 -0
- package/lib/vector2.d.ts +24 -0
- package/lib/vector2.js +85 -16
- package/lib/vector3.d.ts +47 -0
- package/lib/vector3.js +154 -0
- package/lib/vertex.d.ts +14 -0
- package/lib/vertex.js +177 -0
- package/lib/video_mode.d.ts +2 -4
- package/lib/video_mode.js +15 -5
- package/package.json +26 -38
- package/src/base_class_with_loading.h +21 -0
- package/src/clock.cc +12 -3
- package/src/clock.h +5 -2
- package/src/color.cc +18 -13
- package/src/color.h +9 -3
- package/src/drawable/circle_shape.cc +9 -9
- package/src/drawable/circle_shape.h +4 -1
- package/src/drawable/convex_shape.cc +57 -0
- package/src/drawable/convex_shape.h +29 -0
- package/src/drawable/drawable-inl.h +29 -0
- package/src/drawable/drawable.cc +41 -0
- package/src/drawable/drawable.h +26 -38
- package/src/drawable/package_plugin-inl.h +191 -0
- package/src/drawable/package_plugin.h +60 -0
- package/src/drawable/rectangle_shape.cc +43 -7
- package/src/drawable/rectangle_shape.h +7 -1
- package/src/drawable/shape.cc +67 -0
- package/src/drawable/shape.h +13 -28
- package/src/drawable/sprite.cc +122 -0
- package/src/drawable/sprite.h +45 -0
- package/src/drawable/text.cc +133 -0
- package/src/drawable/text.h +54 -0
- package/src/drawable/vertex_array.cc +248 -0
- package/src/drawable/vertex_array.h +46 -0
- package/src/font.cc +214 -0
- package/src/font.h +44 -0
- package/src/gen/joystick_axis.cc +30 -0
- package/src/gen/keycode.cc +12 -4
- package/src/gen/sensor_type.cc +26 -0
- package/src/image.cc +379 -0
- package/src/image.h +72 -0
- package/src/joystick.cc +132 -0
- package/src/joystick.h +32 -0
- package/src/keyboard.cc +50 -0
- package/src/keyboard.h +8 -1
- package/src/mouse.cc +80 -0
- package/src/mouse.h +9 -1
- package/src/plugins/transformable_plugin-inl.h +121 -0
- package/src/plugins/transformable_plugin.h +42 -0
- package/src/poll_event.cc +74 -1
- package/src/poll_event.h +2 -1
- package/src/rect-inl.h +21 -16
- package/src/rect.h +10 -8
- package/src/render_window.cc +249 -6
- package/src/render_window.h +70 -2
- package/src/render_window_async_display.cc +49 -0
- package/src/render_window_async_draw.cc +56 -0
- package/src/resizable_buffer.h +104 -0
- package/src/sensor.cc +82 -0
- package/src/sensor.h +28 -0
- package/src/sfml.cc +41 -0
- package/src/sound/music.cc +113 -0
- package/src/sound/music.h +35 -0
- package/src/sound/sound.cc +116 -0
- package/src/sound/sound.h +41 -0
- package/src/sound/sound_buffer.cc +226 -0
- package/src/sound/sound_buffer.h +46 -0
- package/src/sound/sound_source.cc +124 -0
- package/src/sound/sound_source.h +80 -0
- package/src/texture.cc +246 -0
- package/src/texture.h +47 -0
- package/src/time.cc +1 -1
- package/src/time.h +2 -1
- package/src/touch.cc +54 -0
- package/src/touch.h +23 -0
- package/src/utils-inl.h +19 -0
- package/src/utils.h +6 -0
- package/src/vector2-inl.h +101 -17
- package/src/vector2.cc +4 -3
- package/src/vector2.h +42 -12
- package/src/vector3-inl.h +200 -0
- package/src/vector3.cc +36 -0
- package/src/vector3.h +134 -0
- package/src/vertex.cc +238 -0
- package/src/vertex.h +114 -0
- package/src/video_mode.cc +9 -9
- package/src/video_mode.h +9 -2
- package/src/workers/load_from_file_worker.h +79 -0
- package/src/workers/save_to_file_worker.h +79 -0
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/AlResource.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/Export.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/InputSoundFile.hpp +17 -12
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/Listener.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio/Music.hpp +10 -10
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/OutputSoundFile.hpp +4 -4
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/Sound.hpp +2 -2
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/SoundBuffer.hpp +6 -6
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/SoundBufferRecorder.hpp +3 -3
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio/SoundFileFactory.hpp +3 -3
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio/SoundFileFactory.inl +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/SoundFileReader.hpp +4 -4
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio/SoundFileWriter.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio/SoundRecorder.hpp +12 -10
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio/SoundSource.hpp +5 -5
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Audio/SoundStream.hpp +34 -19
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Audio.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Config.hpp +16 -4
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/GpuPreference.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/BlendMode.hpp +28 -24
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/CircleShape.hpp +3 -3
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Color.hpp +14 -14
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/ConvexShape.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Drawable.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Export.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Font.hpp +81 -24
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Glsl.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Glsl.inl +6 -6
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Glyph.hpp +7 -5
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Image.hpp +34 -12
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/PrimitiveType.hpp +11 -11
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Rect.hpp +25 -5
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Rect.inl +13 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/RectangleShape.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/RenderStates.hpp +6 -6
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/RenderTarget.hpp +21 -13
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/RenderTexture.hpp +23 -3
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/RenderWindow.hpp +13 -2
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Shader.hpp +8 -8
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Shape.hpp +10 -10
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Sprite.hpp +4 -4
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Text.hpp +20 -20
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Texture.hpp +13 -13
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Transform.hpp +23 -5
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/Transformable.hpp +9 -9
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/Vertex.hpp +4 -4
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics/VertexArray.hpp +3 -3
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/VertexBuffer.hpp +8 -8
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Graphics/View.hpp +9 -9
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Graphics.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Main.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/Export.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/Ftp.hpp +53 -53
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/Http.hpp +44 -44
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/IpAddress.hpp +7 -7
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Network/Packet.hpp +18 -5
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/Socket.hpp +12 -12
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Network/SocketHandle.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/SocketSelector.hpp +2 -2
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Network/TcpListener.hpp +5 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Network/TcpSocket.hpp +6 -6
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Network/UdpSocket.hpp +7 -6
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Network.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/OpenGL.hpp +2 -2
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Clock.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/Err.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Export.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/FileInputStream.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/InputStream.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Lock.hpp +2 -2
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/MemoryInputStream.hpp +4 -4
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Mutex.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/NativeActivity.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/NonCopyable.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Sleep.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/String.hpp +5 -5
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/String.inl +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Thread.hpp +3 -3
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/Thread.inl +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/ThreadLocal.hpp +2 -2
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/ThreadLocalPtr.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/ThreadLocalPtr.inl +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Time.hpp +3 -3
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/Utf.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/Utf.inl +12 -12
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/Vector2.hpp +3 -3
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/System/Vector2.inl +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Vector3.hpp +4 -4
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System/Vector3.inl +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/System.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Window/Clipboard.hpp +1 -1
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/Context.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/ContextSettings.hpp +11 -11
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/Cursor.hpp +36 -17
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/Event.hpp +72 -71
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/Export.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Window/GlResource.hpp +1 -1
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Window/Joystick.hpp +15 -15
- package/third_party/sfml/include/SFML/Window/Keyboard.hpp +491 -0
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Window/Mouse.hpp +15 -12
- package/third_party/{SFML-2.5.1 → sfml}/include/SFML/Window/Sensor.hpp +8 -8
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/Touch.hpp +3 -3
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/VideoMode.hpp +4 -4
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Window/GlResource.hpp → sfml/include/SFML/Window/Vulkan.hpp} +51 -45
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/Window.hpp +35 -303
- package/third_party/{SFML-2.5.1/include/SFML/Window/Window.hpp → sfml/include/SFML/Window/WindowBase.hpp} +60 -164
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/WindowHandle.hpp +2 -2
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window/WindowStyle.hpp +7 -7
- package/third_party/{SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers → sfml/include/SFML}/Window.hpp +1 -1
- package/tools/clang_format.js +9 -0
- package/tools/copier/linux.js +21 -0
- package/tools/copier/macos.js +34 -0
- package/tools/copier/windows.js +33 -0
- package/tools/joystick_axis.js +63 -0
- package/tools/keycode.js +62 -19
- package/tools/lib_downloader.js +107 -0
- package/tools/lib_downloader_urls.js +59 -0
- package/tools/mouse_button.js +60 -37
- package/tools/sensor_type.js +63 -0
- package/tsconfig.json +8 -0
- package/lib/drawable/base.d.ts +0 -3
- package/src/drawable/shape-inl.h +0 -231
- package/third_party/SFML-2.5.1/include/SFML/Audio/Music.hpp +0 -337
- package/third_party/SFML-2.5.1/include/SFML/Audio/SoundFileFactory.hpp +0 -197
- package/third_party/SFML-2.5.1/include/SFML/Audio/SoundFileFactory.inl +0 -100
- package/third_party/SFML-2.5.1/include/SFML/Audio/SoundFileWriter.hpp +0 -125
- package/third_party/SFML-2.5.1/include/SFML/Audio/SoundRecorder.hpp +0 -408
- package/third_party/SFML-2.5.1/include/SFML/Audio/SoundSource.hpp +0 -332
- package/third_party/SFML-2.5.1/include/SFML/Audio.hpp +0 -56
- package/third_party/SFML-2.5.1/include/SFML/Config.hpp +0 -236
- package/third_party/SFML-2.5.1/include/SFML/GpuPreference.hpp +0 -74
- package/third_party/SFML-2.5.1/include/SFML/Graphics/BlendMode.hpp +0 -215
- package/third_party/SFML-2.5.1/include/SFML/Graphics/ConvexShape.hpp +0 -153
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Drawable.hpp +0 -126
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Export.hpp +0 -48
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Font.hpp +0 -439
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Glsl.hpp +0 -227
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Rect.hpp +0 -254
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Rect.inl +0 -159
- package/third_party/SFML-2.5.1/include/SFML/Graphics/RectangleShape.hpp +0 -132
- package/third_party/SFML-2.5.1/include/SFML/Graphics/RenderStates.hpp +0 -174
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Shape.hpp +0 -355
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Sprite.hpp +0 -279
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Texture.hpp +0 -733
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Transform.hpp +0 -479
- package/third_party/SFML-2.5.1/include/SFML/Graphics/Vertex.hpp +0 -148
- package/third_party/SFML-2.5.1/include/SFML/Graphics/VertexArray.hpp +0 -223
- package/third_party/SFML-2.5.1/include/SFML/Graphics.hpp +0 -68
- package/third_party/SFML-2.5.1/include/SFML/Network/Export.hpp +0 -48
- package/third_party/SFML-2.5.1/include/SFML/Network/Ftp.hpp +0 -616
- package/third_party/SFML-2.5.1/include/SFML/Network/Http.hpp +0 -482
- package/third_party/SFML-2.5.1/include/SFML/Network/IpAddress.hpp +0 -328
- package/third_party/SFML-2.5.1/include/SFML/Network/Socket.hpp +0 -219
- package/third_party/SFML-2.5.1/include/SFML/Network/SocketSelector.hpp +0 -263
- package/third_party/SFML-2.5.1/include/SFML/Network/TcpSocket.hpp +0 -316
- package/third_party/SFML-2.5.1/include/SFML/System/Err.hpp +0 -80
- package/third_party/SFML-2.5.1/include/SFML/System/InputStream.hpp +0 -152
- package/third_party/SFML-2.5.1/include/SFML/System/NativeActivity.hpp +0 -62
- package/third_party/SFML-2.5.1/include/SFML/System/NonCopyable.hpp +0 -129
- package/third_party/SFML-2.5.1/include/SFML/System/String.hpp +0 -669
- package/third_party/SFML-2.5.1/include/SFML/System/Thread.inl +0 -90
- package/third_party/SFML-2.5.1/include/SFML/System/ThreadLocalPtr.inl +0 -77
- package/third_party/SFML-2.5.1/include/SFML/System/Utf.hpp +0 -763
- package/third_party/SFML-2.5.1/include/SFML/System/Utf.inl +0 -752
- package/third_party/SFML-2.5.1/include/SFML/System/Vector2.hpp +0 -301
- package/third_party/SFML-2.5.1/include/SFML/System/Vector2.inl +0 -161
- package/third_party/SFML-2.5.1/include/SFML/Window/Context.hpp +0 -195
- package/third_party/SFML-2.5.1/include/SFML/Window/ContextSettings.hpp +0 -149
- package/third_party/SFML-2.5.1/include/SFML/Window/Cursor.hpp +0 -222
- package/third_party/SFML-2.5.1/include/SFML/Window/Event.hpp +0 -284
- package/third_party/SFML-2.5.1/include/SFML/Window/Export.hpp +0 -48
- package/third_party/SFML-2.5.1/include/SFML/Window/Keyboard.hpp +0 -232
- package/third_party/SFML-2.5.1/include/SFML/Window/Touch.hpp +0 -137
- package/third_party/SFML-2.5.1/include/SFML/Window/VideoMode.hpp +0 -228
- package/third_party/SFML-2.5.1/include/SFML/Window/WindowHandle.hpp +0 -101
- package/third_party/SFML-2.5.1/include/SFML/Window/WindowStyle.hpp +0 -53
- package/third_party/SFML-2.5.1/include/SFML/Window.hpp +0 -58
- package/third_party/SFML-2.5.1/lib/libsfml-audio.so.2.5.1 +0 -0
- package/third_party/SFML-2.5.1/lib/libsfml-graphics.so.2.5.1 +0 -0
- package/third_party/SFML-2.5.1/lib/libsfml-network.so.2.5.1 +0 -0
- package/third_party/SFML-2.5.1/lib/libsfml-system.so.2.5.1 +0 -0
- package/third_party/SFML-2.5.1/lib/libsfml-window.so.2.5.1 +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/FLAC.framework/Versions/A/FLAC +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/FLAC.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/OpenAL.framework/Versions/A/OpenAL +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/OpenAL.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/AlResource.hpp +0 -70
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/Export.hpp +0 -48
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/InputSoundFile.hpp +0 -263
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/Listener.hpp +0 -234
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/OutputSoundFile.hpp +0 -133
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/Sound.hpp +0 -264
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/SoundBuffer.hpp +0 -352
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/SoundBufferRecorder.hpp +0 -144
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/SoundFileReader.hpp +0 -165
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Audio/SoundStream.hpp +0 -405
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/CircleShape.hpp +0 -154
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Color.hpp +0 -275
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Glsl.inl +0 -155
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Glyph.hpp +0 -79
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Image.hpp +0 -324
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/PrimitiveType.hpp +0 -58
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/RenderTarget.hpp +0 -510
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/RenderTexture.hpp +0 -314
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/RenderWindow.hpp +0 -284
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Shader.hpp +0 -875
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Text.hpp +0 -513
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/Transformable.hpp +0 -429
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/VertexBuffer.hpp +0 -408
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Graphics/View.hpp +0 -343
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Main.hpp +0 -43
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Network/Packet.hpp +0 -532
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Network/SocketHandle.hpp +0 -57
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Network/TcpListener.hpp +0 -166
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Network/UdpSocket.hpp +0 -291
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Network.hpp +0 -53
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/OpenGL.hpp +0 -78
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Clock.hpp +0 -117
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Export.hpp +0 -48
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/FileInputStream.hpp +0 -169
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Lock.hpp +0 -139
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/MemoryInputStream.hpp +0 -148
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Mutex.hpp +0 -148
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Sleep.hpp +0 -52
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/String.inl +0 -53
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Thread.hpp +0 -282
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/ThreadLocal.hpp +0 -103
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/ThreadLocalPtr.hpp +0 -158
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Time.hpp +0 -488
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Vector3.hpp +0 -302
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System/Vector3.inl +0 -168
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/System.hpp +0 -60
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Window/Clipboard.hpp +0 -119
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Window/Joystick.hpp +0 -227
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Window/Keyboard.hpp +0 -232
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Window/Mouse.hpp +0 -177
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Headers/Window/Sensor.hpp +0 -150
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Resources/CMake/SFMLConfig.cmake +0 -148
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Resources/CMake/SFMLConfigDependencies.cmake +0 -86
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Resources/CMake/SFMLConfigVersion.cmake +0 -46
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Resources/CMake/SFMLSharedTargets-release.cmake +0 -59
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Resources/CMake/SFMLSharedTargets.cmake +0 -158
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/Resources/Info.plist +0 -26
- package/third_party/SFML-2.5.1/macOS/Frameworks/SFML.framework/Versions/2.5.1/SFML +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/freetype.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/freetype.framework/Versions/A/freetype +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/ogg.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/ogg.framework/Versions/A/ogg +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-audio.framework/Versions/2.5.1/Resources/Info.plist +0 -26
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-audio.framework/Versions/2.5.1/sfml-audio +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-graphics.framework/Versions/2.5.1/Resources/Info.plist +0 -26
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-graphics.framework/Versions/2.5.1/sfml-graphics +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-network.framework/Versions/2.5.1/Resources/Info.plist +0 -26
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-network.framework/Versions/2.5.1/sfml-network +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-system.framework/Versions/2.5.1/Resources/Info.plist +0 -26
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-system.framework/Versions/2.5.1/sfml-system +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-window.framework/Versions/2.5.1/Resources/Info.plist +0 -26
- package/third_party/SFML-2.5.1/macOS/Frameworks/sfml-window.framework/Versions/2.5.1/sfml-window +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/vorbis.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/vorbis.framework/Versions/A/vorbis +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/vorbisenc.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/vorbisenc.framework/Versions/A/vorbisenc +0 -0
- package/third_party/SFML-2.5.1/macOS/Frameworks/vorbisfile.framework/Versions/A/Resources/Info.plist +0 -22
- package/third_party/SFML-2.5.1/macOS/Frameworks/vorbisfile.framework/Versions/A/vorbisfile +0 -0
- package/third_party/SFML-2.5.1/macOS/lib/libsfml-audio.2.5.1.dylib +0 -0
- package/third_party/SFML-2.5.1/macOS/lib/libsfml-graphics.2.5.1.dylib +0 -0
- package/third_party/SFML-2.5.1/macOS/lib/libsfml-network.2.5.1.dylib +0 -0
- package/third_party/SFML-2.5.1/macOS/lib/libsfml-system.2.5.1.dylib +0 -0
- package/third_party/SFML-2.5.1/macOS/lib/libsfml-window.2.5.1.dylib +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -32,8 +32,6 @@
|
|
|
32
32
|
#include <SFML/Graphics/Glyph.hpp>
|
|
33
33
|
#include <SFML/Graphics/Texture.hpp>
|
|
34
34
|
#include <SFML/Graphics/Rect.hpp>
|
|
35
|
-
#include <SFML/System/Vector2.hpp>
|
|
36
|
-
#include <SFML/System/String.hpp>
|
|
37
35
|
#include <map>
|
|
38
36
|
#include <string>
|
|
39
37
|
#include <vector>
|
|
@@ -57,7 +55,7 @@ public:
|
|
|
57
55
|
////////////////////////////////////////////////////////////
|
|
58
56
|
struct Info
|
|
59
57
|
{
|
|
60
|
-
std::string family;
|
|
58
|
+
std::string family; //!< The font family
|
|
61
59
|
};
|
|
62
60
|
|
|
63
61
|
public:
|
|
@@ -166,6 +164,10 @@ public:
|
|
|
166
164
|
/// might be available. If the glyph is not available at the
|
|
167
165
|
/// requested size, an empty glyph is returned.
|
|
168
166
|
///
|
|
167
|
+
/// You may want to use \ref hasGlyph to determine if the
|
|
168
|
+
/// glyph exists before requesting it. If the glyph does not
|
|
169
|
+
/// exist, a font specific default is returned.
|
|
170
|
+
///
|
|
169
171
|
/// Be aware that using a negative value for the outline
|
|
170
172
|
/// thickness will cause distorted rendering.
|
|
171
173
|
///
|
|
@@ -179,6 +181,24 @@ public:
|
|
|
179
181
|
////////////////////////////////////////////////////////////
|
|
180
182
|
const Glyph& getGlyph(Uint32 codePoint, unsigned int characterSize, bool bold, float outlineThickness = 0) const;
|
|
181
183
|
|
|
184
|
+
////////////////////////////////////////////////////////////
|
|
185
|
+
/// \brief Determine if this font has a glyph representing the requested code point
|
|
186
|
+
///
|
|
187
|
+
/// Most fonts only include a very limited selection of glyphs from
|
|
188
|
+
/// specific Unicode subsets, like Latin, Cyrillic, or Asian characters.
|
|
189
|
+
///
|
|
190
|
+
/// While code points without representation will return a font specific
|
|
191
|
+
/// default character, it might be useful to verify whether specific
|
|
192
|
+
/// code points are included to determine whether a font is suited
|
|
193
|
+
/// to display text in a specific language.
|
|
194
|
+
///
|
|
195
|
+
/// \param codePoint Unicode code point to check
|
|
196
|
+
///
|
|
197
|
+
/// \return True if the codepoint has a glyph representation, false otherwise
|
|
198
|
+
///
|
|
199
|
+
////////////////////////////////////////////////////////////
|
|
200
|
+
bool hasGlyph(Uint32 codePoint) const;
|
|
201
|
+
|
|
182
202
|
////////////////////////////////////////////////////////////
|
|
183
203
|
/// \brief Get the kerning offset of two glyphs
|
|
184
204
|
///
|
|
@@ -195,7 +215,7 @@ public:
|
|
|
195
215
|
/// \return Kerning value for \a first and \a second, in pixels
|
|
196
216
|
///
|
|
197
217
|
////////////////////////////////////////////////////////////
|
|
198
|
-
float getKerning(Uint32 first, Uint32 second, unsigned int characterSize) const;
|
|
218
|
+
float getKerning(Uint32 first, Uint32 second, unsigned int characterSize, bool bold = false) const;
|
|
199
219
|
|
|
200
220
|
////////////////////////////////////////////////////////////
|
|
201
221
|
/// \brief Get the line spacing
|
|
@@ -253,6 +273,32 @@ public:
|
|
|
253
273
|
////////////////////////////////////////////////////////////
|
|
254
274
|
const Texture& getTexture(unsigned int characterSize) const;
|
|
255
275
|
|
|
276
|
+
////////////////////////////////////////////////////////////
|
|
277
|
+
/// \brief Enable or disable the smooth filter
|
|
278
|
+
///
|
|
279
|
+
/// When the filter is activated, the font appears smoother
|
|
280
|
+
/// so that pixels are less noticeable. However if you want
|
|
281
|
+
/// the font to look exactly the same as its source file,
|
|
282
|
+
/// you should disable it.
|
|
283
|
+
/// The smooth filter is enabled by default.
|
|
284
|
+
///
|
|
285
|
+
/// \param smooth True to enable smoothing, false to disable it
|
|
286
|
+
///
|
|
287
|
+
/// \see isSmooth
|
|
288
|
+
///
|
|
289
|
+
////////////////////////////////////////////////////////////
|
|
290
|
+
void setSmooth(bool smooth);
|
|
291
|
+
|
|
292
|
+
////////////////////////////////////////////////////////////
|
|
293
|
+
/// \brief Tell whether the smooth filter is enabled or not
|
|
294
|
+
///
|
|
295
|
+
/// \return True if smoothing is enabled, false if it is disabled
|
|
296
|
+
///
|
|
297
|
+
/// \see setSmooth
|
|
298
|
+
///
|
|
299
|
+
////////////////////////////////////////////////////////////
|
|
300
|
+
bool isSmooth() const;
|
|
301
|
+
|
|
256
302
|
////////////////////////////////////////////////////////////
|
|
257
303
|
/// \brief Overload of assignment operator
|
|
258
304
|
///
|
|
@@ -273,15 +319,15 @@ private:
|
|
|
273
319
|
{
|
|
274
320
|
Row(unsigned int rowTop, unsigned int rowHeight) : width(0), top(rowTop), height(rowHeight) {}
|
|
275
321
|
|
|
276
|
-
unsigned int width;
|
|
277
|
-
unsigned int top;
|
|
278
|
-
unsigned int height;
|
|
322
|
+
unsigned int width; //!< Current width of the row
|
|
323
|
+
unsigned int top; //!< Y position of the row into the texture
|
|
324
|
+
unsigned int height; //!< Height of the row
|
|
279
325
|
};
|
|
280
326
|
|
|
281
327
|
////////////////////////////////////////////////////////////
|
|
282
328
|
// Types
|
|
283
329
|
////////////////////////////////////////////////////////////
|
|
284
|
-
typedef std::map<Uint64, Glyph> GlyphTable;
|
|
330
|
+
typedef std::map<Uint64, Glyph> GlyphTable; //!< Table mapping a codepoint to its glyph
|
|
285
331
|
|
|
286
332
|
////////////////////////////////////////////////////////////
|
|
287
333
|
/// \brief Structure defining a page of glyphs
|
|
@@ -289,12 +335,12 @@ private:
|
|
|
289
335
|
////////////////////////////////////////////////////////////
|
|
290
336
|
struct Page
|
|
291
337
|
{
|
|
292
|
-
Page();
|
|
338
|
+
explicit Page(bool smooth);
|
|
293
339
|
|
|
294
|
-
GlyphTable glyphs;
|
|
295
|
-
Texture texture;
|
|
296
|
-
unsigned int nextRow;
|
|
297
|
-
std::vector<Row> rows;
|
|
340
|
+
GlyphTable glyphs; //!< Table mapping code points to their corresponding glyph
|
|
341
|
+
Texture texture; //!< Texture containing the pixels of the glyphs
|
|
342
|
+
unsigned int nextRow; //!< Y position of the next new row in the texture
|
|
343
|
+
std::vector<Row> rows; //!< List containing the position of all the existing rows
|
|
298
344
|
};
|
|
299
345
|
|
|
300
346
|
////////////////////////////////////////////////////////////
|
|
@@ -303,6 +349,16 @@ private:
|
|
|
303
349
|
////////////////////////////////////////////////////////////
|
|
304
350
|
void cleanup();
|
|
305
351
|
|
|
352
|
+
////////////////////////////////////////////////////////////
|
|
353
|
+
/// \brief Find or create the glyphs page corresponding to the given character size
|
|
354
|
+
///
|
|
355
|
+
/// \param characterSize Reference character size
|
|
356
|
+
///
|
|
357
|
+
/// \return The glyphs page corresponding to \a characterSize
|
|
358
|
+
///
|
|
359
|
+
////////////////////////////////////////////////////////////
|
|
360
|
+
Page& loadPage(unsigned int characterSize) const;
|
|
361
|
+
|
|
306
362
|
////////////////////////////////////////////////////////////
|
|
307
363
|
/// \brief Load a new glyph and store it in the cache
|
|
308
364
|
///
|
|
@@ -341,21 +397,22 @@ private:
|
|
|
341
397
|
////////////////////////////////////////////////////////////
|
|
342
398
|
// Types
|
|
343
399
|
////////////////////////////////////////////////////////////
|
|
344
|
-
typedef std::map<unsigned int, Page> PageTable;
|
|
400
|
+
typedef std::map<unsigned int, Page> PageTable; //!< Table mapping a character size to its page (texture)
|
|
345
401
|
|
|
346
402
|
////////////////////////////////////////////////////////////
|
|
347
403
|
// Member data
|
|
348
404
|
////////////////////////////////////////////////////////////
|
|
349
|
-
void* m_library;
|
|
350
|
-
void* m_face;
|
|
351
|
-
void* m_streamRec;
|
|
352
|
-
void* m_stroker;
|
|
353
|
-
int* m_refCount;
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
mutable
|
|
405
|
+
void* m_library; //!< Pointer to the internal library interface (it is typeless to avoid exposing implementation details)
|
|
406
|
+
void* m_face; //!< Pointer to the internal font face (it is typeless to avoid exposing implementation details)
|
|
407
|
+
void* m_streamRec; //!< Pointer to the stream rec instance (it is typeless to avoid exposing implementation details)
|
|
408
|
+
void* m_stroker; //!< Pointer to the stroker (it is typeless to avoid exposing implementation details)
|
|
409
|
+
int* m_refCount; //!< Reference counter used by implicit sharing
|
|
410
|
+
bool m_isSmooth; //!< Status of the smooth filter
|
|
411
|
+
Info m_info; //!< Information about the font
|
|
412
|
+
mutable PageTable m_pages; //!< Table containing the glyphs pages by character size
|
|
413
|
+
mutable std::vector<Uint8> m_pixelBuffer; //!< Pixel buffer holding a glyph's pixels before being written to the texture
|
|
357
414
|
#ifdef SFML_SYSTEM_ANDROID
|
|
358
|
-
void* m_stream;
|
|
415
|
+
void* m_stream; //!< Asset file streamer (if loaded from file)
|
|
359
416
|
#endif
|
|
360
417
|
};
|
|
361
418
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -81,7 +81,7 @@ struct Matrix
|
|
|
81
81
|
copyMatrix(transform, *this);
|
|
82
82
|
}
|
|
83
83
|
|
|
84
|
-
float array[Columns * Rows];
|
|
84
|
+
float array[Columns * Rows]; //!< Array holding matrix data
|
|
85
85
|
};
|
|
86
86
|
|
|
87
87
|
////////////////////////////////////////////////////////////
|
|
@@ -148,8 +148,8 @@ struct Vector4
|
|
|
148
148
|
copyVector(color, *this);
|
|
149
149
|
}
|
|
150
150
|
|
|
151
|
-
T x;
|
|
152
|
-
T y;
|
|
153
|
-
T z;
|
|
154
|
-
T w;
|
|
151
|
+
T x; //!< 1st component (X) of the 4D vector
|
|
152
|
+
T y; //!< 2nd component (Y) of the 4D vector
|
|
153
|
+
T z; //!< 3rd component (Z) of the 4D vector
|
|
154
|
+
T w; //!< 4th component (W) of the 4D vector
|
|
155
155
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -46,14 +46,16 @@ public:
|
|
|
46
46
|
/// \brief Default constructor
|
|
47
47
|
///
|
|
48
48
|
////////////////////////////////////////////////////////////
|
|
49
|
-
Glyph() : advance(0) {}
|
|
49
|
+
Glyph() : advance(0), lsbDelta(0), rsbDelta(0) {}
|
|
50
50
|
|
|
51
51
|
////////////////////////////////////////////////////////////
|
|
52
52
|
// Member data
|
|
53
53
|
////////////////////////////////////////////////////////////
|
|
54
|
-
float advance;
|
|
55
|
-
|
|
56
|
-
|
|
54
|
+
float advance; //!< Offset to move horizontally to the next character
|
|
55
|
+
int lsbDelta; //!< Left offset after forced autohint. Internally used by getKerning()
|
|
56
|
+
int rsbDelta; //!< Right offset after forced autohint. Internally used by getKerning()
|
|
57
|
+
FloatRect bounds; //!< Bounding rectangle of the glyph, in coordinates relative to the baseline
|
|
58
|
+
IntRect textureRect; //!< Texture coordinates of the glyph inside the font's texture
|
|
57
59
|
};
|
|
58
60
|
|
|
59
61
|
} // namespace sf
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -90,8 +90,8 @@ public:
|
|
|
90
90
|
/// \brief Load the image from a file on disk
|
|
91
91
|
///
|
|
92
92
|
/// The supported image formats are bmp, png, tga, jpg, gif,
|
|
93
|
-
/// psd, hdr and
|
|
94
|
-
/// like
|
|
93
|
+
/// psd, hdr, pic and pnm. Some format options are not supported,
|
|
94
|
+
/// like jpeg with arithmetic coding or ASCII pnm.
|
|
95
95
|
/// If this function fails, the image is left unchanged.
|
|
96
96
|
///
|
|
97
97
|
/// \param filename Path of the image file to load
|
|
@@ -107,8 +107,8 @@ public:
|
|
|
107
107
|
/// \brief Load the image from a file in memory
|
|
108
108
|
///
|
|
109
109
|
/// The supported image formats are bmp, png, tga, jpg, gif,
|
|
110
|
-
/// psd, hdr and
|
|
111
|
-
/// like
|
|
110
|
+
/// psd, hdr, pic and pnm. Some format options are not supported,
|
|
111
|
+
/// like jpeg with arithmetic coding or ASCII pnm.
|
|
112
112
|
/// If this function fails, the image is left unchanged.
|
|
113
113
|
///
|
|
114
114
|
/// \param data Pointer to the file data in memory
|
|
@@ -125,8 +125,8 @@ public:
|
|
|
125
125
|
/// \brief Load the image from a custom stream
|
|
126
126
|
///
|
|
127
127
|
/// The supported image formats are bmp, png, tga, jpg, gif,
|
|
128
|
-
/// psd, hdr and
|
|
129
|
-
/// like
|
|
128
|
+
/// psd, hdr, pic and pnm. Some format options are not supported,
|
|
129
|
+
/// like jpeg with arithmetic coding or ASCII pnm.
|
|
130
130
|
/// If this function fails, the image is left unchanged.
|
|
131
131
|
///
|
|
132
132
|
/// \param stream Source stream to read from
|
|
@@ -155,6 +155,24 @@ public:
|
|
|
155
155
|
////////////////////////////////////////////////////////////
|
|
156
156
|
bool saveToFile(const std::string& filename) const;
|
|
157
157
|
|
|
158
|
+
////////////////////////////////////////////////////////////
|
|
159
|
+
/// \brief Save the image to a buffer in memory
|
|
160
|
+
///
|
|
161
|
+
/// The format of the image must be specified.
|
|
162
|
+
/// The supported image formats are bmp, png, tga and jpg.
|
|
163
|
+
/// This function fails if the image is empty, or if
|
|
164
|
+
/// the format was invalid.
|
|
165
|
+
///
|
|
166
|
+
/// \param output Buffer to fill with encoded data
|
|
167
|
+
/// \param format Encoding format to use
|
|
168
|
+
///
|
|
169
|
+
/// \return True if saving was successful
|
|
170
|
+
///
|
|
171
|
+
/// \see create, loadFromFile, loadFromMemory, saveToFile
|
|
172
|
+
///
|
|
173
|
+
////////////////////////////////////////////////////////////
|
|
174
|
+
bool saveToMemory(std::vector<sf::Uint8>& output, const std::string& format) const;
|
|
175
|
+
|
|
158
176
|
////////////////////////////////////////////////////////////
|
|
159
177
|
/// \brief Return the size (width and height) of the image
|
|
160
178
|
///
|
|
@@ -185,9 +203,13 @@ public:
|
|
|
185
203
|
/// kind of feature in real-time you'd better use sf::RenderTexture.
|
|
186
204
|
///
|
|
187
205
|
/// If \a sourceRect is empty, the whole image is copied.
|
|
188
|
-
/// If \a applyAlpha is set to true,
|
|
189
|
-
///
|
|
190
|
-
///
|
|
206
|
+
/// If \a applyAlpha is set to true, alpha blending is
|
|
207
|
+
/// applied from the source pixels to the destination pixels
|
|
208
|
+
/// using the \b over operator. If it is false, the source
|
|
209
|
+
/// pixels are copied unchanged with their alpha value.
|
|
210
|
+
///
|
|
211
|
+
/// See https://en.wikipedia.org/wiki/Alpha_compositing for
|
|
212
|
+
/// details on the \b over operator.
|
|
191
213
|
///
|
|
192
214
|
/// \param source Source image to copy
|
|
193
215
|
/// \param destX X coordinate of the destination position
|
|
@@ -263,8 +285,8 @@ private:
|
|
|
263
285
|
////////////////////////////////////////////////////////////
|
|
264
286
|
// Member data
|
|
265
287
|
////////////////////////////////////////////////////////////
|
|
266
|
-
Vector2u m_size;
|
|
267
|
-
std::vector<Uint8> m_pixels;
|
|
288
|
+
Vector2u m_size; //!< Image size
|
|
289
|
+
std::vector<Uint8> m_pixels; //!< Pixels of the image
|
|
268
290
|
};
|
|
269
291
|
|
|
270
292
|
} // namespace sf
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -38,18 +38,18 @@ namespace sf
|
|
|
38
38
|
////////////////////////////////////////////////////////////
|
|
39
39
|
enum PrimitiveType
|
|
40
40
|
{
|
|
41
|
-
Points,
|
|
42
|
-
Lines,
|
|
43
|
-
LineStrip,
|
|
44
|
-
Triangles,
|
|
45
|
-
TriangleStrip,
|
|
46
|
-
TriangleFan,
|
|
47
|
-
Quads,
|
|
41
|
+
Points, //!< List of individual points
|
|
42
|
+
Lines, //!< List of individual lines
|
|
43
|
+
LineStrip, //!< List of connected lines, a point uses the previous point to form a line
|
|
44
|
+
Triangles, //!< List of individual triangles
|
|
45
|
+
TriangleStrip, //!< List of connected triangles, a point uses the two previous points to form a triangle
|
|
46
|
+
TriangleFan, //!< List of connected triangles, a point uses the common center and the previous point to form a triangle
|
|
47
|
+
Quads, //!< List of individual quads (deprecated, don't work with OpenGL ES)
|
|
48
48
|
|
|
49
49
|
// Deprecated names
|
|
50
|
-
LinesStrip = LineStrip,
|
|
51
|
-
TrianglesStrip = TriangleStrip,
|
|
52
|
-
TrianglesFan = TriangleFan
|
|
50
|
+
LinesStrip = LineStrip, //!< \deprecated Use LineStrip instead
|
|
51
|
+
TrianglesStrip = TriangleStrip, //!< \deprecated Use TriangleStrip instead
|
|
52
|
+
TrianglesFan = TriangleFan //!< \deprecated Use TriangleFan instead
|
|
53
53
|
};
|
|
54
54
|
|
|
55
55
|
} // namespace sf
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -151,13 +151,33 @@ public:
|
|
|
151
151
|
////////////////////////////////////////////////////////////
|
|
152
152
|
bool intersects(const Rect<T>& rectangle, Rect<T>& intersection) const;
|
|
153
153
|
|
|
154
|
+
////////////////////////////////////////////////////////////
|
|
155
|
+
/// \brief Get the position of the rectangle's top-left corner
|
|
156
|
+
///
|
|
157
|
+
/// \return Position of rectangle
|
|
158
|
+
///
|
|
159
|
+
/// \see getSize
|
|
160
|
+
///
|
|
161
|
+
////////////////////////////////////////////////////////////
|
|
162
|
+
sf::Vector2<T> getPosition() const;
|
|
163
|
+
|
|
164
|
+
////////////////////////////////////////////////////////////
|
|
165
|
+
/// \brief Get the size of the rectangle
|
|
166
|
+
///
|
|
167
|
+
/// \return Size of rectangle
|
|
168
|
+
///
|
|
169
|
+
/// \see getPosition
|
|
170
|
+
///
|
|
171
|
+
////////////////////////////////////////////////////////////
|
|
172
|
+
sf::Vector2<T> getSize() const;
|
|
173
|
+
|
|
154
174
|
////////////////////////////////////////////////////////////
|
|
155
175
|
// Member data
|
|
156
176
|
////////////////////////////////////////////////////////////
|
|
157
|
-
T left;
|
|
158
|
-
T top;
|
|
159
|
-
T width;
|
|
160
|
-
T height;
|
|
177
|
+
T left; //!< Left coordinate of the rectangle
|
|
178
|
+
T top; //!< Top coordinate of the rectangle
|
|
179
|
+
T width; //!< Width of the rectangle
|
|
180
|
+
T height; //!< Height of the rectangle
|
|
161
181
|
};
|
|
162
182
|
|
|
163
183
|
////////////////////////////////////////////////////////////
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -141,6 +141,18 @@ bool Rect<T>::intersects(const Rect<T>& rectangle, Rect<T>& intersection) const
|
|
|
141
141
|
}
|
|
142
142
|
}
|
|
143
143
|
|
|
144
|
+
template <typename T>
|
|
145
|
+
sf::Vector2<T> Rect<T>::getPosition() const
|
|
146
|
+
{
|
|
147
|
+
return sf::Vector2<T>(left, top);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
template <typename T>
|
|
151
|
+
sf::Vector2<T> Rect<T>::getSize() const
|
|
152
|
+
{
|
|
153
|
+
return sf::Vector2<T>(width, height);
|
|
154
|
+
}
|
|
155
|
+
|
|
144
156
|
|
|
145
157
|
////////////////////////////////////////////////////////////
|
|
146
158
|
template <typename T>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -99,7 +99,7 @@ private:
|
|
|
99
99
|
////////////////////////////////////////////////////////////
|
|
100
100
|
// Member data
|
|
101
101
|
////////////////////////////////////////////////////////////
|
|
102
|
-
Vector2f m_size;
|
|
102
|
+
Vector2f m_size; //!< Size of the rectangle
|
|
103
103
|
};
|
|
104
104
|
|
|
105
105
|
} // namespace sf
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -107,15 +107,15 @@ public:
|
|
|
107
107
|
////////////////////////////////////////////////////////////
|
|
108
108
|
// Static member data
|
|
109
109
|
////////////////////////////////////////////////////////////
|
|
110
|
-
static const RenderStates Default;
|
|
110
|
+
static const RenderStates Default; //!< Special instance holding the default render states
|
|
111
111
|
|
|
112
112
|
////////////////////////////////////////////////////////////
|
|
113
113
|
// Member data
|
|
114
114
|
////////////////////////////////////////////////////////////
|
|
115
|
-
BlendMode blendMode;
|
|
116
|
-
Transform transform;
|
|
117
|
-
const Texture* texture;
|
|
118
|
-
const Shader* shader;
|
|
115
|
+
BlendMode blendMode; //!< Blending mode
|
|
116
|
+
Transform transform; //!< Transform
|
|
117
|
+
const Texture* texture; //!< Texture
|
|
118
|
+
const Shader* shader; //!< Shader
|
|
119
119
|
};
|
|
120
120
|
|
|
121
121
|
} // namespace sf
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
////////////////////////////////////////////////////////////
|
|
2
2
|
//
|
|
3
3
|
// SFML - Simple and Fast Multimedia Library
|
|
4
|
-
// Copyright (C) 2007-
|
|
4
|
+
// Copyright (C) 2007-2023 Laurent Gomila (laurent@sfml-dev.org)
|
|
5
5
|
//
|
|
6
6
|
// This software is provided 'as-is', without any express or implied warranty.
|
|
7
7
|
// In no event will the authors be held liable for any damages arising from the use of this software.
|
|
@@ -276,6 +276,14 @@ public:
|
|
|
276
276
|
////////////////////////////////////////////////////////////
|
|
277
277
|
virtual Vector2u getSize() const = 0;
|
|
278
278
|
|
|
279
|
+
////////////////////////////////////////////////////////////
|
|
280
|
+
/// \brief Tell if the render target will use sRGB encoding when drawing on it
|
|
281
|
+
///
|
|
282
|
+
/// \return True if the render target use sRGB encoding, false otherwise
|
|
283
|
+
///
|
|
284
|
+
////////////////////////////////////////////////////////////
|
|
285
|
+
virtual bool isSrgb() const;
|
|
286
|
+
|
|
279
287
|
////////////////////////////////////////////////////////////
|
|
280
288
|
/// \brief Activate or deactivate the render target for rendering
|
|
281
289
|
///
|
|
@@ -458,23 +466,23 @@ private:
|
|
|
458
466
|
{
|
|
459
467
|
enum {VertexCacheSize = 4};
|
|
460
468
|
|
|
461
|
-
bool enable;
|
|
462
|
-
bool glStatesSet;
|
|
463
|
-
bool viewChanged;
|
|
464
|
-
BlendMode lastBlendMode;
|
|
465
|
-
Uint64 lastTextureId;
|
|
466
|
-
bool texCoordsArrayEnabled;
|
|
467
|
-
bool useVertexCache;
|
|
468
|
-
Vertex vertexCache[VertexCacheSize];
|
|
469
|
+
bool enable; //!< Is the cache enabled?
|
|
470
|
+
bool glStatesSet; //!< Are our internal GL states set yet?
|
|
471
|
+
bool viewChanged; //!< Has the current view changed since last draw?
|
|
472
|
+
BlendMode lastBlendMode; //!< Cached blending mode
|
|
473
|
+
Uint64 lastTextureId; //!< Cached texture
|
|
474
|
+
bool texCoordsArrayEnabled; //!< Is GL_TEXTURE_COORD_ARRAY client state enabled?
|
|
475
|
+
bool useVertexCache; //!< Did we previously use the vertex cache?
|
|
476
|
+
Vertex vertexCache[VertexCacheSize]; //!< Pre-transformed vertices cache
|
|
469
477
|
};
|
|
470
478
|
|
|
471
479
|
////////////////////////////////////////////////////////////
|
|
472
480
|
// Member data
|
|
473
481
|
////////////////////////////////////////////////////////////
|
|
474
|
-
View m_defaultView;
|
|
475
|
-
View m_view;
|
|
476
|
-
StatesCache m_cache;
|
|
477
|
-
Uint64 m_id;
|
|
482
|
+
View m_defaultView; //!< Default view
|
|
483
|
+
View m_view; //!< Current view
|
|
484
|
+
StatesCache m_cache; //!< Render states cache
|
|
485
|
+
Uint64 m_id; //!< Unique number that identifies the RenderTarget
|
|
478
486
|
};
|
|
479
487
|
|
|
480
488
|
} // namespace sf
|