mirror of
https://github.com/SFML/SFML.git
synced 2025-02-19 06:39:59 +08:00
Added the trunk/branches/tags directories at repository root, and moved previous root into trunk/
git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/trunk@1002 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
commit
2f524481c1
239
CSFML/Doxyfile
Normal file
239
CSFML/Doxyfile
Normal file
@ -0,0 +1,239 @@
|
||||
# Doxyfile 1.5.2
|
||||
|
||||
#---------------------------------------------------------------------------
|
||||
# Project related configuration options
|
||||
#---------------------------------------------------------------------------
|
||||
DOXYFILE_ENCODING = UTF-8
|
||||
PROJECT_NAME = SFML
|
||||
PROJECT_NUMBER =
|
||||
OUTPUT_DIRECTORY = doc
|
||||
CREATE_SUBDIRS = NO
|
||||
OUTPUT_LANGUAGE = English
|
||||
BRIEF_MEMBER_DESC = YES
|
||||
REPEAT_BRIEF = YES
|
||||
ABBREVIATE_BRIEF = "The $name class" \
|
||||
"The $name widget" \
|
||||
"The $name file" \
|
||||
is \
|
||||
provides \
|
||||
specifies \
|
||||
contains \
|
||||
represents \
|
||||
a \
|
||||
an \
|
||||
the
|
||||
ALWAYS_DETAILED_SEC = YES
|
||||
INLINE_INHERITED_MEMB = YES
|
||||
FULL_PATH_NAMES = NO
|
||||
STRIP_FROM_PATH =
|
||||
STRIP_FROM_INC_PATH =
|
||||
SHORT_NAMES = NO
|
||||
JAVADOC_AUTOBRIEF = YES
|
||||
MULTILINE_CPP_IS_BRIEF = NO
|
||||
DETAILS_AT_TOP = NO
|
||||
INHERIT_DOCS = YES
|
||||
SEPARATE_MEMBER_PAGES = NO
|
||||
TAB_SIZE = 4
|
||||
ALIASES =
|
||||
OPTIMIZE_OUTPUT_FOR_C = YES
|
||||
OPTIMIZE_OUTPUT_JAVA = NO
|
||||
BUILTIN_STL_SUPPORT = NO
|
||||
CPP_CLI_SUPPORT = NO
|
||||
DISTRIBUTE_GROUP_DOC = NO
|
||||
SUBGROUPING = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# Build related configuration options
|
||||
#---------------------------------------------------------------------------
|
||||
EXTRACT_ALL = YES
|
||||
EXTRACT_PRIVATE = NO
|
||||
EXTRACT_STATIC = NO
|
||||
EXTRACT_LOCAL_CLASSES = NO
|
||||
EXTRACT_LOCAL_METHODS = NO
|
||||
HIDE_UNDOC_MEMBERS = NO
|
||||
HIDE_UNDOC_CLASSES = NO
|
||||
HIDE_FRIEND_COMPOUNDS = NO
|
||||
HIDE_IN_BODY_DOCS = NO
|
||||
INTERNAL_DOCS = NO
|
||||
CASE_SENSE_NAMES = YES
|
||||
HIDE_SCOPE_NAMES = NO
|
||||
SHOW_INCLUDE_FILES = YES
|
||||
INLINE_INFO = YES
|
||||
SORT_MEMBER_DOCS = YES
|
||||
SORT_BRIEF_DOCS = NO
|
||||
SORT_BY_SCOPE_NAME = NO
|
||||
GENERATE_TODOLIST = YES
|
||||
GENERATE_TESTLIST = YES
|
||||
GENERATE_BUGLIST = YES
|
||||
GENERATE_DEPRECATEDLIST= YES
|
||||
ENABLED_SECTIONS =
|
||||
MAX_INITIALIZER_LINES = 30
|
||||
SHOW_USED_FILES = YES
|
||||
SHOW_DIRECTORIES = NO
|
||||
FILE_VERSION_FILTER =
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to warning and progress messages
|
||||
#---------------------------------------------------------------------------
|
||||
QUIET = NO
|
||||
WARNINGS = YES
|
||||
WARN_IF_UNDOCUMENTED = YES
|
||||
WARN_IF_DOC_ERROR = YES
|
||||
WARN_NO_PARAMDOC = YES
|
||||
WARN_FORMAT = "$file:$line: $text"
|
||||
WARN_LOGFILE =
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the input files
|
||||
#---------------------------------------------------------------------------
|
||||
INPUT = include/SFML/ \
|
||||
Doxygen.hpp
|
||||
INPUT_ENCODING = UTF-8
|
||||
FILE_PATTERNS = *.h \
|
||||
*.hpp
|
||||
RECURSIVE = YES
|
||||
EXCLUDE =
|
||||
EXCLUDE_SYMLINKS = NO
|
||||
EXCLUDE_PATTERNS = .svn
|
||||
EXCLUDE_SYMBOLS =
|
||||
EXAMPLE_PATH =
|
||||
EXAMPLE_PATTERNS = *
|
||||
EXAMPLE_RECURSIVE = NO
|
||||
IMAGE_PATH =
|
||||
INPUT_FILTER =
|
||||
FILTER_PATTERNS =
|
||||
FILTER_SOURCE_FILES = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to source browsing
|
||||
#---------------------------------------------------------------------------
|
||||
SOURCE_BROWSER = YES
|
||||
INLINE_SOURCES = NO
|
||||
STRIP_CODE_COMMENTS = YES
|
||||
REFERENCED_BY_RELATION = NO
|
||||
REFERENCES_RELATION = NO
|
||||
REFERENCES_LINK_SOURCE = NO
|
||||
USE_HTAGS = NO
|
||||
VERBATIM_HEADERS = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the alphabetical class index
|
||||
#---------------------------------------------------------------------------
|
||||
ALPHABETICAL_INDEX = YES
|
||||
COLS_IN_ALPHA_INDEX = 5
|
||||
IGNORE_PREFIX =
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the HTML output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_HTML = YES
|
||||
HTML_OUTPUT = html
|
||||
HTML_FILE_EXTENSION = .htm
|
||||
HTML_HEADER = ../header.htm
|
||||
HTML_FOOTER = ../footer.htm
|
||||
HTML_STYLESHEET = ../doxygen.css
|
||||
HTML_ALIGN_MEMBERS = YES
|
||||
GENERATE_HTMLHELP = YES
|
||||
CHM_FILE = ../SFML.chm
|
||||
HHC_LOCATION = "C:/Program Files/HTML Help Workshop/hhc.exe"
|
||||
GENERATE_CHI = NO
|
||||
BINARY_TOC = NO
|
||||
TOC_EXPAND = NO
|
||||
DISABLE_INDEX = NO
|
||||
ENUM_VALUES_PER_LINE = 1
|
||||
GENERATE_TREEVIEW = NO
|
||||
TREEVIEW_WIDTH = 250
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the LaTeX output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_LATEX = NO
|
||||
LATEX_OUTPUT = latex
|
||||
LATEX_CMD_NAME = latex
|
||||
MAKEINDEX_CMD_NAME = makeindex
|
||||
COMPACT_LATEX = NO
|
||||
PAPER_TYPE = a4wide
|
||||
EXTRA_PACKAGES =
|
||||
LATEX_HEADER =
|
||||
PDF_HYPERLINKS = NO
|
||||
USE_PDFLATEX = NO
|
||||
LATEX_BATCHMODE = NO
|
||||
LATEX_HIDE_INDICES = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the RTF output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_RTF = NO
|
||||
RTF_OUTPUT = rtf
|
||||
COMPACT_RTF = NO
|
||||
RTF_HYPERLINKS = NO
|
||||
RTF_STYLESHEET_FILE =
|
||||
RTF_EXTENSIONS_FILE =
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the man page output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_MAN = NO
|
||||
MAN_OUTPUT = man
|
||||
MAN_EXTENSION = .3
|
||||
MAN_LINKS = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the XML output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_XML = NO
|
||||
XML_OUTPUT = xml
|
||||
XML_SCHEMA =
|
||||
XML_DTD =
|
||||
XML_PROGRAMLISTING = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options for the AutoGen Definitions output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_AUTOGEN_DEF = NO
|
||||
#---------------------------------------------------------------------------
|
||||
# configuration options related to the Perl module output
|
||||
#---------------------------------------------------------------------------
|
||||
GENERATE_PERLMOD = NO
|
||||
PERLMOD_LATEX = NO
|
||||
PERLMOD_PRETTY = YES
|
||||
PERLMOD_MAKEVAR_PREFIX =
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration options related to the preprocessor
|
||||
#---------------------------------------------------------------------------
|
||||
ENABLE_PREPROCESSING = YES
|
||||
MACRO_EXPANSION = NO
|
||||
EXPAND_ONLY_PREDEF = NO
|
||||
SEARCH_INCLUDES = YES
|
||||
INCLUDE_PATH =
|
||||
INCLUDE_FILE_PATTERNS =
|
||||
PREDEFINED =
|
||||
EXPAND_AS_DEFINED =
|
||||
SKIP_FUNCTION_MACROS = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration::additions related to external references
|
||||
#---------------------------------------------------------------------------
|
||||
TAGFILES =
|
||||
GENERATE_TAGFILE =
|
||||
ALLEXTERNALS = NO
|
||||
EXTERNAL_GROUPS = YES
|
||||
PERL_PATH = /usr/bin/perl
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration options related to the dot tool
|
||||
#---------------------------------------------------------------------------
|
||||
CLASS_DIAGRAMS = YES
|
||||
MSCGEN_PATH = D:/Programmes/mscgen
|
||||
HIDE_UNDOC_RELATIONS = YES
|
||||
HAVE_DOT = NO
|
||||
CLASS_GRAPH = YES
|
||||
COLLABORATION_GRAPH = YES
|
||||
GROUP_GRAPHS = YES
|
||||
UML_LOOK = NO
|
||||
TEMPLATE_RELATIONS = NO
|
||||
INCLUDE_GRAPH = YES
|
||||
INCLUDED_BY_GRAPH = YES
|
||||
CALL_GRAPH = NO
|
||||
CALLER_GRAPH = NO
|
||||
GRAPHICAL_HIERARCHY = YES
|
||||
DIRECTORY_GRAPH = YES
|
||||
DOT_IMAGE_FORMAT = png
|
||||
DOT_PATH =
|
||||
DOTFILE_DIRS =
|
||||
DOT_GRAPH_MAX_NODES = 50
|
||||
DOT_TRANSPARENT = NO
|
||||
DOT_MULTI_TARGETS = NO
|
||||
GENERATE_LEGEND = YES
|
||||
DOT_CLEANUP = YES
|
||||
#---------------------------------------------------------------------------
|
||||
# Configuration::additions related to the search engine
|
||||
#---------------------------------------------------------------------------
|
||||
SEARCHENGINE = NO
|
95
CSFML/Doxygen.hpp
Normal file
95
CSFML/Doxygen.hpp
Normal file
@ -0,0 +1,95 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
/// \mainpage
|
||||
///
|
||||
/// \section welcome Welcome
|
||||
/// Welcome to the official SFML documentation for C. Here you will find a detailed
|
||||
/// view of all the SFML <a href="./globals_func.htm">functions</a>, as well as source
|
||||
/// <a href="./files.htm">files</a>. <br/>
|
||||
/// If you are looking for tutorials, you can visit the official website
|
||||
/// at <a href="http://www.sfml-dev.org/tutorials/">www.sfml-dev.org</a>.
|
||||
///
|
||||
/// \section example Short example
|
||||
/// Here is a short example, to show you how simple it is to use SFML in C :
|
||||
///
|
||||
/// \code
|
||||
///
|
||||
/// #include <SFML/Audio.h>
|
||||
/// #include <SFML/Graphics.h>
|
||||
///
|
||||
/// int main()
|
||||
/// {
|
||||
/// sfWindowSettings Settings = {24, 8, 0};
|
||||
/// sfVideoMode Mode = {800, 600, 32};
|
||||
/// sfRenderWindow* App;
|
||||
/// sfImage* Image;
|
||||
/// sfSprite* Sprite;
|
||||
/// sfFont* Font;
|
||||
/// sfString* Text;
|
||||
/// sfMusic* Music;
|
||||
/// sfEvent Event;
|
||||
///
|
||||
/// /* Create the main window */
|
||||
/// App = sfRenderWindow_Create(Mode, "SFML window", sfResize | sfClose, Settings);
|
||||
/// if (!App)
|
||||
/// return EXIT_FAILURE;
|
||||
///
|
||||
/// /* Load a sprite to display */
|
||||
/// Image = sfImage_CreateFromFile("cute_image.jpg");
|
||||
/// if (!Image)
|
||||
/// return EXIT_FAILURE;
|
||||
/// Sprite = sfSprite_Create();
|
||||
/// sfSprite_SetImage(Sprite, Image);
|
||||
///
|
||||
/// /* Create a graphical string to display */
|
||||
/// Font = sfFont_CreateFromFile("arial.ttf", 50, NULL);
|
||||
/// if (!Font)
|
||||
/// return EXIT_FAILURE;
|
||||
/// Text = sfString_Create();
|
||||
/// sfString_SetText(Text, "Hello SFML");
|
||||
/// sfString_SetFont(Text, Font);
|
||||
/// sfString_SetSize(Text, 50);
|
||||
///
|
||||
/// /* Load a music to play */
|
||||
/// Music = sfMusic_CreateFromFile("nice_music.ogg");
|
||||
/// if (!Music)
|
||||
/// return EXIT_FAILURE;
|
||||
///
|
||||
/// /* Play the music */
|
||||
/// sfMusic_Play(Music);
|
||||
///
|
||||
/// /* Start the game loop */
|
||||
/// while (sfRenderWindow_IsOpened(App))
|
||||
/// {
|
||||
/// /* Process events */
|
||||
/// while (sfRenderWindow_GetEvent(App, &Event))
|
||||
/// {
|
||||
/// /* Close window : exit */
|
||||
/// if (Event.Type == sfEvtClosed)
|
||||
/// sfRenderWindow_Close(App);
|
||||
/// }
|
||||
///
|
||||
/// /* Clear the screen */
|
||||
/// sfRenderWindow_Clear(App, sfBlack);
|
||||
///
|
||||
/// /* Draw the sprite */
|
||||
/// sfRenderWindow_DrawSprite(App, Sprite);
|
||||
///
|
||||
/// /* Draw the string */
|
||||
/// sfRenderWindow_DrawString(App, Text);
|
||||
///
|
||||
/// /* Update the window */
|
||||
/// sfRenderWindow_Display(App);
|
||||
/// }
|
||||
///
|
||||
/// /* Cleanup resources */
|
||||
/// sfMusic_Destroy(Music);
|
||||
/// sfString_Destroy(Text);
|
||||
/// sfFont_Destroy(Font);
|
||||
/// sfSprite_Destroy(Sprite);
|
||||
/// sfImage_Destroy(Image);
|
||||
/// sfRenderWindow_Destroy(App);
|
||||
///
|
||||
/// return EXIT_SUCCESS;
|
||||
/// }
|
||||
/// \endcode
|
||||
////////////////////////////////////////////////////////////
|
14
CSFML/Makefile
Normal file
14
CSFML/Makefile
Normal file
@ -0,0 +1,14 @@
|
||||
|
||||
all: csfml
|
||||
|
||||
csfml:
|
||||
@(cd ./src/SFML && $(MAKE))
|
||||
|
||||
install:
|
||||
@(cd ./src/SFML && $(MAKE) $@)
|
||||
|
||||
clean:
|
||||
@(cd ./src/SFML && $(MAKE) $@)
|
||||
|
||||
mrproper:
|
||||
@(cd ./src/SFML && $(MAKE) $@)
|
98
CSFML/VC2005/CSFML.sln
Normal file
98
CSFML/VC2005/CSFML.sln
Normal file
@ -0,0 +1,98 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 9.00
|
||||
# Visual Studio 2005
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-audio", "csfml-audio.vcproj", "{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8} = {C061A27D-7CA0-4179-9869-672FA04A86A8}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-graphics", "csfml-graphics.vcproj", "{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED} = {0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8} = {C061A27D-7CA0-4179-9869-672FA04A86A8}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-network", "csfml-network.vcproj", "{823DDC98-42D5-4A38-88CF-9DC06C788AE4}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-system", "csfml-system.vcproj", "{C061A27D-7CA0-4179-9869-672FA04A86A8}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-window", "csfml-window.vcproj", "{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8} = {C061A27D-7CA0-4179-9869-672FA04A86A8}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug DLL|Win32 = Debug DLL|Win32
|
||||
Debug static|Win32 = Debug static|Win32
|
||||
Debug|Win32 = Debug|Win32
|
||||
Release DLL|Win32 = Release DLL|Win32
|
||||
Release static|Win32 = Release static|Win32
|
||||
Release|Win32 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release|Win32.Build.0 = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release|Win32.Build.0 = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.Build.0 = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release|Win32.Build.0 = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release|Win32.Build.0 = Release static|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
96
CSFML/VC2005/csfml-audio-d.def
Normal file
96
CSFML/VC2005/csfml-audio-d.def
Normal file
@ -0,0 +1,96 @@
|
||||
LIBRARY csfml-audio-d
|
||||
EXPORTS
|
||||
sfListener_SetGlobalVolume
|
||||
sfListener_GetGlobalVolume
|
||||
sfListener_SetPosition
|
||||
sfListener_GetPosition
|
||||
sfListener_SetTarget
|
||||
sfListener_GetTarget
|
||||
sfMusic_CreateFromFile
|
||||
sfMusic_CreateFromMemory
|
||||
sfMusic_Destroy
|
||||
sfMusic_SetLoop
|
||||
sfMusic_GetLoop
|
||||
sfMusic_GetDuration
|
||||
sfMusic_Play
|
||||
sfMusic_Pause
|
||||
sfMusic_Stop
|
||||
sfMusic_GetChannelsCount
|
||||
sfMusic_GetSampleRate
|
||||
sfMusic_GetStatus
|
||||
sfMusic_SetPitch
|
||||
sfMusic_SetVolume
|
||||
sfMusic_SetPosition
|
||||
sfMusic_SetMinDistance
|
||||
sfMusic_SetAttenuation
|
||||
sfMusic_GetPitch
|
||||
sfMusic_GetVolume
|
||||
sfMusic_GetPosition
|
||||
sfMusic_GetMinDistance
|
||||
sfMusic_GetAttenuation
|
||||
sfMusic_GetPlayingOffset
|
||||
sfSound_Create
|
||||
sfSound_Destroy
|
||||
sfSound_Play
|
||||
sfSound_Pause
|
||||
sfSound_Stop
|
||||
sfSound_SetBuffer
|
||||
sfSound_GetBuffer
|
||||
sfSound_SetLoop
|
||||
sfSound_GetLoop
|
||||
sfSound_GetStatus
|
||||
sfSound_SetPitch
|
||||
sfSound_SetVolume
|
||||
sfSound_SetPosition
|
||||
sfSound_SetMinDistance
|
||||
sfSound_SetAttenuation
|
||||
sfSound_SetPlayingOffset
|
||||
sfSound_GetPitch
|
||||
sfSound_GetVolume
|
||||
sfSound_GetPosition
|
||||
sfSound_GetPlayingOffset
|
||||
sfSound_GetMinDistance
|
||||
sfSound_GetAttenuation
|
||||
sfSoundBuffer_CreateFromFile
|
||||
sfSoundBuffer_CreateFromMemory
|
||||
sfSoundBuffer_CreateFromSamples
|
||||
sfSoundBuffer_Destroy
|
||||
sfSoundBuffer_SaveToFile
|
||||
sfSoundBuffer_GetSamples
|
||||
sfSoundBuffer_GetSamplesCount
|
||||
sfSoundBuffer_GetSampleRate
|
||||
sfSoundBuffer_GetChannelsCount
|
||||
sfSoundBuffer_GetDuration
|
||||
sfSoundBufferRecorder_Create
|
||||
sfSoundBufferRecorder_Destroy
|
||||
sfSoundBufferRecorder_Start
|
||||
sfSoundBufferRecorder_Stop
|
||||
sfSoundBufferRecorder_GetSampleRate
|
||||
sfSoundBufferRecorder_GetBuffer
|
||||
sfSoundRecorder_Create
|
||||
sfSoundRecorder_Destroy
|
||||
sfSoundRecorder_Start
|
||||
sfSoundRecorder_Stop
|
||||
sfSoundRecorder_GetSampleRate
|
||||
sfSoundRecorder_CanCapture
|
||||
sfSoundStream_Create
|
||||
sfSoundStream_Destroy
|
||||
sfSoundStream_Play
|
||||
sfSoundStream_Pause
|
||||
sfSoundStream_Stop
|
||||
sfSoundStream_GetStatus
|
||||
sfSoundStream_GetChannelsCount
|
||||
sfSoundStream_GetSampleRate
|
||||
sfSoundStream_SetPitch
|
||||
sfSoundStream_SetVolume
|
||||
sfSoundStream_SetPosition
|
||||
sfSoundStream_SetMinDistance
|
||||
sfSoundStream_SetAttenuation
|
||||
sfSoundStream_SetLoop
|
||||
sfSoundStream_GetPitch
|
||||
sfSoundStream_GetVolume
|
||||
sfSoundStream_GetPosition
|
||||
sfSoundStream_GetMinDistance
|
||||
sfSoundStream_GetAttenuation
|
||||
sfSoundStream_GetLoop
|
||||
sfSoundStream_GetPlayingOffset
|
96
CSFML/VC2005/csfml-audio.def
Normal file
96
CSFML/VC2005/csfml-audio.def
Normal file
@ -0,0 +1,96 @@
|
||||
LIBRARY csfml-audio
|
||||
EXPORTS
|
||||
sfListener_SetGlobalVolume
|
||||
sfListener_GetGlobalVolume
|
||||
sfListener_SetPosition
|
||||
sfListener_GetPosition
|
||||
sfListener_SetTarget
|
||||
sfListener_GetTarget
|
||||
sfMusic_CreateFromFile
|
||||
sfMusic_CreateFromMemory
|
||||
sfMusic_Destroy
|
||||
sfMusic_SetLoop
|
||||
sfMusic_GetLoop
|
||||
sfMusic_GetDuration
|
||||
sfMusic_Play
|
||||
sfMusic_Pause
|
||||
sfMusic_Stop
|
||||
sfMusic_GetChannelsCount
|
||||
sfMusic_GetSampleRate
|
||||
sfMusic_GetStatus
|
||||
sfMusic_SetPitch
|
||||
sfMusic_SetVolume
|
||||
sfMusic_SetPosition
|
||||
sfMusic_SetMinDistance
|
||||
sfMusic_SetAttenuation
|
||||
sfMusic_GetPitch
|
||||
sfMusic_GetVolume
|
||||
sfMusic_GetPosition
|
||||
sfMusic_GetMinDistance
|
||||
sfMusic_GetAttenuation
|
||||
sfMusic_GetPlayingOffset
|
||||
sfSound_Create
|
||||
sfSound_Destroy
|
||||
sfSound_Play
|
||||
sfSound_Pause
|
||||
sfSound_Stop
|
||||
sfSound_SetBuffer
|
||||
sfSound_GetBuffer
|
||||
sfSound_SetLoop
|
||||
sfSound_GetLoop
|
||||
sfSound_GetStatus
|
||||
sfSound_SetPitch
|
||||
sfSound_SetVolume
|
||||
sfSound_SetPosition
|
||||
sfSound_SetMinDistance
|
||||
sfSound_SetAttenuation
|
||||
sfSound_SetPlayingOffset
|
||||
sfSound_GetPitch
|
||||
sfSound_GetVolume
|
||||
sfSound_GetPosition
|
||||
sfSound_GetPlayingOffset
|
||||
sfSound_GetMinDistance
|
||||
sfSound_GetAttenuation
|
||||
sfSoundBuffer_CreateFromFile
|
||||
sfSoundBuffer_CreateFromMemory
|
||||
sfSoundBuffer_CreateFromSamples
|
||||
sfSoundBuffer_Destroy
|
||||
sfSoundBuffer_SaveToFile
|
||||
sfSoundBuffer_GetSamples
|
||||
sfSoundBuffer_GetSamplesCount
|
||||
sfSoundBuffer_GetSampleRate
|
||||
sfSoundBuffer_GetChannelsCount
|
||||
sfSoundBuffer_GetDuration
|
||||
sfSoundBufferRecorder_Create
|
||||
sfSoundBufferRecorder_Destroy
|
||||
sfSoundBufferRecorder_Start
|
||||
sfSoundBufferRecorder_Stop
|
||||
sfSoundBufferRecorder_GetSampleRate
|
||||
sfSoundBufferRecorder_GetBuffer
|
||||
sfSoundRecorder_Create
|
||||
sfSoundRecorder_Destroy
|
||||
sfSoundRecorder_Start
|
||||
sfSoundRecorder_Stop
|
||||
sfSoundRecorder_GetSampleRate
|
||||
sfSoundRecorder_CanCapture
|
||||
sfSoundStream_Create
|
||||
sfSoundStream_Destroy
|
||||
sfSoundStream_Play
|
||||
sfSoundStream_Pause
|
||||
sfSoundStream_Stop
|
||||
sfSoundStream_GetStatus
|
||||
sfSoundStream_GetChannelsCount
|
||||
sfSoundStream_GetSampleRate
|
||||
sfSoundStream_SetPitch
|
||||
sfSoundStream_SetVolume
|
||||
sfSoundStream_SetPosition
|
||||
sfSoundStream_SetMinDistance
|
||||
sfSoundStream_SetAttenuation
|
||||
sfSoundStream_SetLoop
|
||||
sfSoundStream_GetPitch
|
||||
sfSoundStream_GetVolume
|
||||
sfSoundStream_GetPosition
|
||||
sfSoundStream_GetMinDistance
|
||||
sfSoundStream_GetAttenuation
|
||||
sfSoundStream_GetLoop
|
||||
sfSoundStream_GetPlayingOffset
|
407
CSFML/VC2005/csfml-audio.vcproj
Normal file
407
CSFML/VC2005/csfml-audio.vcproj
Normal file
@ -0,0 +1,407 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="csfml-audio"
|
||||
ProjectGUID="{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}"
|
||||
RootNamespace="csfml-audio"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-audio-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-audio-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-audio-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-audio.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-audio-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-audio-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath=".\csfml-audio-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-audio.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\Listener.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\Listener.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\Music.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\Music.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\Sound.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\Sound.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundBuffer.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundBuffer.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundBufferRecorder.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundBufferRecorder.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundRecorder.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundRecorder.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundStatus.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundStream.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundStream.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
215
CSFML/VC2005/csfml-graphics-d.def
Normal file
215
CSFML/VC2005/csfml-graphics-d.def
Normal file
@ -0,0 +1,215 @@
|
||||
LIBRARY csfml-graphics-d
|
||||
EXPORTS
|
||||
sfBlack
|
||||
sfWhite
|
||||
sfRed
|
||||
sfGreen
|
||||
sfBlue
|
||||
sfYellow
|
||||
sfMagenta
|
||||
sfCyan
|
||||
sfColor_FromRGB
|
||||
sfColor_FromRGBA
|
||||
sfColor_Add
|
||||
sfColor_Modulate
|
||||
sfImage_Create
|
||||
sfImage_CreateFromColor
|
||||
sfImage_CreateFromPixels
|
||||
sfImage_CreateFromFile
|
||||
sfImage_CreateFromMemory
|
||||
sfImage_Destroy
|
||||
sfImage_SaveToFile
|
||||
sfImage_CreateMaskFromColor
|
||||
sfImage_Copy
|
||||
sfImage_CopyScreen
|
||||
sfImage_SetPixel
|
||||
sfImage_GetPixel
|
||||
sfImage_GetPixelsPtr
|
||||
sfImage_Bind
|
||||
sfImage_SetSmooth
|
||||
sfImage_GetWidth
|
||||
sfImage_GetHeight
|
||||
sfImage_IsSmooth
|
||||
sfFloatRect_Offset
|
||||
sfFloatRect_Contains
|
||||
sfFloatRect_Intersects
|
||||
sfIntRect_Offset
|
||||
sfIntRect_Contains
|
||||
sfIntRect_Intersects
|
||||
sfPostFX_CreateFromFile
|
||||
sfPostFX_CreateFromMemory
|
||||
sfPostFX_Destroy
|
||||
sfPostFX_SetParameter1
|
||||
sfPostFX_SetParameter2
|
||||
sfPostFX_SetParameter3
|
||||
sfPostFX_SetParameter4
|
||||
sfPostFX_SetTexture
|
||||
sfPostFX_CanUsePostFX
|
||||
sfShape_Create
|
||||
sfShape_CreateLine
|
||||
sfShape_CreateRectangle
|
||||
sfShape_CreateCircle
|
||||
sfShape_Destroy
|
||||
sfShape_SetX
|
||||
sfShape_SetY
|
||||
sfShape_SetPosition
|
||||
sfShape_SetScaleX
|
||||
sfShape_SetScaleY
|
||||
sfShape_SetScale
|
||||
sfShape_SetRotation
|
||||
sfShape_SetCenter
|
||||
sfShape_SetColor
|
||||
sfShape_SetBlendMode
|
||||
sfShape_GetX
|
||||
sfShape_GetY
|
||||
sfShape_GetScaleX
|
||||
sfShape_GetScaleY
|
||||
sfShape_GetRotation
|
||||
sfShape_GetCenterX
|
||||
sfShape_GetCenterY
|
||||
sfShape_GetColor
|
||||
sfShape_GetBlendMode
|
||||
sfShape_Move
|
||||
sfShape_Scale
|
||||
sfShape_Rotate
|
||||
sfShape_TransformToLocal
|
||||
sfShape_TransformToGlobal
|
||||
sfShape_AddPoint
|
||||
sfShape_EnableFill
|
||||
sfShape_EnableOutline
|
||||
sfShape_SetOutlineWidth
|
||||
sfShape_GetOutlineWidth
|
||||
sfShape_GetNbPoints
|
||||
sfShape_GetPointPosition
|
||||
sfShape_GetPointColor
|
||||
sfShape_GetPointOutlineColor
|
||||
sfShape_SetPointPosition
|
||||
sfShape_SetPointColor
|
||||
sfShape_SetPointOutlineColor
|
||||
sfSprite_Create
|
||||
sfSprite_Destroy
|
||||
sfSprite_SetX
|
||||
sfSprite_SetY
|
||||
sfSprite_SetPosition
|
||||
sfSprite_SetScaleX
|
||||
sfSprite_SetScaleY
|
||||
sfSprite_SetScale
|
||||
sfSprite_SetRotation
|
||||
sfSprite_SetCenter
|
||||
sfSprite_SetColor
|
||||
sfSprite_SetBlendMode
|
||||
sfSprite_GetX
|
||||
sfSprite_GetY
|
||||
sfSprite_GetScaleX
|
||||
sfSprite_GetScaleY
|
||||
sfSprite_GetRotation
|
||||
sfSprite_GetCenterX
|
||||
sfSprite_GetCenterY
|
||||
sfSprite_GetColor
|
||||
sfSprite_GetBlendMode
|
||||
sfSprite_Move
|
||||
sfSprite_Scale
|
||||
sfSprite_Rotate
|
||||
sfSprite_TransformToLocal
|
||||
sfSprite_TransformToGlobal
|
||||
sfSprite_SetImage
|
||||
sfSprite_SetSubRect
|
||||
sfSprite_Resize
|
||||
sfSprite_FlipX
|
||||
sfSprite_FlipY
|
||||
sfSprite_GetImage
|
||||
sfSprite_GetSubRect
|
||||
sfSprite_GetWidth
|
||||
sfSprite_GetHeight
|
||||
sfSprite_GetPixel
|
||||
sfFont_Create
|
||||
sfFont_CreateFromFile
|
||||
sfFont_CreateFromMemory
|
||||
sfFont_Destroy
|
||||
sfFont_GetCharacterSize
|
||||
sfFont_GetDefaultFont
|
||||
sfString_Create
|
||||
sfString_Destroy
|
||||
sfString_SetX
|
||||
sfString_SetY
|
||||
sfString_SetPosition
|
||||
sfString_SetScaleX
|
||||
sfString_SetScaleY
|
||||
sfString_SetScale
|
||||
sfString_SetRotation
|
||||
sfString_SetCenter
|
||||
sfString_SetColor
|
||||
sfString_SetBlendMode
|
||||
sfString_GetX
|
||||
sfString_GetY
|
||||
sfString_GetScaleX
|
||||
sfString_GetScaleY
|
||||
sfString_GetRotation
|
||||
sfString_GetCenterX
|
||||
sfString_GetCenterY
|
||||
sfString_GetColor
|
||||
sfString_GetBlendMode
|
||||
sfString_Move
|
||||
sfString_Scale
|
||||
sfString_Rotate
|
||||
sfString_TransformToLocal
|
||||
sfString_TransformToGlobal
|
||||
sfString_SetText
|
||||
sfString_SetUnicodeText
|
||||
sfString_SetFont
|
||||
sfString_SetSize
|
||||
sfString_SetStyle
|
||||
sfString_GetUnicodeText
|
||||
sfString_GetText
|
||||
sfString_GetFont
|
||||
sfString_GetSize
|
||||
sfString_GetStyle
|
||||
sfString_GetCharacterPos
|
||||
sfString_GetRect
|
||||
sfRenderWindow_Create
|
||||
sfRenderWindow_CreateFromHandle
|
||||
sfRenderWindow_Destroy
|
||||
sfRenderWindow_Close
|
||||
sfRenderWindow_IsOpened
|
||||
sfRenderWindow_GetWidth
|
||||
sfRenderWindow_GetHeight
|
||||
sfRenderWindow_GetSettings
|
||||
sfRenderWindow_GetEvent
|
||||
sfRenderWindow_UseVerticalSync
|
||||
sfRenderWindow_ShowMouseCursor
|
||||
sfRenderWindow_SetCursorPosition
|
||||
sfRenderWindow_SetPosition
|
||||
sfRenderWindow_SetSize
|
||||
sfRenderWindow_Show
|
||||
sfRenderWindow_EnableKeyRepeat
|
||||
sfRenderWindow_SetIcon
|
||||
sfRenderWindow_SetActive
|
||||
sfRenderWindow_Display
|
||||
sfRenderWindow_GetInput
|
||||
sfRenderWindow_SetFramerateLimit
|
||||
sfRenderWindow_GetFrameTime
|
||||
sfRenderWindow_SetJoystickThreshold
|
||||
sfRenderWindow_DrawPostFX
|
||||
sfRenderWindow_DrawSprite
|
||||
sfRenderWindow_DrawString
|
||||
sfRenderWindow_DrawShape
|
||||
sfRenderWindow_Capture
|
||||
sfRenderWindow_Clear
|
||||
sfRenderWindow_SetView
|
||||
sfRenderWindow_GetView
|
||||
sfRenderWindow_GetDefaultView
|
||||
sfRenderWindow_ConvertCoords
|
||||
sfRenderWindow_PreserveOpenGLStates
|
||||
sfView_Create
|
||||
sfView_CreateFromRect
|
||||
sfView_Destroy
|
||||
sfView_SetCenter
|
||||
sfView_SetHalfSize
|
||||
sfView_SetFromRect
|
||||
sfView_GetCenterX
|
||||
sfView_GetCenterY
|
||||
sfView_GetHalfSizeX
|
||||
sfView_GetHalfSizeY
|
||||
sfView_GetRect
|
||||
sfView_Move
|
||||
sfView_Zoom
|
215
CSFML/VC2005/csfml-graphics.def
Normal file
215
CSFML/VC2005/csfml-graphics.def
Normal file
@ -0,0 +1,215 @@
|
||||
LIBRARY csfml-graphics
|
||||
EXPORTS
|
||||
sfBlack
|
||||
sfWhite
|
||||
sfRed
|
||||
sfGreen
|
||||
sfBlue
|
||||
sfYellow
|
||||
sfMagenta
|
||||
sfCyan
|
||||
sfColor_FromRGB
|
||||
sfColor_FromRGBA
|
||||
sfColor_Add
|
||||
sfColor_Modulate
|
||||
sfImage_Create
|
||||
sfImage_CreateFromColor
|
||||
sfImage_CreateFromPixels
|
||||
sfImage_CreateFromFile
|
||||
sfImage_CreateFromMemory
|
||||
sfImage_Destroy
|
||||
sfImage_SaveToFile
|
||||
sfImage_CreateMaskFromColor
|
||||
sfImage_Copy
|
||||
sfImage_CopyScreen
|
||||
sfImage_SetPixel
|
||||
sfImage_GetPixel
|
||||
sfImage_GetPixelsPtr
|
||||
sfImage_Bind
|
||||
sfImage_SetSmooth
|
||||
sfImage_GetWidth
|
||||
sfImage_GetHeight
|
||||
sfImage_IsSmooth
|
||||
sfFloatRect_Offset
|
||||
sfFloatRect_Contains
|
||||
sfFloatRect_Intersects
|
||||
sfIntRect_Offset
|
||||
sfIntRect_Contains
|
||||
sfIntRect_Intersects
|
||||
sfPostFX_CreateFromFile
|
||||
sfPostFX_CreateFromMemory
|
||||
sfPostFX_Destroy
|
||||
sfPostFX_SetParameter1
|
||||
sfPostFX_SetParameter2
|
||||
sfPostFX_SetParameter3
|
||||
sfPostFX_SetParameter4
|
||||
sfPostFX_SetTexture
|
||||
sfPostFX_CanUsePostFX
|
||||
sfShape_Create
|
||||
sfShape_CreateLine
|
||||
sfShape_CreateRectangle
|
||||
sfShape_CreateCircle
|
||||
sfShape_Destroy
|
||||
sfShape_SetX
|
||||
sfShape_SetY
|
||||
sfShape_SetPosition
|
||||
sfShape_SetScaleX
|
||||
sfShape_SetScaleY
|
||||
sfShape_SetScale
|
||||
sfShape_SetRotation
|
||||
sfShape_SetCenter
|
||||
sfShape_SetColor
|
||||
sfShape_SetBlendMode
|
||||
sfShape_GetX
|
||||
sfShape_GetY
|
||||
sfShape_GetScaleX
|
||||
sfShape_GetScaleY
|
||||
sfShape_GetRotation
|
||||
sfShape_GetCenterX
|
||||
sfShape_GetCenterY
|
||||
sfShape_GetColor
|
||||
sfShape_GetBlendMode
|
||||
sfShape_Move
|
||||
sfShape_Scale
|
||||
sfShape_Rotate
|
||||
sfShape_TransformToLocal
|
||||
sfShape_TransformToGlobal
|
||||
sfShape_AddPoint
|
||||
sfShape_EnableFill
|
||||
sfShape_EnableOutline
|
||||
sfShape_SetOutlineWidth
|
||||
sfShape_GetOutlineWidth
|
||||
sfShape_GetNbPoints
|
||||
sfShape_GetPointPosition
|
||||
sfShape_GetPointColor
|
||||
sfShape_GetPointOutlineColor
|
||||
sfShape_SetPointPosition
|
||||
sfShape_SetPointColor
|
||||
sfShape_SetPointOutlineColor
|
||||
sfSprite_Create
|
||||
sfSprite_Destroy
|
||||
sfSprite_SetX
|
||||
sfSprite_SetY
|
||||
sfSprite_SetPosition
|
||||
sfSprite_SetScaleX
|
||||
sfSprite_SetScaleY
|
||||
sfSprite_SetScale
|
||||
sfSprite_SetRotation
|
||||
sfSprite_SetCenter
|
||||
sfSprite_SetColor
|
||||
sfSprite_SetBlendMode
|
||||
sfSprite_GetX
|
||||
sfSprite_GetY
|
||||
sfSprite_GetScaleX
|
||||
sfSprite_GetScaleY
|
||||
sfSprite_GetRotation
|
||||
sfSprite_GetCenterX
|
||||
sfSprite_GetCenterY
|
||||
sfSprite_GetColor
|
||||
sfSprite_GetBlendMode
|
||||
sfSprite_Move
|
||||
sfSprite_Scale
|
||||
sfSprite_Rotate
|
||||
sfSprite_TransformToLocal
|
||||
sfSprite_TransformToGlobal
|
||||
sfSprite_SetImage
|
||||
sfSprite_SetSubRect
|
||||
sfSprite_Resize
|
||||
sfSprite_FlipX
|
||||
sfSprite_FlipY
|
||||
sfSprite_GetImage
|
||||
sfSprite_GetSubRect
|
||||
sfSprite_GetWidth
|
||||
sfSprite_GetHeight
|
||||
sfSprite_GetPixel
|
||||
sfFont_Create
|
||||
sfFont_CreateFromFile
|
||||
sfFont_CreateFromMemory
|
||||
sfFont_Destroy
|
||||
sfFont_GetCharacterSize
|
||||
sfFont_GetDefaultFont
|
||||
sfString_Create
|
||||
sfString_Destroy
|
||||
sfString_SetX
|
||||
sfString_SetY
|
||||
sfString_SetPosition
|
||||
sfString_SetScaleX
|
||||
sfString_SetScaleY
|
||||
sfString_SetScale
|
||||
sfString_SetRotation
|
||||
sfString_SetCenter
|
||||
sfString_SetColor
|
||||
sfString_SetBlendMode
|
||||
sfString_GetX
|
||||
sfString_GetY
|
||||
sfString_GetScaleX
|
||||
sfString_GetScaleY
|
||||
sfString_GetRotation
|
||||
sfString_GetCenterX
|
||||
sfString_GetCenterY
|
||||
sfString_GetColor
|
||||
sfString_GetBlendMode
|
||||
sfString_Move
|
||||
sfString_Scale
|
||||
sfString_Rotate
|
||||
sfString_TransformToLocal
|
||||
sfString_TransformToGlobal
|
||||
sfString_SetText
|
||||
sfString_SetUnicodeText
|
||||
sfString_SetFont
|
||||
sfString_SetSize
|
||||
sfString_SetStyle
|
||||
sfString_GetUnicodeText
|
||||
sfString_GetText
|
||||
sfString_GetFont
|
||||
sfString_GetSize
|
||||
sfString_GetStyle
|
||||
sfString_GetCharacterPos
|
||||
sfString_GetRect
|
||||
sfRenderWindow_Create
|
||||
sfRenderWindow_CreateFromHandle
|
||||
sfRenderWindow_Destroy
|
||||
sfRenderWindow_Close
|
||||
sfRenderWindow_IsOpened
|
||||
sfRenderWindow_GetWidth
|
||||
sfRenderWindow_GetHeight
|
||||
sfRenderWindow_GetSettings
|
||||
sfRenderWindow_GetEvent
|
||||
sfRenderWindow_UseVerticalSync
|
||||
sfRenderWindow_ShowMouseCursor
|
||||
sfRenderWindow_SetCursorPosition
|
||||
sfRenderWindow_SetPosition
|
||||
sfRenderWindow_SetSize
|
||||
sfRenderWindow_Show
|
||||
sfRenderWindow_EnableKeyRepeat
|
||||
sfRenderWindow_SetIcon
|
||||
sfRenderWindow_SetActive
|
||||
sfRenderWindow_Display
|
||||
sfRenderWindow_GetInput
|
||||
sfRenderWindow_SetFramerateLimit
|
||||
sfRenderWindow_GetFrameTime
|
||||
sfRenderWindow_SetJoystickThreshold
|
||||
sfRenderWindow_DrawPostFX
|
||||
sfRenderWindow_DrawSprite
|
||||
sfRenderWindow_DrawString
|
||||
sfRenderWindow_DrawShape
|
||||
sfRenderWindow_Capture
|
||||
sfRenderWindow_Clear
|
||||
sfRenderWindow_SetView
|
||||
sfRenderWindow_GetView
|
||||
sfRenderWindow_GetDefaultView
|
||||
sfRenderWindow_ConvertCoords
|
||||
sfRenderWindow_PreserveOpenGLStates
|
||||
sfView_Create
|
||||
sfView_CreateFromRect
|
||||
sfView_Destroy
|
||||
sfView_SetCenter
|
||||
sfView_SetHalfSize
|
||||
sfView_SetFromRect
|
||||
sfView_GetCenterX
|
||||
sfView_GetCenterY
|
||||
sfView_GetHalfSizeX
|
||||
sfView_GetHalfSizeY
|
||||
sfView_GetRect
|
||||
sfView_Move
|
||||
sfView_Zoom
|
450
CSFML/VC2005/csfml-graphics.vcproj
Normal file
450
CSFML/VC2005/csfml-graphics.vcproj
Normal file
@ -0,0 +1,450 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="csfml-graphics"
|
||||
ProjectGUID="{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}"
|
||||
RootNamespace="csfml-graphics"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
<DefaultToolFile
|
||||
FileName="masm.rules"
|
||||
/>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-graphics-s-d.lib sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-graphics-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-graphics-s.lib sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-graphics.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-graphics-s-d.lib sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-graphics-s.lib sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\BlendMode.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Color.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Color.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-graphics-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-graphics.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Font.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Font.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Glyph.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Image.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Image.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\PostFX.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\PostFX.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Rect.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Rect.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\RenderWindow.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\RenderWindow.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Shape.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Shape.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Sprite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Sprite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\String.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\String.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\View.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\View.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
125
CSFML/VC2005/csfml-network-d.def
Normal file
125
CSFML/VC2005/csfml-network-d.def
Normal file
@ -0,0 +1,125 @@
|
||||
LIBRARY csfml-network-d
|
||||
EXPORTS
|
||||
sfFtpListingResponse_Destroy
|
||||
sfFtpListingResponse_IsOk
|
||||
sfFtpListingResponse_GetStatus
|
||||
sfFtpListingResponse_GetMessage
|
||||
sfFtpListingResponse_GetCount
|
||||
sfFtpListingResponse_GetFilename
|
||||
sfFtpDirectoryResponse_Destroy
|
||||
sfFtpDirectoryResponse_IsOk
|
||||
sfFtpDirectoryResponse_GetStatus
|
||||
sfFtpDirectoryResponse_GetMessage
|
||||
sfFtpDirectoryResponse_GetDirectory
|
||||
sfFtpResponse_Destroy
|
||||
sfFtpResponse_IsOk
|
||||
sfFtpResponse_GetStatus
|
||||
sfFtpResponse_GetMessage
|
||||
sfFtp_Create
|
||||
sfFtp_Destroy
|
||||
sfFtp_Connect
|
||||
sfFtp_LoginAnonymous
|
||||
sfFtp_Login
|
||||
sfFtp_Disconnect
|
||||
sfFtp_KeepAlive
|
||||
sfFtp_GetWorkingDirectory
|
||||
sfFtp_GetDirectoryListing
|
||||
sfFtp_ChangeDirectory
|
||||
sfFtp_ParentDirectory
|
||||
sfFtp_MakeDirectory
|
||||
sfFtp_DeleteDirectory
|
||||
sfFtp_RenameFile
|
||||
sfFtp_DeleteFile
|
||||
sfFtp_Download
|
||||
sfFtp_Upload
|
||||
sfHttpRequest_Create
|
||||
sfHttpRequest_Destroy
|
||||
sfHttpRequest_SetField
|
||||
sfHttpRequest_SetMethod
|
||||
sfHttpRequest_SetURI
|
||||
sfHttpRequest_SetHttpVersion
|
||||
sfHttpRequest_SetBody
|
||||
sfHttpResponse_Destroy
|
||||
sfHttpResponse_GetField
|
||||
sfHttpResponse_GetStatus
|
||||
sfHttpResponse_GetMajorVersion
|
||||
sfHttpResponse_GetMinorVersion
|
||||
sfHttpResponse_GetBody
|
||||
sfHttp_Create
|
||||
sfHttp_Destroy
|
||||
sfHttp_SetHost
|
||||
sfHttp_SendRequest
|
||||
sfIPAddress_FromString
|
||||
sfIPAddress_FromBytes
|
||||
sfIPAddress_FromInteger
|
||||
sfIPAddress_IsValid
|
||||
sfIPAddress_ToString
|
||||
sfIPAddress_ToInteger
|
||||
sfIPAddress_GetLocalAddress
|
||||
sfIPAddress_GetPublicAddress
|
||||
sfIPAddress_LocalHost
|
||||
sfSocketTCP_Create
|
||||
sfSocketTCP_Destroy
|
||||
sfSocketTCP_SetBlocking
|
||||
sfSocketTCP_Connect
|
||||
sfSocketTCP_Listen
|
||||
sfSocketTCP_Accept
|
||||
sfSocketTCP_Send
|
||||
sfSocketTCP_Receive
|
||||
sfSocketTCP_SendPacket
|
||||
sfSocketTCP_ReceivePacket
|
||||
sfSocketTCP_IsValid
|
||||
sfSocketUDP_Create
|
||||
sfSocketUDP_Destroy
|
||||
sfSocketUDP_SetBlocking
|
||||
sfSocketUDP_Bind
|
||||
sfSocketUDP_Unbind
|
||||
sfSocketUDP_Send
|
||||
sfSocketUDP_Receive
|
||||
sfSocketUDP_SendPacket
|
||||
sfSocketUDP_ReceivePacket
|
||||
sfSocketUDP_IsValid
|
||||
sfPacket_Create
|
||||
sfPacket_Destroy
|
||||
sfPacket_Append
|
||||
sfPacket_Clear
|
||||
sfPacket_GetData
|
||||
sfPacket_GetDataSize
|
||||
sfPacket_EndOfPacket
|
||||
sfPacket_CanRead
|
||||
sfPacket_ReadBool
|
||||
sfPacket_ReadInt8
|
||||
sfPacket_ReadUint8
|
||||
sfPacket_ReadInt16
|
||||
sfPacket_ReadUint16
|
||||
sfPacket_ReadInt32
|
||||
sfPacket_ReadUint32
|
||||
sfPacket_ReadFloat
|
||||
sfPacket_ReadDouble
|
||||
sfPacket_ReadString
|
||||
sfPacket_ReadWideString
|
||||
sfPacket_WriteBool
|
||||
sfPacket_WriteInt8
|
||||
sfPacket_WriteUint8
|
||||
sfPacket_WriteInt16
|
||||
sfPacket_WriteUint16
|
||||
sfPacket_WriteInt32
|
||||
sfPacket_WriteUint32
|
||||
sfPacket_WriteFloat
|
||||
sfPacket_WriteDouble
|
||||
sfPacket_WriteString
|
||||
sfPacket_WriteWideString
|
||||
sfSelectorTCP_Create
|
||||
sfSelectorTCP_Destroy
|
||||
sfSelectorTCP_Add
|
||||
sfSelectorTCP_Remove
|
||||
sfSelectorTCP_Clear
|
||||
sfSelectorTCP_Wait
|
||||
sfSelectorTCP_GetSocketReady
|
||||
sfSelectorUDP_Create
|
||||
sfSelectorUDP_Destroy
|
||||
sfSelectorUDP_Add
|
||||
sfSelectorUDP_Remove
|
||||
sfSelectorUDP_Clear
|
||||
sfSelectorUDP_Wait
|
||||
sfSelectorUDP_GetSocketReady
|
125
CSFML/VC2005/csfml-network.def
Normal file
125
CSFML/VC2005/csfml-network.def
Normal file
@ -0,0 +1,125 @@
|
||||
LIBRARY csfml-network
|
||||
EXPORTS
|
||||
sfFtpListingResponse_Destroy
|
||||
sfFtpListingResponse_IsOk
|
||||
sfFtpListingResponse_GetStatus
|
||||
sfFtpListingResponse_GetMessage
|
||||
sfFtpListingResponse_GetCount
|
||||
sfFtpListingResponse_GetFilename
|
||||
sfFtpDirectoryResponse_Destroy
|
||||
sfFtpDirectoryResponse_IsOk
|
||||
sfFtpDirectoryResponse_GetStatus
|
||||
sfFtpDirectoryResponse_GetMessage
|
||||
sfFtpDirectoryResponse_GetDirectory
|
||||
sfFtpResponse_Destroy
|
||||
sfFtpResponse_IsOk
|
||||
sfFtpResponse_GetStatus
|
||||
sfFtpResponse_GetMessage
|
||||
sfFtp_Create
|
||||
sfFtp_Destroy
|
||||
sfFtp_Connect
|
||||
sfFtp_LoginAnonymous
|
||||
sfFtp_Login
|
||||
sfFtp_Disconnect
|
||||
sfFtp_KeepAlive
|
||||
sfFtp_GetWorkingDirectory
|
||||
sfFtp_GetDirectoryListing
|
||||
sfFtp_ChangeDirectory
|
||||
sfFtp_ParentDirectory
|
||||
sfFtp_MakeDirectory
|
||||
sfFtp_DeleteDirectory
|
||||
sfFtp_RenameFile
|
||||
sfFtp_DeleteFile
|
||||
sfFtp_Download
|
||||
sfFtp_Upload
|
||||
sfHttpRequest_Create
|
||||
sfHttpRequest_Destroy
|
||||
sfHttpRequest_SetField
|
||||
sfHttpRequest_SetMethod
|
||||
sfHttpRequest_SetURI
|
||||
sfHttpRequest_SetHttpVersion
|
||||
sfHttpRequest_SetBody
|
||||
sfHttpResponse_Destroy
|
||||
sfHttpResponse_GetField
|
||||
sfHttpResponse_GetStatus
|
||||
sfHttpResponse_GetMajorVersion
|
||||
sfHttpResponse_GetMinorVersion
|
||||
sfHttpResponse_GetBody
|
||||
sfHttp_Create
|
||||
sfHttp_Destroy
|
||||
sfHttp_SetHost
|
||||
sfHttp_SendRequest
|
||||
sfIPAddress_FromString
|
||||
sfIPAddress_FromBytes
|
||||
sfIPAddress_FromInteger
|
||||
sfIPAddress_IsValid
|
||||
sfIPAddress_ToString
|
||||
sfIPAddress_ToInteger
|
||||
sfIPAddress_GetLocalAddress
|
||||
sfIPAddress_GetPublicAddress
|
||||
sfIPAddress_LocalHost
|
||||
sfSocketTCP_Create
|
||||
sfSocketTCP_Destroy
|
||||
sfSocketTCP_SetBlocking
|
||||
sfSocketTCP_Connect
|
||||
sfSocketTCP_Listen
|
||||
sfSocketTCP_Accept
|
||||
sfSocketTCP_Send
|
||||
sfSocketTCP_Receive
|
||||
sfSocketTCP_SendPacket
|
||||
sfSocketTCP_ReceivePacket
|
||||
sfSocketTCP_IsValid
|
||||
sfSocketUDP_Create
|
||||
sfSocketUDP_Destroy
|
||||
sfSocketUDP_SetBlocking
|
||||
sfSocketUDP_Bind
|
||||
sfSocketUDP_Unbind
|
||||
sfSocketUDP_Send
|
||||
sfSocketUDP_Receive
|
||||
sfSocketUDP_SendPacket
|
||||
sfSocketUDP_ReceivePacket
|
||||
sfSocketUDP_IsValid
|
||||
sfPacket_Create
|
||||
sfPacket_Destroy
|
||||
sfPacket_Append
|
||||
sfPacket_Clear
|
||||
sfPacket_GetData
|
||||
sfPacket_GetDataSize
|
||||
sfPacket_EndOfPacket
|
||||
sfPacket_CanRead
|
||||
sfPacket_ReadBool
|
||||
sfPacket_ReadInt8
|
||||
sfPacket_ReadUint8
|
||||
sfPacket_ReadInt16
|
||||
sfPacket_ReadUint16
|
||||
sfPacket_ReadInt32
|
||||
sfPacket_ReadUint32
|
||||
sfPacket_ReadFloat
|
||||
sfPacket_ReadDouble
|
||||
sfPacket_ReadString
|
||||
sfPacket_ReadWideString
|
||||
sfPacket_WriteBool
|
||||
sfPacket_WriteInt8
|
||||
sfPacket_WriteUint8
|
||||
sfPacket_WriteInt16
|
||||
sfPacket_WriteUint16
|
||||
sfPacket_WriteInt32
|
||||
sfPacket_WriteUint32
|
||||
sfPacket_WriteFloat
|
||||
sfPacket_WriteDouble
|
||||
sfPacket_WriteString
|
||||
sfPacket_WriteWideString
|
||||
sfSelectorTCP_Create
|
||||
sfSelectorTCP_Destroy
|
||||
sfSelectorTCP_Add
|
||||
sfSelectorTCP_Remove
|
||||
sfSelectorTCP_Clear
|
||||
sfSelectorTCP_Wait
|
||||
sfSelectorTCP_GetSocketReady
|
||||
sfSelectorUDP_Create
|
||||
sfSelectorUDP_Destroy
|
||||
sfSelectorUDP_Add
|
||||
sfSelectorUDP_Remove
|
||||
sfSelectorUDP_Clear
|
||||
sfSelectorUDP_Wait
|
||||
sfSelectorUDP_GetSocketReady
|
403
CSFML/VC2005/csfml-network.vcproj
Normal file
403
CSFML/VC2005/csfml-network.vcproj
Normal file
@ -0,0 +1,403 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="csfml-network"
|
||||
ProjectGUID="{823DDC98-42D5-4A38-88CF-9DC06C788AE4}"
|
||||
RootNamespace="csfml-network"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-network-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-network-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-network-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-network.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-network-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-network-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath=".\csfml-network-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-network.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Ftp.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Ftp.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Http.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Http.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\IPAddress.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\IPAddress.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Packet.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Packet.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Selector.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Selector.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\SocketStatus.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\SocketTCP.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\SocketTCP.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\SocketUDP.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\SocketUDP.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
20
CSFML/VC2005/csfml-system-d.def
Normal file
20
CSFML/VC2005/csfml-system-d.def
Normal file
@ -0,0 +1,20 @@
|
||||
LIBRARY csfml-system-d
|
||||
EXPORTS
|
||||
sfClock_Create
|
||||
sfClock_Destroy
|
||||
sfClock_GetTime
|
||||
sfClock_Reset
|
||||
sfMutex_Create
|
||||
sfMutex_Destroy
|
||||
sfMutex_Lock
|
||||
sfMutex_Unlock
|
||||
sfRandom_SetSeed
|
||||
sfRandom_GetSeed
|
||||
sfRandom_Float
|
||||
sfRandom_Int
|
||||
sfSleep
|
||||
sfThread_Create
|
||||
sfThread_Destroy
|
||||
sfThread_Launch
|
||||
sfThread_Wait
|
||||
sfThread_Terminate
|
20
CSFML/VC2005/csfml-system.def
Normal file
20
CSFML/VC2005/csfml-system.def
Normal file
@ -0,0 +1,20 @@
|
||||
LIBRARY csfml-system
|
||||
EXPORTS
|
||||
sfClock_Create
|
||||
sfClock_Destroy
|
||||
sfClock_GetTime
|
||||
sfClock_Reset
|
||||
sfMutex_Create
|
||||
sfMutex_Destroy
|
||||
sfMutex_Lock
|
||||
sfMutex_Unlock
|
||||
sfRandom_SetSeed
|
||||
sfRandom_GetSeed
|
||||
sfRandom_Float
|
||||
sfRandom_Int
|
||||
sfSleep
|
||||
sfThread_Create
|
||||
sfThread_Destroy
|
||||
sfThread_Launch
|
||||
sfThread_Wait
|
||||
sfThread_Terminate
|
383
CSFML/VC2005/csfml-system.vcproj
Normal file
383
CSFML/VC2005/csfml-system.vcproj
Normal file
@ -0,0 +1,383 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="csfml-system"
|
||||
ProjectGUID="{C061A27D-7CA0-4179-9869-672FA04A86A8}"
|
||||
RootNamespace="csfml-system"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-system-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-system.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Clock.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Clock.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-system-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-system.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Mutex.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Mutex.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Randomizer.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Randomizer.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Sleep.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Sleep.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Thread.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Thread.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
38
CSFML/VC2005/csfml-window-d.def
Normal file
38
CSFML/VC2005/csfml-window-d.def
Normal file
@ -0,0 +1,38 @@
|
||||
LIBRARY csfml-window-d
|
||||
EXPORTS
|
||||
sfInput_IsKeyDown
|
||||
sfInput_IsMouseButtonDown
|
||||
sfInput_IsJoystickButtonDown
|
||||
sfInput_GetMouseX
|
||||
sfInput_GetMouseY
|
||||
sfInput_GetJoystickAxis
|
||||
sfVideoMode_GetDesktopMode
|
||||
sfVideoMode_GetMode
|
||||
sfVideoMode_GetModesCount
|
||||
sfVideoMode_IsValid
|
||||
sfWindow_Create
|
||||
sfWindow_CreateFromHandle
|
||||
sfWindow_Close
|
||||
sfWindow_IsOpened
|
||||
sfWindow_Destroy
|
||||
sfWindow_GetWidth
|
||||
sfWindow_GetHeight
|
||||
sfWindow_GetSettings
|
||||
sfWindow_GetEvent
|
||||
sfWindow_UseVerticalSync
|
||||
sfWindow_ShowMouseCursor
|
||||
sfWindow_SetCursorPosition
|
||||
sfWindow_SetPosition
|
||||
sfWindow_SetSize
|
||||
sfWindow_Show
|
||||
sfWindow_EnableKeyRepeat
|
||||
sfWindow_SetIcon
|
||||
sfWindow_SetActive
|
||||
sfWindow_Display
|
||||
sfWindow_GetInput
|
||||
sfWindow_SetFramerateLimit
|
||||
sfWindow_GetFrameTime
|
||||
sfWindow_SetJoystickThreshold
|
||||
sfContext_Create
|
||||
sfContext_Destroy
|
||||
sfContext_SetActive
|
38
CSFML/VC2005/csfml-window.def
Normal file
38
CSFML/VC2005/csfml-window.def
Normal file
@ -0,0 +1,38 @@
|
||||
LIBRARY csfml-window
|
||||
EXPORTS
|
||||
sfInput_IsKeyDown
|
||||
sfInput_IsMouseButtonDown
|
||||
sfInput_IsJoystickButtonDown
|
||||
sfInput_GetMouseX
|
||||
sfInput_GetMouseY
|
||||
sfInput_GetJoystickAxis
|
||||
sfVideoMode_GetDesktopMode
|
||||
sfVideoMode_GetMode
|
||||
sfVideoMode_GetModesCount
|
||||
sfVideoMode_IsValid
|
||||
sfWindow_Create
|
||||
sfWindow_CreateFromHandle
|
||||
sfWindow_Close
|
||||
sfWindow_IsOpened
|
||||
sfWindow_Destroy
|
||||
sfWindow_GetWidth
|
||||
sfWindow_GetHeight
|
||||
sfWindow_GetSettings
|
||||
sfWindow_GetEvent
|
||||
sfWindow_UseVerticalSync
|
||||
sfWindow_ShowMouseCursor
|
||||
sfWindow_SetCursorPosition
|
||||
sfWindow_SetPosition
|
||||
sfWindow_SetSize
|
||||
sfWindow_Show
|
||||
sfWindow_EnableKeyRepeat
|
||||
sfWindow_SetIcon
|
||||
sfWindow_SetActive
|
||||
sfWindow_Display
|
||||
sfWindow_GetInput
|
||||
sfWindow_SetFramerateLimit
|
||||
sfWindow_GetFrameTime
|
||||
sfWindow_SetJoystickThreshold
|
||||
sfContext_Create
|
||||
sfContext_Destroy
|
||||
sfContext_SetActive
|
387
CSFML/VC2005/csfml-window.vcproj
Normal file
387
CSFML/VC2005/csfml-window.vcproj
Normal file
@ -0,0 +1,387 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="8,00"
|
||||
Name="csfml-window"
|
||||
ProjectGUID="{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}"
|
||||
RootNamespace="csfml-window"
|
||||
Keyword="Win32Proj"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS;GLEW_BUILD"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-window-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS;GLEW_BUILD"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-window.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS;GLEW_STATIC"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS;GLEW_STATIC"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2005\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2005\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\Context.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Context.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-window-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-window.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Event.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\Input.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Input.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\VideoMode.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\VideoMode.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\Window.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Window.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\WindowHandle.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
98
CSFML/VC2008/CSFML.sln
Normal file
98
CSFML/VC2008/CSFML.sln
Normal file
@ -0,0 +1,98 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 10.00
|
||||
# Visual C++ Express 2008
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-audio", "csfml-audio.vcproj", "{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8} = {C061A27D-7CA0-4179-9869-672FA04A86A8}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-graphics", "csfml-graphics.vcproj", "{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED} = {0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8} = {C061A27D-7CA0-4179-9869-672FA04A86A8}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-network", "csfml-network.vcproj", "{823DDC98-42D5-4A38-88CF-9DC06C788AE4}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-system", "csfml-system.vcproj", "{C061A27D-7CA0-4179-9869-672FA04A86A8}"
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "csfml-window", "csfml-window.vcproj", "{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}"
|
||||
ProjectSection(ProjectDependencies) = postProject
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8} = {C061A27D-7CA0-4179-9869-672FA04A86A8}
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug DLL|Win32 = Debug DLL|Win32
|
||||
Debug static|Win32 = Debug static|Win32
|
||||
Debug|Win32 = Debug|Win32
|
||||
Release DLL|Win32 = Release DLL|Win32
|
||||
Release static|Win32 = Release static|Win32
|
||||
Release|Win32 = Release|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}.Release|Win32.Build.0 = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}.Release|Win32.Build.0 = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{823DDC98-42D5-4A38-88CF-9DC06C788AE4}.Release|Win32.Build.0 = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{C061A27D-7CA0-4179-9869-672FA04A86A8}.Release|Win32.Build.0 = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug DLL|Win32.ActiveCfg = Debug DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug DLL|Win32.Build.0 = Debug DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug static|Win32.ActiveCfg = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug static|Win32.Build.0 = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug|Win32.ActiveCfg = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Debug|Win32.Build.0 = Debug static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release DLL|Win32.ActiveCfg = Release DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release DLL|Win32.Build.0 = Release DLL|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release static|Win32.ActiveCfg = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release static|Win32.Build.0 = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release|Win32.ActiveCfg = Release static|Win32
|
||||
{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}.Release|Win32.Build.0 = Release static|Win32
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
EndGlobal
|
96
CSFML/VC2008/csfml-audio-d.def
Normal file
96
CSFML/VC2008/csfml-audio-d.def
Normal file
@ -0,0 +1,96 @@
|
||||
LIBRARY csfml-audio-d
|
||||
EXPORTS
|
||||
sfListener_SetGlobalVolume
|
||||
sfListener_GetGlobalVolume
|
||||
sfListener_SetPosition
|
||||
sfListener_GetPosition
|
||||
sfListener_SetTarget
|
||||
sfListener_GetTarget
|
||||
sfMusic_CreateFromFile
|
||||
sfMusic_CreateFromMemory
|
||||
sfMusic_Destroy
|
||||
sfMusic_SetLoop
|
||||
sfMusic_GetLoop
|
||||
sfMusic_GetDuration
|
||||
sfMusic_Play
|
||||
sfMusic_Pause
|
||||
sfMusic_Stop
|
||||
sfMusic_GetChannelsCount
|
||||
sfMusic_GetSampleRate
|
||||
sfMusic_GetStatus
|
||||
sfMusic_SetPitch
|
||||
sfMusic_SetVolume
|
||||
sfMusic_SetPosition
|
||||
sfMusic_SetMinDistance
|
||||
sfMusic_SetAttenuation
|
||||
sfMusic_GetPitch
|
||||
sfMusic_GetVolume
|
||||
sfMusic_GetPosition
|
||||
sfMusic_GetMinDistance
|
||||
sfMusic_GetAttenuation
|
||||
sfMusic_GetPlayingOffset
|
||||
sfSound_Create
|
||||
sfSound_Destroy
|
||||
sfSound_Play
|
||||
sfSound_Pause
|
||||
sfSound_Stop
|
||||
sfSound_SetBuffer
|
||||
sfSound_GetBuffer
|
||||
sfSound_SetLoop
|
||||
sfSound_GetLoop
|
||||
sfSound_GetStatus
|
||||
sfSound_SetPitch
|
||||
sfSound_SetVolume
|
||||
sfSound_SetPosition
|
||||
sfSound_SetMinDistance
|
||||
sfSound_SetAttenuation
|
||||
sfSound_SetPlayingOffset
|
||||
sfSound_GetPitch
|
||||
sfSound_GetVolume
|
||||
sfSound_GetPosition
|
||||
sfSound_GetPlayingOffset
|
||||
sfSound_GetMinDistance
|
||||
sfSound_GetAttenuation
|
||||
sfSoundBuffer_CreateFromFile
|
||||
sfSoundBuffer_CreateFromMemory
|
||||
sfSoundBuffer_CreateFromSamples
|
||||
sfSoundBuffer_Destroy
|
||||
sfSoundBuffer_SaveToFile
|
||||
sfSoundBuffer_GetSamples
|
||||
sfSoundBuffer_GetSamplesCount
|
||||
sfSoundBuffer_GetSampleRate
|
||||
sfSoundBuffer_GetChannelsCount
|
||||
sfSoundBuffer_GetDuration
|
||||
sfSoundBufferRecorder_Create
|
||||
sfSoundBufferRecorder_Destroy
|
||||
sfSoundBufferRecorder_Start
|
||||
sfSoundBufferRecorder_Stop
|
||||
sfSoundBufferRecorder_GetSampleRate
|
||||
sfSoundBufferRecorder_GetBuffer
|
||||
sfSoundRecorder_Create
|
||||
sfSoundRecorder_Destroy
|
||||
sfSoundRecorder_Start
|
||||
sfSoundRecorder_Stop
|
||||
sfSoundRecorder_GetSampleRate
|
||||
sfSoundRecorder_CanCapture
|
||||
sfSoundStream_Create
|
||||
sfSoundStream_Destroy
|
||||
sfSoundStream_Play
|
||||
sfSoundStream_Pause
|
||||
sfSoundStream_Stop
|
||||
sfSoundStream_GetStatus
|
||||
sfSoundStream_GetChannelsCount
|
||||
sfSoundStream_GetSampleRate
|
||||
sfSoundStream_SetPitch
|
||||
sfSoundStream_SetVolume
|
||||
sfSoundStream_SetPosition
|
||||
sfSoundStream_SetMinDistance
|
||||
sfSoundStream_SetAttenuation
|
||||
sfSoundStream_SetLoop
|
||||
sfSoundStream_GetPitch
|
||||
sfSoundStream_GetVolume
|
||||
sfSoundStream_GetPosition
|
||||
sfSoundStream_GetMinDistance
|
||||
sfSoundStream_GetAttenuation
|
||||
sfSoundStream_GetLoop
|
||||
sfSoundStream_GetPlayingOffset
|
96
CSFML/VC2008/csfml-audio.def
Normal file
96
CSFML/VC2008/csfml-audio.def
Normal file
@ -0,0 +1,96 @@
|
||||
LIBRARY csfml-audio
|
||||
EXPORTS
|
||||
sfListener_SetGlobalVolume
|
||||
sfListener_GetGlobalVolume
|
||||
sfListener_SetPosition
|
||||
sfListener_GetPosition
|
||||
sfListener_SetTarget
|
||||
sfListener_GetTarget
|
||||
sfMusic_CreateFromFile
|
||||
sfMusic_CreateFromMemory
|
||||
sfMusic_Destroy
|
||||
sfMusic_SetLoop
|
||||
sfMusic_GetLoop
|
||||
sfMusic_GetDuration
|
||||
sfMusic_Play
|
||||
sfMusic_Pause
|
||||
sfMusic_Stop
|
||||
sfMusic_GetChannelsCount
|
||||
sfMusic_GetSampleRate
|
||||
sfMusic_GetStatus
|
||||
sfMusic_SetPitch
|
||||
sfMusic_SetVolume
|
||||
sfMusic_SetPosition
|
||||
sfMusic_SetMinDistance
|
||||
sfMusic_SetAttenuation
|
||||
sfMusic_GetPitch
|
||||
sfMusic_GetVolume
|
||||
sfMusic_GetPosition
|
||||
sfMusic_GetMinDistance
|
||||
sfMusic_GetAttenuation
|
||||
sfMusic_GetPlayingOffset
|
||||
sfSound_Create
|
||||
sfSound_Destroy
|
||||
sfSound_Play
|
||||
sfSound_Pause
|
||||
sfSound_Stop
|
||||
sfSound_SetBuffer
|
||||
sfSound_GetBuffer
|
||||
sfSound_SetLoop
|
||||
sfSound_GetLoop
|
||||
sfSound_GetStatus
|
||||
sfSound_SetPitch
|
||||
sfSound_SetVolume
|
||||
sfSound_SetPosition
|
||||
sfSound_SetMinDistance
|
||||
sfSound_SetAttenuation
|
||||
sfSound_SetPlayingOffset
|
||||
sfSound_GetPitch
|
||||
sfSound_GetVolume
|
||||
sfSound_GetPosition
|
||||
sfSound_GetPlayingOffset
|
||||
sfSound_GetMinDistance
|
||||
sfSound_GetAttenuation
|
||||
sfSoundBuffer_CreateFromFile
|
||||
sfSoundBuffer_CreateFromMemory
|
||||
sfSoundBuffer_CreateFromSamples
|
||||
sfSoundBuffer_Destroy
|
||||
sfSoundBuffer_SaveToFile
|
||||
sfSoundBuffer_GetSamples
|
||||
sfSoundBuffer_GetSamplesCount
|
||||
sfSoundBuffer_GetSampleRate
|
||||
sfSoundBuffer_GetChannelsCount
|
||||
sfSoundBuffer_GetDuration
|
||||
sfSoundBufferRecorder_Create
|
||||
sfSoundBufferRecorder_Destroy
|
||||
sfSoundBufferRecorder_Start
|
||||
sfSoundBufferRecorder_Stop
|
||||
sfSoundBufferRecorder_GetSampleRate
|
||||
sfSoundBufferRecorder_GetBuffer
|
||||
sfSoundRecorder_Create
|
||||
sfSoundRecorder_Destroy
|
||||
sfSoundRecorder_Start
|
||||
sfSoundRecorder_Stop
|
||||
sfSoundRecorder_GetSampleRate
|
||||
sfSoundRecorder_CanCapture
|
||||
sfSoundStream_Create
|
||||
sfSoundStream_Destroy
|
||||
sfSoundStream_Play
|
||||
sfSoundStream_Pause
|
||||
sfSoundStream_Stop
|
||||
sfSoundStream_GetStatus
|
||||
sfSoundStream_GetChannelsCount
|
||||
sfSoundStream_GetSampleRate
|
||||
sfSoundStream_SetPitch
|
||||
sfSoundStream_SetVolume
|
||||
sfSoundStream_SetPosition
|
||||
sfSoundStream_SetMinDistance
|
||||
sfSoundStream_SetAttenuation
|
||||
sfSoundStream_SetLoop
|
||||
sfSoundStream_GetPitch
|
||||
sfSoundStream_GetVolume
|
||||
sfSoundStream_GetPosition
|
||||
sfSoundStream_GetMinDistance
|
||||
sfSoundStream_GetAttenuation
|
||||
sfSoundStream_GetLoop
|
||||
sfSoundStream_GetPlayingOffset
|
406
CSFML/VC2008/csfml-audio.vcproj
Normal file
406
CSFML/VC2008/csfml-audio.vcproj
Normal file
@ -0,0 +1,406 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9,00"
|
||||
Name="csfml-audio"
|
||||
ProjectGUID="{B1BDA469-E6A7-4AF7-BDF9-EDDD7AD979A2}"
|
||||
RootNamespace="csfml-audio"
|
||||
Keyword="Win32Proj"
|
||||
TargetFrameworkVersion="131072"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-audio-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-audio-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-audio-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-audio.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-audio-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-audio-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath=".\csfml-audio-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-audio.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\Listener.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\Listener.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\Music.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\Music.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\Sound.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\Sound.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundBuffer.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundBuffer.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundBufferRecorder.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundBufferRecorder.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundRecorder.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundRecorder.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundStatus.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Audio\SoundStream.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Audio\SoundStream.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
215
CSFML/VC2008/csfml-graphics-d.def
Normal file
215
CSFML/VC2008/csfml-graphics-d.def
Normal file
@ -0,0 +1,215 @@
|
||||
LIBRARY csfml-graphics-d
|
||||
EXPORTS
|
||||
sfBlack
|
||||
sfWhite
|
||||
sfRed
|
||||
sfGreen
|
||||
sfBlue
|
||||
sfYellow
|
||||
sfMagenta
|
||||
sfCyan
|
||||
sfColor_FromRGB
|
||||
sfColor_FromRGBA
|
||||
sfColor_Add
|
||||
sfColor_Modulate
|
||||
sfImage_Create
|
||||
sfImage_CreateFromColor
|
||||
sfImage_CreateFromPixels
|
||||
sfImage_CreateFromFile
|
||||
sfImage_CreateFromMemory
|
||||
sfImage_Destroy
|
||||
sfImage_SaveToFile
|
||||
sfImage_CreateMaskFromColor
|
||||
sfImage_Copy
|
||||
sfImage_CopyScreen
|
||||
sfImage_SetPixel
|
||||
sfImage_GetPixel
|
||||
sfImage_GetPixelsPtr
|
||||
sfImage_Bind
|
||||
sfImage_SetSmooth
|
||||
sfImage_GetWidth
|
||||
sfImage_GetHeight
|
||||
sfImage_IsSmooth
|
||||
sfFloatRect_Offset
|
||||
sfFloatRect_Contains
|
||||
sfFloatRect_Intersects
|
||||
sfIntRect_Offset
|
||||
sfIntRect_Contains
|
||||
sfIntRect_Intersects
|
||||
sfPostFX_CreateFromFile
|
||||
sfPostFX_CreateFromMemory
|
||||
sfPostFX_Destroy
|
||||
sfPostFX_SetParameter1
|
||||
sfPostFX_SetParameter2
|
||||
sfPostFX_SetParameter3
|
||||
sfPostFX_SetParameter4
|
||||
sfPostFX_SetTexture
|
||||
sfPostFX_CanUsePostFX
|
||||
sfShape_Create
|
||||
sfShape_CreateLine
|
||||
sfShape_CreateRectangle
|
||||
sfShape_CreateCircle
|
||||
sfShape_Destroy
|
||||
sfShape_SetX
|
||||
sfShape_SetY
|
||||
sfShape_SetPosition
|
||||
sfShape_SetScaleX
|
||||
sfShape_SetScaleY
|
||||
sfShape_SetScale
|
||||
sfShape_SetRotation
|
||||
sfShape_SetCenter
|
||||
sfShape_SetColor
|
||||
sfShape_SetBlendMode
|
||||
sfShape_GetX
|
||||
sfShape_GetY
|
||||
sfShape_GetScaleX
|
||||
sfShape_GetScaleY
|
||||
sfShape_GetRotation
|
||||
sfShape_GetCenterX
|
||||
sfShape_GetCenterY
|
||||
sfShape_GetColor
|
||||
sfShape_GetBlendMode
|
||||
sfShape_Move
|
||||
sfShape_Scale
|
||||
sfShape_Rotate
|
||||
sfShape_TransformToLocal
|
||||
sfShape_TransformToGlobal
|
||||
sfShape_AddPoint
|
||||
sfShape_EnableFill
|
||||
sfShape_EnableOutline
|
||||
sfShape_SetOutlineWidth
|
||||
sfShape_GetOutlineWidth
|
||||
sfShape_GetNbPoints
|
||||
sfShape_GetPointPosition
|
||||
sfShape_GetPointColor
|
||||
sfShape_GetPointOutlineColor
|
||||
sfShape_SetPointPosition
|
||||
sfShape_SetPointColor
|
||||
sfShape_SetPointOutlineColor
|
||||
sfSprite_Create
|
||||
sfSprite_Destroy
|
||||
sfSprite_SetX
|
||||
sfSprite_SetY
|
||||
sfSprite_SetPosition
|
||||
sfSprite_SetScaleX
|
||||
sfSprite_SetScaleY
|
||||
sfSprite_SetScale
|
||||
sfSprite_SetRotation
|
||||
sfSprite_SetCenter
|
||||
sfSprite_SetColor
|
||||
sfSprite_SetBlendMode
|
||||
sfSprite_GetX
|
||||
sfSprite_GetY
|
||||
sfSprite_GetScaleX
|
||||
sfSprite_GetScaleY
|
||||
sfSprite_GetRotation
|
||||
sfSprite_GetCenterX
|
||||
sfSprite_GetCenterY
|
||||
sfSprite_GetColor
|
||||
sfSprite_GetBlendMode
|
||||
sfSprite_Move
|
||||
sfSprite_Scale
|
||||
sfSprite_Rotate
|
||||
sfSprite_TransformToLocal
|
||||
sfSprite_TransformToGlobal
|
||||
sfSprite_SetImage
|
||||
sfSprite_SetSubRect
|
||||
sfSprite_Resize
|
||||
sfSprite_FlipX
|
||||
sfSprite_FlipY
|
||||
sfSprite_GetImage
|
||||
sfSprite_GetSubRect
|
||||
sfSprite_GetWidth
|
||||
sfSprite_GetHeight
|
||||
sfSprite_GetPixel
|
||||
sfFont_Create
|
||||
sfFont_CreateFromFile
|
||||
sfFont_CreateFromMemory
|
||||
sfFont_Destroy
|
||||
sfFont_GetCharacterSize
|
||||
sfFont_GetDefaultFont
|
||||
sfString_Create
|
||||
sfString_Destroy
|
||||
sfString_SetX
|
||||
sfString_SetY
|
||||
sfString_SetPosition
|
||||
sfString_SetScaleX
|
||||
sfString_SetScaleY
|
||||
sfString_SetScale
|
||||
sfString_SetRotation
|
||||
sfString_SetCenter
|
||||
sfString_SetColor
|
||||
sfString_SetBlendMode
|
||||
sfString_GetX
|
||||
sfString_GetY
|
||||
sfString_GetScaleX
|
||||
sfString_GetScaleY
|
||||
sfString_GetRotation
|
||||
sfString_GetCenterX
|
||||
sfString_GetCenterY
|
||||
sfString_GetColor
|
||||
sfString_GetBlendMode
|
||||
sfString_Move
|
||||
sfString_Scale
|
||||
sfString_Rotate
|
||||
sfString_TransformToLocal
|
||||
sfString_TransformToGlobal
|
||||
sfString_SetText
|
||||
sfString_SetUnicodeText
|
||||
sfString_SetFont
|
||||
sfString_SetSize
|
||||
sfString_SetStyle
|
||||
sfString_GetUnicodeText
|
||||
sfString_GetText
|
||||
sfString_GetFont
|
||||
sfString_GetSize
|
||||
sfString_GetStyle
|
||||
sfString_GetCharacterPos
|
||||
sfString_GetRect
|
||||
sfRenderWindow_Create
|
||||
sfRenderWindow_CreateFromHandle
|
||||
sfRenderWindow_Destroy
|
||||
sfRenderWindow_Close
|
||||
sfRenderWindow_IsOpened
|
||||
sfRenderWindow_GetWidth
|
||||
sfRenderWindow_GetHeight
|
||||
sfRenderWindow_GetSettings
|
||||
sfRenderWindow_GetEvent
|
||||
sfRenderWindow_UseVerticalSync
|
||||
sfRenderWindow_ShowMouseCursor
|
||||
sfRenderWindow_SetCursorPosition
|
||||
sfRenderWindow_SetPosition
|
||||
sfRenderWindow_SetSize
|
||||
sfRenderWindow_Show
|
||||
sfRenderWindow_EnableKeyRepeat
|
||||
sfRenderWindow_SetIcon
|
||||
sfRenderWindow_SetActive
|
||||
sfRenderWindow_Display
|
||||
sfRenderWindow_GetInput
|
||||
sfRenderWindow_SetFramerateLimit
|
||||
sfRenderWindow_GetFrameTime
|
||||
sfRenderWindow_SetJoystickThreshold
|
||||
sfRenderWindow_DrawPostFX
|
||||
sfRenderWindow_DrawSprite
|
||||
sfRenderWindow_DrawString
|
||||
sfRenderWindow_DrawShape
|
||||
sfRenderWindow_Capture
|
||||
sfRenderWindow_Clear
|
||||
sfRenderWindow_SetView
|
||||
sfRenderWindow_GetView
|
||||
sfRenderWindow_GetDefaultView
|
||||
sfRenderWindow_ConvertCoords
|
||||
sfRenderWindow_PreserveOpenGLStates
|
||||
sfView_Create
|
||||
sfView_CreateFromRect
|
||||
sfView_Destroy
|
||||
sfView_SetCenter
|
||||
sfView_SetHalfSize
|
||||
sfView_SetFromRect
|
||||
sfView_GetCenterX
|
||||
sfView_GetCenterY
|
||||
sfView_GetHalfSizeX
|
||||
sfView_GetHalfSizeY
|
||||
sfView_GetRect
|
||||
sfView_Move
|
||||
sfView_Zoom
|
215
CSFML/VC2008/csfml-graphics.def
Normal file
215
CSFML/VC2008/csfml-graphics.def
Normal file
@ -0,0 +1,215 @@
|
||||
LIBRARY csfml-graphics
|
||||
EXPORTS
|
||||
sfBlack
|
||||
sfWhite
|
||||
sfRed
|
||||
sfGreen
|
||||
sfBlue
|
||||
sfYellow
|
||||
sfMagenta
|
||||
sfCyan
|
||||
sfColor_FromRGB
|
||||
sfColor_FromRGBA
|
||||
sfColor_Add
|
||||
sfColor_Modulate
|
||||
sfImage_Create
|
||||
sfImage_CreateFromColor
|
||||
sfImage_CreateFromPixels
|
||||
sfImage_CreateFromFile
|
||||
sfImage_CreateFromMemory
|
||||
sfImage_Destroy
|
||||
sfImage_SaveToFile
|
||||
sfImage_CreateMaskFromColor
|
||||
sfImage_Copy
|
||||
sfImage_CopyScreen
|
||||
sfImage_SetPixel
|
||||
sfImage_GetPixel
|
||||
sfImage_GetPixelsPtr
|
||||
sfImage_Bind
|
||||
sfImage_SetSmooth
|
||||
sfImage_GetWidth
|
||||
sfImage_GetHeight
|
||||
sfImage_IsSmooth
|
||||
sfFloatRect_Offset
|
||||
sfFloatRect_Contains
|
||||
sfFloatRect_Intersects
|
||||
sfIntRect_Offset
|
||||
sfIntRect_Contains
|
||||
sfIntRect_Intersects
|
||||
sfPostFX_CreateFromFile
|
||||
sfPostFX_CreateFromMemory
|
||||
sfPostFX_Destroy
|
||||
sfPostFX_SetParameter1
|
||||
sfPostFX_SetParameter2
|
||||
sfPostFX_SetParameter3
|
||||
sfPostFX_SetParameter4
|
||||
sfPostFX_SetTexture
|
||||
sfPostFX_CanUsePostFX
|
||||
sfShape_Create
|
||||
sfShape_CreateLine
|
||||
sfShape_CreateRectangle
|
||||
sfShape_CreateCircle
|
||||
sfShape_Destroy
|
||||
sfShape_SetX
|
||||
sfShape_SetY
|
||||
sfShape_SetPosition
|
||||
sfShape_SetScaleX
|
||||
sfShape_SetScaleY
|
||||
sfShape_SetScale
|
||||
sfShape_SetRotation
|
||||
sfShape_SetCenter
|
||||
sfShape_SetColor
|
||||
sfShape_SetBlendMode
|
||||
sfShape_GetX
|
||||
sfShape_GetY
|
||||
sfShape_GetScaleX
|
||||
sfShape_GetScaleY
|
||||
sfShape_GetRotation
|
||||
sfShape_GetCenterX
|
||||
sfShape_GetCenterY
|
||||
sfShape_GetColor
|
||||
sfShape_GetBlendMode
|
||||
sfShape_Move
|
||||
sfShape_Scale
|
||||
sfShape_Rotate
|
||||
sfShape_TransformToLocal
|
||||
sfShape_TransformToGlobal
|
||||
sfShape_AddPoint
|
||||
sfShape_EnableFill
|
||||
sfShape_EnableOutline
|
||||
sfShape_SetOutlineWidth
|
||||
sfShape_GetOutlineWidth
|
||||
sfShape_GetNbPoints
|
||||
sfShape_GetPointPosition
|
||||
sfShape_GetPointColor
|
||||
sfShape_GetPointOutlineColor
|
||||
sfShape_SetPointPosition
|
||||
sfShape_SetPointColor
|
||||
sfShape_SetPointOutlineColor
|
||||
sfSprite_Create
|
||||
sfSprite_Destroy
|
||||
sfSprite_SetX
|
||||
sfSprite_SetY
|
||||
sfSprite_SetPosition
|
||||
sfSprite_SetScaleX
|
||||
sfSprite_SetScaleY
|
||||
sfSprite_SetScale
|
||||
sfSprite_SetRotation
|
||||
sfSprite_SetCenter
|
||||
sfSprite_SetColor
|
||||
sfSprite_SetBlendMode
|
||||
sfSprite_GetX
|
||||
sfSprite_GetY
|
||||
sfSprite_GetScaleX
|
||||
sfSprite_GetScaleY
|
||||
sfSprite_GetRotation
|
||||
sfSprite_GetCenterX
|
||||
sfSprite_GetCenterY
|
||||
sfSprite_GetColor
|
||||
sfSprite_GetBlendMode
|
||||
sfSprite_Move
|
||||
sfSprite_Scale
|
||||
sfSprite_Rotate
|
||||
sfSprite_TransformToLocal
|
||||
sfSprite_TransformToGlobal
|
||||
sfSprite_SetImage
|
||||
sfSprite_SetSubRect
|
||||
sfSprite_Resize
|
||||
sfSprite_FlipX
|
||||
sfSprite_FlipY
|
||||
sfSprite_GetImage
|
||||
sfSprite_GetSubRect
|
||||
sfSprite_GetWidth
|
||||
sfSprite_GetHeight
|
||||
sfSprite_GetPixel
|
||||
sfFont_Create
|
||||
sfFont_CreateFromFile
|
||||
sfFont_CreateFromMemory
|
||||
sfFont_Destroy
|
||||
sfFont_GetCharacterSize
|
||||
sfFont_GetDefaultFont
|
||||
sfString_Create
|
||||
sfString_Destroy
|
||||
sfString_SetX
|
||||
sfString_SetY
|
||||
sfString_SetPosition
|
||||
sfString_SetScaleX
|
||||
sfString_SetScaleY
|
||||
sfString_SetScale
|
||||
sfString_SetRotation
|
||||
sfString_SetCenter
|
||||
sfString_SetColor
|
||||
sfString_SetBlendMode
|
||||
sfString_GetX
|
||||
sfString_GetY
|
||||
sfString_GetScaleX
|
||||
sfString_GetScaleY
|
||||
sfString_GetRotation
|
||||
sfString_GetCenterX
|
||||
sfString_GetCenterY
|
||||
sfString_GetColor
|
||||
sfString_GetBlendMode
|
||||
sfString_Move
|
||||
sfString_Scale
|
||||
sfString_Rotate
|
||||
sfString_TransformToLocal
|
||||
sfString_TransformToGlobal
|
||||
sfString_SetText
|
||||
sfString_SetUnicodeText
|
||||
sfString_SetFont
|
||||
sfString_SetSize
|
||||
sfString_SetStyle
|
||||
sfString_GetUnicodeText
|
||||
sfString_GetText
|
||||
sfString_GetFont
|
||||
sfString_GetSize
|
||||
sfString_GetStyle
|
||||
sfString_GetCharacterPos
|
||||
sfString_GetRect
|
||||
sfRenderWindow_Create
|
||||
sfRenderWindow_CreateFromHandle
|
||||
sfRenderWindow_Destroy
|
||||
sfRenderWindow_Close
|
||||
sfRenderWindow_IsOpened
|
||||
sfRenderWindow_GetWidth
|
||||
sfRenderWindow_GetHeight
|
||||
sfRenderWindow_GetSettings
|
||||
sfRenderWindow_GetEvent
|
||||
sfRenderWindow_UseVerticalSync
|
||||
sfRenderWindow_ShowMouseCursor
|
||||
sfRenderWindow_SetCursorPosition
|
||||
sfRenderWindow_SetPosition
|
||||
sfRenderWindow_SetSize
|
||||
sfRenderWindow_Show
|
||||
sfRenderWindow_EnableKeyRepeat
|
||||
sfRenderWindow_SetIcon
|
||||
sfRenderWindow_SetActive
|
||||
sfRenderWindow_Display
|
||||
sfRenderWindow_GetInput
|
||||
sfRenderWindow_SetFramerateLimit
|
||||
sfRenderWindow_GetFrameTime
|
||||
sfRenderWindow_SetJoystickThreshold
|
||||
sfRenderWindow_DrawPostFX
|
||||
sfRenderWindow_DrawSprite
|
||||
sfRenderWindow_DrawString
|
||||
sfRenderWindow_DrawShape
|
||||
sfRenderWindow_Capture
|
||||
sfRenderWindow_Clear
|
||||
sfRenderWindow_SetView
|
||||
sfRenderWindow_GetView
|
||||
sfRenderWindow_GetDefaultView
|
||||
sfRenderWindow_ConvertCoords
|
||||
sfRenderWindow_PreserveOpenGLStates
|
||||
sfView_Create
|
||||
sfView_CreateFromRect
|
||||
sfView_Destroy
|
||||
sfView_SetCenter
|
||||
sfView_SetHalfSize
|
||||
sfView_SetFromRect
|
||||
sfView_GetCenterX
|
||||
sfView_GetCenterY
|
||||
sfView_GetHalfSizeX
|
||||
sfView_GetHalfSizeY
|
||||
sfView_GetRect
|
||||
sfView_Move
|
||||
sfView_Zoom
|
445
CSFML/VC2008/csfml-graphics.vcproj
Normal file
445
CSFML/VC2008/csfml-graphics.vcproj
Normal file
@ -0,0 +1,445 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9,00"
|
||||
Name="csfml-graphics"
|
||||
ProjectGUID="{FA4620B1-393A-4719-9BB4-3BC8CAA70C4B}"
|
||||
RootNamespace="csfml-graphics"
|
||||
Keyword="Win32Proj"
|
||||
TargetFrameworkVersion="131072"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
<DefaultToolFile
|
||||
FileName="masm.rules"
|
||||
/>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-graphics-s-d.lib sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-graphics-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-graphics-s.lib sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-graphics.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-graphics-s-d.lib sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="MASM"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4996"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-graphics-s.lib sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\BlendMode.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Color.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Color.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-graphics-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-graphics.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Font.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Font.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Image.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Image.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\PostFX.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\PostFX.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Rect.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Rect.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\RenderWindow.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\RenderWindow.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Shape.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Shape.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\Sprite.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\Sprite.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\String.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\String.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Graphics\View.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Graphics\View.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
125
CSFML/VC2008/csfml-network-d.def
Normal file
125
CSFML/VC2008/csfml-network-d.def
Normal file
@ -0,0 +1,125 @@
|
||||
LIBRARY csfml-network-d
|
||||
EXPORTS
|
||||
sfFtpListingResponse_Destroy
|
||||
sfFtpListingResponse_IsOk
|
||||
sfFtpListingResponse_GetStatus
|
||||
sfFtpListingResponse_GetMessage
|
||||
sfFtpListingResponse_GetCount
|
||||
sfFtpListingResponse_GetFilename
|
||||
sfFtpDirectoryResponse_Destroy
|
||||
sfFtpDirectoryResponse_IsOk
|
||||
sfFtpDirectoryResponse_GetStatus
|
||||
sfFtpDirectoryResponse_GetMessage
|
||||
sfFtpDirectoryResponse_GetDirectory
|
||||
sfFtpResponse_Destroy
|
||||
sfFtpResponse_IsOk
|
||||
sfFtpResponse_GetStatus
|
||||
sfFtpResponse_GetMessage
|
||||
sfFtp_Create
|
||||
sfFtp_Destroy
|
||||
sfFtp_Connect
|
||||
sfFtp_LoginAnonymous
|
||||
sfFtp_Login
|
||||
sfFtp_Disconnect
|
||||
sfFtp_KeepAlive
|
||||
sfFtp_GetWorkingDirectory
|
||||
sfFtp_GetDirectoryListing
|
||||
sfFtp_ChangeDirectory
|
||||
sfFtp_ParentDirectory
|
||||
sfFtp_MakeDirectory
|
||||
sfFtp_DeleteDirectory
|
||||
sfFtp_RenameFile
|
||||
sfFtp_DeleteFile
|
||||
sfFtp_Download
|
||||
sfFtp_Upload
|
||||
sfHttpRequest_Create
|
||||
sfHttpRequest_Destroy
|
||||
sfHttpRequest_SetField
|
||||
sfHttpRequest_SetMethod
|
||||
sfHttpRequest_SetURI
|
||||
sfHttpRequest_SetHttpVersion
|
||||
sfHttpRequest_SetBody
|
||||
sfHttpResponse_Destroy
|
||||
sfHttpResponse_GetField
|
||||
sfHttpResponse_GetStatus
|
||||
sfHttpResponse_GetMajorVersion
|
||||
sfHttpResponse_GetMinorVersion
|
||||
sfHttpResponse_GetBody
|
||||
sfHttp_Create
|
||||
sfHttp_Destroy
|
||||
sfHttp_SetHost
|
||||
sfHttp_SendRequest
|
||||
sfIPAddress_FromString
|
||||
sfIPAddress_FromBytes
|
||||
sfIPAddress_FromInteger
|
||||
sfIPAddress_IsValid
|
||||
sfIPAddress_ToString
|
||||
sfIPAddress_ToInteger
|
||||
sfIPAddress_GetLocalAddress
|
||||
sfIPAddress_GetPublicAddress
|
||||
sfIPAddress_LocalHost
|
||||
sfSocketTCP_Create
|
||||
sfSocketTCP_Destroy
|
||||
sfSocketTCP_SetBlocking
|
||||
sfSocketTCP_Connect
|
||||
sfSocketTCP_Listen
|
||||
sfSocketTCP_Accept
|
||||
sfSocketTCP_Send
|
||||
sfSocketTCP_Receive
|
||||
sfSocketTCP_SendPacket
|
||||
sfSocketTCP_ReceivePacket
|
||||
sfSocketTCP_IsValid
|
||||
sfSocketUDP_Create
|
||||
sfSocketUDP_Destroy
|
||||
sfSocketUDP_SetBlocking
|
||||
sfSocketUDP_Bind
|
||||
sfSocketUDP_Unbind
|
||||
sfSocketUDP_Send
|
||||
sfSocketUDP_Receive
|
||||
sfSocketUDP_SendPacket
|
||||
sfSocketUDP_ReceivePacket
|
||||
sfSocketUDP_IsValid
|
||||
sfPacket_Create
|
||||
sfPacket_Destroy
|
||||
sfPacket_Append
|
||||
sfPacket_Clear
|
||||
sfPacket_GetData
|
||||
sfPacket_GetDataSize
|
||||
sfPacket_EndOfPacket
|
||||
sfPacket_CanRead
|
||||
sfPacket_ReadBool
|
||||
sfPacket_ReadInt8
|
||||
sfPacket_ReadUint8
|
||||
sfPacket_ReadInt16
|
||||
sfPacket_ReadUint16
|
||||
sfPacket_ReadInt32
|
||||
sfPacket_ReadUint32
|
||||
sfPacket_ReadFloat
|
||||
sfPacket_ReadDouble
|
||||
sfPacket_ReadString
|
||||
sfPacket_ReadWideString
|
||||
sfPacket_WriteBool
|
||||
sfPacket_WriteInt8
|
||||
sfPacket_WriteUint8
|
||||
sfPacket_WriteInt16
|
||||
sfPacket_WriteUint16
|
||||
sfPacket_WriteInt32
|
||||
sfPacket_WriteUint32
|
||||
sfPacket_WriteFloat
|
||||
sfPacket_WriteDouble
|
||||
sfPacket_WriteString
|
||||
sfPacket_WriteWideString
|
||||
sfSelectorTCP_Create
|
||||
sfSelectorTCP_Destroy
|
||||
sfSelectorTCP_Add
|
||||
sfSelectorTCP_Remove
|
||||
sfSelectorTCP_Clear
|
||||
sfSelectorTCP_Wait
|
||||
sfSelectorTCP_GetSocketReady
|
||||
sfSelectorUDP_Create
|
||||
sfSelectorUDP_Destroy
|
||||
sfSelectorUDP_Add
|
||||
sfSelectorUDP_Remove
|
||||
sfSelectorUDP_Clear
|
||||
sfSelectorUDP_Wait
|
||||
sfSelectorUDP_GetSocketReady
|
125
CSFML/VC2008/csfml-network.def
Normal file
125
CSFML/VC2008/csfml-network.def
Normal file
@ -0,0 +1,125 @@
|
||||
LIBRARY csfml-network
|
||||
EXPORTS
|
||||
sfFtpListingResponse_Destroy
|
||||
sfFtpListingResponse_IsOk
|
||||
sfFtpListingResponse_GetStatus
|
||||
sfFtpListingResponse_GetMessage
|
||||
sfFtpListingResponse_GetCount
|
||||
sfFtpListingResponse_GetFilename
|
||||
sfFtpDirectoryResponse_Destroy
|
||||
sfFtpDirectoryResponse_IsOk
|
||||
sfFtpDirectoryResponse_GetStatus
|
||||
sfFtpDirectoryResponse_GetMessage
|
||||
sfFtpDirectoryResponse_GetDirectory
|
||||
sfFtpResponse_Destroy
|
||||
sfFtpResponse_IsOk
|
||||
sfFtpResponse_GetStatus
|
||||
sfFtpResponse_GetMessage
|
||||
sfFtp_Create
|
||||
sfFtp_Destroy
|
||||
sfFtp_Connect
|
||||
sfFtp_LoginAnonymous
|
||||
sfFtp_Login
|
||||
sfFtp_Disconnect
|
||||
sfFtp_KeepAlive
|
||||
sfFtp_GetWorkingDirectory
|
||||
sfFtp_GetDirectoryListing
|
||||
sfFtp_ChangeDirectory
|
||||
sfFtp_ParentDirectory
|
||||
sfFtp_MakeDirectory
|
||||
sfFtp_DeleteDirectory
|
||||
sfFtp_RenameFile
|
||||
sfFtp_DeleteFile
|
||||
sfFtp_Download
|
||||
sfFtp_Upload
|
||||
sfHttpRequest_Create
|
||||
sfHttpRequest_Destroy
|
||||
sfHttpRequest_SetField
|
||||
sfHttpRequest_SetMethod
|
||||
sfHttpRequest_SetURI
|
||||
sfHttpRequest_SetHttpVersion
|
||||
sfHttpRequest_SetBody
|
||||
sfHttpResponse_Destroy
|
||||
sfHttpResponse_GetField
|
||||
sfHttpResponse_GetStatus
|
||||
sfHttpResponse_GetMajorVersion
|
||||
sfHttpResponse_GetMinorVersion
|
||||
sfHttpResponse_GetBody
|
||||
sfHttp_Create
|
||||
sfHttp_Destroy
|
||||
sfHttp_SetHost
|
||||
sfHttp_SendRequest
|
||||
sfIPAddress_FromString
|
||||
sfIPAddress_FromBytes
|
||||
sfIPAddress_FromInteger
|
||||
sfIPAddress_IsValid
|
||||
sfIPAddress_ToString
|
||||
sfIPAddress_ToInteger
|
||||
sfIPAddress_GetLocalAddress
|
||||
sfIPAddress_GetPublicAddress
|
||||
sfIPAddress_LocalHost
|
||||
sfSocketTCP_Create
|
||||
sfSocketTCP_Destroy
|
||||
sfSocketTCP_SetBlocking
|
||||
sfSocketTCP_Connect
|
||||
sfSocketTCP_Listen
|
||||
sfSocketTCP_Accept
|
||||
sfSocketTCP_Send
|
||||
sfSocketTCP_Receive
|
||||
sfSocketTCP_SendPacket
|
||||
sfSocketTCP_ReceivePacket
|
||||
sfSocketTCP_IsValid
|
||||
sfSocketUDP_Create
|
||||
sfSocketUDP_Destroy
|
||||
sfSocketUDP_SetBlocking
|
||||
sfSocketUDP_Bind
|
||||
sfSocketUDP_Unbind
|
||||
sfSocketUDP_Send
|
||||
sfSocketUDP_Receive
|
||||
sfSocketUDP_SendPacket
|
||||
sfSocketUDP_ReceivePacket
|
||||
sfSocketUDP_IsValid
|
||||
sfPacket_Create
|
||||
sfPacket_Destroy
|
||||
sfPacket_Append
|
||||
sfPacket_Clear
|
||||
sfPacket_GetData
|
||||
sfPacket_GetDataSize
|
||||
sfPacket_EndOfPacket
|
||||
sfPacket_CanRead
|
||||
sfPacket_ReadBool
|
||||
sfPacket_ReadInt8
|
||||
sfPacket_ReadUint8
|
||||
sfPacket_ReadInt16
|
||||
sfPacket_ReadUint16
|
||||
sfPacket_ReadInt32
|
||||
sfPacket_ReadUint32
|
||||
sfPacket_ReadFloat
|
||||
sfPacket_ReadDouble
|
||||
sfPacket_ReadString
|
||||
sfPacket_ReadWideString
|
||||
sfPacket_WriteBool
|
||||
sfPacket_WriteInt8
|
||||
sfPacket_WriteUint8
|
||||
sfPacket_WriteInt16
|
||||
sfPacket_WriteUint16
|
||||
sfPacket_WriteInt32
|
||||
sfPacket_WriteUint32
|
||||
sfPacket_WriteFloat
|
||||
sfPacket_WriteDouble
|
||||
sfPacket_WriteString
|
||||
sfPacket_WriteWideString
|
||||
sfSelectorTCP_Create
|
||||
sfSelectorTCP_Destroy
|
||||
sfSelectorTCP_Add
|
||||
sfSelectorTCP_Remove
|
||||
sfSelectorTCP_Clear
|
||||
sfSelectorTCP_Wait
|
||||
sfSelectorTCP_GetSocketReady
|
||||
sfSelectorUDP_Create
|
||||
sfSelectorUDP_Destroy
|
||||
sfSelectorUDP_Add
|
||||
sfSelectorUDP_Remove
|
||||
sfSelectorUDP_Clear
|
||||
sfSelectorUDP_Wait
|
||||
sfSelectorUDP_GetSocketReady
|
402
CSFML/VC2008/csfml-network.vcproj
Normal file
402
CSFML/VC2008/csfml-network.vcproj
Normal file
@ -0,0 +1,402 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9,00"
|
||||
Name="csfml-network"
|
||||
ProjectGUID="{823DDC98-42D5-4A38-88CF-9DC06C788AE4}"
|
||||
RootNamespace="csfml-network"
|
||||
Keyword="Win32Proj"
|
||||
TargetFrameworkVersion="131072"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-network-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-network-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-network-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-network.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-network-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;_CRT_SECURE_NO_DEPRECATE;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-network-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath=".\csfml-network-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-network.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Ftp.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Ftp.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Http.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Http.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\IPAddress.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\IPAddress.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Packet.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Packet.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\Selector.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\Selector.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\SocketStatus.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\SocketTCP.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\SocketTCP.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Network\SocketUDP.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Network\SocketUDP.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
20
CSFML/VC2008/csfml-system-d.def
Normal file
20
CSFML/VC2008/csfml-system-d.def
Normal file
@ -0,0 +1,20 @@
|
||||
LIBRARY csfml-system-d
|
||||
EXPORTS
|
||||
sfClock_Create
|
||||
sfClock_Destroy
|
||||
sfClock_GetTime
|
||||
sfClock_Reset
|
||||
sfMutex_Create
|
||||
sfMutex_Destroy
|
||||
sfMutex_Lock
|
||||
sfMutex_Unlock
|
||||
sfRandom_SetSeed
|
||||
sfRandom_GetSeed
|
||||
sfRandom_Float
|
||||
sfRandom_Int
|
||||
sfSleep
|
||||
sfThread_Create
|
||||
sfThread_Destroy
|
||||
sfThread_Launch
|
||||
sfThread_Wait
|
||||
sfThread_Terminate
|
20
CSFML/VC2008/csfml-system.def
Normal file
20
CSFML/VC2008/csfml-system.def
Normal file
@ -0,0 +1,20 @@
|
||||
LIBRARY csfml-system
|
||||
EXPORTS
|
||||
sfClock_Create
|
||||
sfClock_Destroy
|
||||
sfClock_GetTime
|
||||
sfClock_Reset
|
||||
sfMutex_Create
|
||||
sfMutex_Destroy
|
||||
sfMutex_Lock
|
||||
sfMutex_Unlock
|
||||
sfRandom_SetSeed
|
||||
sfRandom_GetSeed
|
||||
sfRandom_Float
|
||||
sfRandom_Int
|
||||
sfSleep
|
||||
sfThread_Create
|
||||
sfThread_Destroy
|
||||
sfThread_Launch
|
||||
sfThread_Wait
|
||||
sfThread_Terminate
|
382
CSFML/VC2008/csfml-system.vcproj
Normal file
382
CSFML/VC2008/csfml-system.vcproj
Normal file
@ -0,0 +1,382 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9,00"
|
||||
Name="csfml-system"
|
||||
ProjectGUID="{C061A27D-7CA0-4179-9869-672FA04A86A8}"
|
||||
RootNamespace="csfml-system"
|
||||
Keyword="Win32Proj"
|
||||
TargetFrameworkVersion="131072"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-system-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-system.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Clock.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Clock.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-system-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-system.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Mutex.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Mutex.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Randomizer.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Randomizer.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Sleep.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Sleep.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\sfml\system\Thread.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\System\Thread.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
38
CSFML/VC2008/csfml-window-d.def
Normal file
38
CSFML/VC2008/csfml-window-d.def
Normal file
@ -0,0 +1,38 @@
|
||||
LIBRARY csfml-window-d
|
||||
EXPORTS
|
||||
sfInput_IsKeyDown
|
||||
sfInput_IsMouseButtonDown
|
||||
sfInput_IsJoystickButtonDown
|
||||
sfInput_GetMouseX
|
||||
sfInput_GetMouseY
|
||||
sfInput_GetJoystickAxis
|
||||
sfVideoMode_GetDesktopMode
|
||||
sfVideoMode_GetMode
|
||||
sfVideoMode_GetModesCount
|
||||
sfVideoMode_IsValid
|
||||
sfWindow_Create
|
||||
sfWindow_CreateFromHandle
|
||||
sfWindow_Close
|
||||
sfWindow_IsOpened
|
||||
sfWindow_Destroy
|
||||
sfWindow_GetWidth
|
||||
sfWindow_GetHeight
|
||||
sfWindow_GetSettings
|
||||
sfWindow_GetEvent
|
||||
sfWindow_UseVerticalSync
|
||||
sfWindow_ShowMouseCursor
|
||||
sfWindow_SetCursorPosition
|
||||
sfWindow_SetPosition
|
||||
sfWindow_SetSize
|
||||
sfWindow_Show
|
||||
sfWindow_EnableKeyRepeat
|
||||
sfWindow_SetIcon
|
||||
sfWindow_SetActive
|
||||
sfWindow_Display
|
||||
sfWindow_GetInput
|
||||
sfWindow_SetFramerateLimit
|
||||
sfWindow_GetFrameTime
|
||||
sfWindow_SetJoystickThreshold
|
||||
sfContext_Create
|
||||
sfContext_Destroy
|
||||
sfContext_SetActive
|
38
CSFML/VC2008/csfml-window.def
Normal file
38
CSFML/VC2008/csfml-window.def
Normal file
@ -0,0 +1,38 @@
|
||||
LIBRARY csfml-window
|
||||
EXPORTS
|
||||
sfInput_IsKeyDown
|
||||
sfInput_IsMouseButtonDown
|
||||
sfInput_IsJoystickButtonDown
|
||||
sfInput_GetMouseX
|
||||
sfInput_GetMouseY
|
||||
sfInput_GetJoystickAxis
|
||||
sfVideoMode_GetDesktopMode
|
||||
sfVideoMode_GetMode
|
||||
sfVideoMode_GetModesCount
|
||||
sfVideoMode_IsValid
|
||||
sfWindow_Create
|
||||
sfWindow_CreateFromHandle
|
||||
sfWindow_Close
|
||||
sfWindow_IsOpened
|
||||
sfWindow_Destroy
|
||||
sfWindow_GetWidth
|
||||
sfWindow_GetHeight
|
||||
sfWindow_GetSettings
|
||||
sfWindow_GetEvent
|
||||
sfWindow_UseVerticalSync
|
||||
sfWindow_ShowMouseCursor
|
||||
sfWindow_SetCursorPosition
|
||||
sfWindow_SetPosition
|
||||
sfWindow_SetSize
|
||||
sfWindow_Show
|
||||
sfWindow_EnableKeyRepeat
|
||||
sfWindow_SetIcon
|
||||
sfWindow_SetActive
|
||||
sfWindow_Display
|
||||
sfWindow_GetInput
|
||||
sfWindow_SetFramerateLimit
|
||||
sfWindow_GetFrameTime
|
||||
sfWindow_SetJoystickThreshold
|
||||
sfContext_Create
|
||||
sfContext_Destroy
|
||||
sfContext_SetActive
|
386
CSFML/VC2008/csfml-window.vcproj
Normal file
386
CSFML/VC2008/csfml-window.vcproj
Normal file
@ -0,0 +1,386 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="9,00"
|
||||
Name="csfml-window"
|
||||
ProjectGUID="{0F9CE5F0-4D89-4314-9147-8AAB1B8842ED}"
|
||||
RootNamespace="csfml-window"
|
||||
Keyword="Win32Proj"
|
||||
TargetFrameworkVersion="131072"
|
||||
>
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"
|
||||
/>
|
||||
</Platforms>
|
||||
<ToolFiles>
|
||||
</ToolFiles>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS;GLEW_BUILD"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-d.dll"
|
||||
LinkIncremental="2"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-window-d.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release DLL|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="2"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="1"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS;GLEW_BUILD"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
AdditionalDependencies="sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName).dll"
|
||||
LinkIncremental="1"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
ModuleDefinitionFile="$(SolutionDir)/csfml-window.def"
|
||||
GenerateDebugInformation="true"
|
||||
ProgramDatabaseFile="$(IntDir)$(TargetName).pdb"
|
||||
SubSystem="2"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
RandomizedBaseAddress="1"
|
||||
DataExecutionPrevention="0"
|
||||
TargetMachine="1"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManifestTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCAppVerifierTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Debug static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_LIB;CSFML_EXPORTS;GLEW_STATIC"
|
||||
MinimalRebuild="true"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="3"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="4"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-window-s-d.lib sfml-system-s-d.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s-d.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
CommandLine=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release static|Win32"
|
||||
OutputDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
IntermediateDirectory="$(SolutionDir)..\Temp\$(ProjectName)\$(ConfigurationName)"
|
||||
ConfigurationType="4"
|
||||
CharacterSet="2"
|
||||
WholeProgramOptimization="0"
|
||||
>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"
|
||||
Description=""
|
||||
CommandLine=""
|
||||
Outputs=""
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="3"
|
||||
FavorSizeOrSpeed="1"
|
||||
AdditionalIncludeDirectories=""$(SolutionDir)..\src";"$(SolutionDir)..\..\include";"$(SolutionDir)..\include""
|
||||
PreprocessorDefinitions="NDEBUG;WIN32;_LIB;CSFML_EXPORTS;GLEW_STATIC"
|
||||
RuntimeLibrary="2"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="4"
|
||||
Detect64BitPortabilityProblems="true"
|
||||
DebugInformationFormat="0"
|
||||
DisableSpecificWarnings="4311;4312"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCManagedResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCLibrarianTool"
|
||||
AdditionalDependencies="sfml-window-s.lib sfml-system-s.lib"
|
||||
OutputFile="$(SolutionDir)..\lib\vc2008\$(ProjectName)-s.lib"
|
||||
AdditionalLibraryDirectories="$(SolutionDir)..\..\lib\vc2008\"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCALinkTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCXDCMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCBscMakeTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCFxCopTool"
|
||||
/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\Context.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Context.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-window-d.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\csfml-window.def"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Event.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\Input.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Input.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\VideoMode.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\VideoMode.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\src\SFML\Window\Window.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\Window.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\include\SFML\Window\WindowHandle.h"
|
||||
>
|
||||
</File>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
10
CSFML/codeblocks/CSFML.workspace
Normal file
10
CSFML/codeblocks/CSFML.workspace
Normal file
@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<CodeBlocks_workspace_file>
|
||||
<Workspace title="CSFML workspace">
|
||||
<Project filename="csfml-system.cbp" active="1" />
|
||||
<Project filename="csfml-window.cbp" />
|
||||
<Project filename="csfml-graphics.cbp" />
|
||||
<Project filename="csfml-network.cbp" />
|
||||
<Project filename="csfml-audio.cbp" />
|
||||
</Workspace>
|
||||
</CodeBlocks_workspace_file>
|
137
CSFML/codeblocks/csfml-audio.cbp
Normal file
137
CSFML/codeblocks/csfml-audio.cbp
Normal file
@ -0,0 +1,137 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<CodeBlocks_project_file>
|
||||
<FileVersion major="1" minor="6" />
|
||||
<Project>
|
||||
<Option title="csfml-audio" />
|
||||
<Option pch_mode="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Build>
|
||||
<Target title="Debug DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-audio-d.dll" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-audio\Debug DLL_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-system-d.a;" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
<Add directory="..\..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-audio-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-audio.dll" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-audio\Release DLL_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-system.a;" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
<Add directory="..\..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-audio-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Debug static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-audio-s-d.a" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-audio\Debug static_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-system-s-d.a;" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
<Add directory="..\..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-audio-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-audio-s.a" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-audio\Release static_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-system-s.a;" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
<Add directory="..\..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-audio-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
</Build>
|
||||
<Compiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\include" />
|
||||
<Add directory="..\..\include" />
|
||||
</Compiler>
|
||||
<Linker>
|
||||
<Add library="..\..\extlibs\libs-mingw\libopenal32.a" />
|
||||
<Add library="..\..\extlibs\libs-mingw\libsndfile.a" />
|
||||
<Add directory="..\..\lib\mingw" />
|
||||
</Linker>
|
||||
<Unit filename="..\include\SFML\Audio\Listener.h" />
|
||||
<Unit filename="..\include\SFML\Audio\Music.h" />
|
||||
<Unit filename="..\include\SFML\Audio\Sound.h" />
|
||||
<Unit filename="..\include\SFML\Audio\SoundBuffer.h" />
|
||||
<Unit filename="..\include\SFML\Audio\SoundBufferRecorder.h" />
|
||||
<Unit filename="..\include\SFML\Audio\SoundRecorder.h" />
|
||||
<Unit filename="..\include\SFML\Audio\SoundStatus.h" />
|
||||
<Unit filename="..\include\SFML\Audio\SoundStream.h" />
|
||||
<Unit filename="..\src\SFML\Audio\Listener.cpp" />
|
||||
<Unit filename="..\src\SFML\Audio\Music.cpp" />
|
||||
<Unit filename="..\src\SFML\Audio\Sound.cpp" />
|
||||
<Unit filename="..\src\SFML\Audio\SoundBuffer.cpp" />
|
||||
<Unit filename="..\src\SFML\Audio\SoundBufferRecorder.cpp" />
|
||||
<Unit filename="..\src\SFML\Audio\SoundRecorder.cpp" />
|
||||
<Unit filename="..\src\SFML\Audio\SoundStream.cpp" />
|
||||
<Extensions>
|
||||
<code_completion />
|
||||
</Extensions>
|
||||
</Project>
|
||||
</CodeBlocks_project_file>
|
151
CSFML/codeblocks/csfml-graphics.cbp
Normal file
151
CSFML/codeblocks/csfml-graphics.cbp
Normal file
@ -0,0 +1,151 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<CodeBlocks_project_file>
|
||||
<FileVersion major="1" minor="6" />
|
||||
<Project>
|
||||
<Option title="csfml-graphics" />
|
||||
<Option pch_mode="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Build>
|
||||
<Target title="Debug DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-graphics-d" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-graphics\Debug DLL_Win32" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-graphics-s-d" />
|
||||
<Add option="-lsfml-window-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-graphics" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-graphics\Release DLL_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-window.a;..\lib\mingw\libcsfml-system.a;" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-graphics-s" />
|
||||
<Add option="-lsfml-window-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Debug static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-graphics-s-d" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-graphics\Debug static_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-window-s-d.a;..\lib\mingw\libcsfml-system-s-d.a;" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
<Add option="-DGLEW_STATIC" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-graphics-s-d" />
|
||||
<Add option="-lsfml-window-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-graphics-s" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-graphics\Release static_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\libcsfml-window-s.a;..\lib\mingw\libcsfml-system-s.a;" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
<Add option="-DGLEW_STATIC" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\extlibs" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-graphics-s" />
|
||||
<Add option="-lsfml-window-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
</Build>
|
||||
<Compiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\include" />
|
||||
<Add directory="..\..\include" />
|
||||
</Compiler>
|
||||
<Linker>
|
||||
<Add library="libopengl32.a" />
|
||||
<Add library="libwinmm.a" />
|
||||
<Add library="libgdi32.a" />
|
||||
<Add library="..\..\extlibs\libs-mingw\libfreetype.a" />
|
||||
<Add directory="..\..\lib\mingw" />
|
||||
</Linker>
|
||||
<Unit filename="..\include\SFML\Graphics\BlendMode.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\Color.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\Font.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\Image.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\PostFX.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\Rect.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\RenderWindow.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\Shape.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\Sprite.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\String.h" />
|
||||
<Unit filename="..\include\SFML\Graphics\View.h" />
|
||||
<Unit filename="..\src\SFML\Graphics\Color.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\Font.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\Image.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\PostFX.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\Rect.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\RenderWindow.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\Shape.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\Sprite.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\String.cpp" />
|
||||
<Unit filename="..\src\SFML\Graphics\View.cpp" />
|
||||
<Extensions>
|
||||
<code_completion />
|
||||
<debugger />
|
||||
</Extensions>
|
||||
</Project>
|
||||
</CodeBlocks_project_file>
|
128
CSFML/codeblocks/csfml-network.cbp
Normal file
128
CSFML/codeblocks/csfml-network.cbp
Normal file
@ -0,0 +1,128 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<CodeBlocks_project_file>
|
||||
<FileVersion major="1" minor="6" />
|
||||
<Project>
|
||||
<Option title="csfml-network" />
|
||||
<Option pch_mode="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Build>
|
||||
<Target title="Debug DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-network-d.dll" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-network\Debug DLL_Win32" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-network-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-network.dll" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-network\Release DLL_Win32" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-network-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Debug static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-network-s-d.a" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-network\Debug static_Win32" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-network-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-network-s.a" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-network\Release static_Win32" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-network-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
</Build>
|
||||
<Compiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\include" />
|
||||
<Add directory="..\..\include" />
|
||||
</Compiler>
|
||||
<Linker>
|
||||
<Add library="libws2_32.a" />
|
||||
<Add directory="..\..\lib\mingw" />
|
||||
</Linker>
|
||||
<Unit filename="..\include\SFML\Network\Ftp.h" />
|
||||
<Unit filename="..\include\SFML\Network\Http.h" />
|
||||
<Unit filename="..\include\SFML\Network\IPAddress.h" />
|
||||
<Unit filename="..\include\SFML\Network\Packet.h" />
|
||||
<Unit filename="..\include\SFML\Network\Selector.h" />
|
||||
<Unit filename="..\include\SFML\Network\SocketStatus.h" />
|
||||
<Unit filename="..\include\SFML\Network\SocketTCP.h" />
|
||||
<Unit filename="..\include\SFML\Network\SocketUDP.h" />
|
||||
<Unit filename="..\src\SFML\Network\Ftp.cpp" />
|
||||
<Unit filename="..\src\SFML\Network\Http.cpp" />
|
||||
<Unit filename="..\src\SFML\Network\IPAddress.cpp" />
|
||||
<Unit filename="..\src\SFML\Network\Packet.cpp" />
|
||||
<Unit filename="..\src\SFML\Network\Selector.cpp" />
|
||||
<Unit filename="..\src\SFML\Network\SocketTCP.cpp" />
|
||||
<Unit filename="..\src\SFML\Network\SocketUDP.cpp" />
|
||||
<Extensions>
|
||||
<code_completion />
|
||||
</Extensions>
|
||||
</Project>
|
||||
</CodeBlocks_project_file>
|
116
CSFML/codeblocks/csfml-system.cbp
Normal file
116
CSFML/codeblocks/csfml-system.cbp
Normal file
@ -0,0 +1,116 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<CodeBlocks_project_file>
|
||||
<FileVersion major="1" minor="6" />
|
||||
<Project>
|
||||
<Option title="csfml-system" />
|
||||
<Option pch_mode="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Build>
|
||||
<Target title="Debug DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-system-d.dll" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-system\Debug DLL_Win32" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-system.dll" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-system\Release DLL_Win32" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Debug static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-system-s-d.a" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-system\Debug static_Win32" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-system-s.a" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-system\Release static_Win32" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
</Build>
|
||||
<Compiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\..\include" />
|
||||
<Add directory="..\include" />
|
||||
</Compiler>
|
||||
<Linker>
|
||||
<Add directory="..\..\lib\mingw" />
|
||||
</Linker>
|
||||
<Unit filename="..\include\SFML\System\Clock.h" />
|
||||
<Unit filename="..\include\SFML\System\Mutex.h" />
|
||||
<Unit filename="..\include\SFML\System\Randomizer.h" />
|
||||
<Unit filename="..\include\SFML\System\Sleep.h" />
|
||||
<Unit filename="..\include\SFML\System\Thread.h" />
|
||||
<Unit filename="..\src\SFML\System\Clock.cpp" />
|
||||
<Unit filename="..\src\SFML\System\Mutex.cpp" />
|
||||
<Unit filename="..\src\SFML\System\Randomizer.cpp" />
|
||||
<Unit filename="..\src\SFML\System\Sleep.cpp" />
|
||||
<Unit filename="..\src\SFML\System\Thread.cpp" />
|
||||
<Extensions>
|
||||
<code_completion />
|
||||
</Extensions>
|
||||
</Project>
|
||||
</CodeBlocks_project_file>
|
135
CSFML/codeblocks/csfml-window.cbp
Normal file
135
CSFML/codeblocks/csfml-window.cbp
Normal file
@ -0,0 +1,135 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<CodeBlocks_project_file>
|
||||
<FileVersion major="1" minor="6" />
|
||||
<Project>
|
||||
<Option title="csfml-window" />
|
||||
<Option pch_mode="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Build>
|
||||
<Target title="Debug DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-window-d" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-window\Debug DLL_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\csfml-system-d.a;" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
<Add option="-DGLEW_BUILD" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-window-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release DLL_Win32">
|
||||
<Option output="..\lib\mingw\csfml-window" prefix_auto="1" extension_auto="1" />
|
||||
<Option object_output="..\Temp\csfml-window\Release DLL_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\csfml-system.a;" />
|
||||
<Option type="3" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createStaticLib="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
<Add option="-DGLEW_BUILD" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-window-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Debug static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-window-s-d" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-window\Debug static_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\csfml-system-s-d.a;" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-Wall" />
|
||||
<Add option="-O0" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-D_DEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
<Add option="-DGLEW_STATIC" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-window-s-d" />
|
||||
<Add option="-lsfml-system-s-d" />
|
||||
</Linker>
|
||||
</Target>
|
||||
<Target title="Release static_Win32">
|
||||
<Option output="..\lib\mingw\libcsfml-window-s" prefix_auto="1" extension_auto="1" />
|
||||
<Option working_dir="" />
|
||||
<Option object_output="..\Temp\csfml-window\Release static_Win32" />
|
||||
<Option external_deps="..\..\lib\mingw\csfml-system-s.a;" />
|
||||
<Option type="2" />
|
||||
<Option compiler="gcc" />
|
||||
<Option createDefFile="1" />
|
||||
<Compiler>
|
||||
<Add option="-O3" />
|
||||
<Add option="-Wall" />
|
||||
<Add option="-DWIN32" />
|
||||
<Add option="-DNDEBUG" />
|
||||
<Add option="-D_LIB" />
|
||||
<Add option="-DCSFML_EXPORTS" />
|
||||
<Add option="-DGLEW_STATIC" />
|
||||
</Compiler>
|
||||
<ResourceCompiler>
|
||||
<Add directory="..\..\src" />
|
||||
</ResourceCompiler>
|
||||
<Linker>
|
||||
<Add option="-lsfml-window-s" />
|
||||
<Add option="-lsfml-system-s" />
|
||||
</Linker>
|
||||
</Target>
|
||||
</Build>
|
||||
<Compiler>
|
||||
<Add directory="..\src" />
|
||||
<Add directory="..\include" />
|
||||
<Add directory="..\..\include" />
|
||||
</Compiler>
|
||||
<Linker>
|
||||
<Add option="--verbose" />
|
||||
<Add library="libwinmm.a" />
|
||||
<Add library="libopengl32.a" />
|
||||
<Add library="libgdi32.a" />
|
||||
<Add directory="..\..\lib\mingw" />
|
||||
</Linker>
|
||||
<Unit filename="..\include\SFML\Window\Context.h" />
|
||||
<Unit filename="..\include\SFML\Window\Event.h" />
|
||||
<Unit filename="..\include\SFML\Window\Input.h" />
|
||||
<Unit filename="..\include\SFML\Window\VideoMode.h" />
|
||||
<Unit filename="..\include\SFML\Window\Window.h" />
|
||||
<Unit filename="..\include\SFML\Window\WindowHandle.h" />
|
||||
<Unit filename="..\src\SFML\Window\Context.cpp" />
|
||||
<Unit filename="..\src\SFML\Window\Input.cpp" />
|
||||
<Unit filename="..\src\SFML\Window\VideoMode.cpp" />
|
||||
<Unit filename="..\src\SFML\Window\Window.cpp" />
|
||||
<Extensions>
|
||||
<code_completion />
|
||||
<debugger />
|
||||
</Extensions>
|
||||
</Project>
|
||||
</CodeBlocks_project_file>
|
8
CSFML/footer.htm
Normal file
8
CSFML/footer.htm
Normal file
@ -0,0 +1,8 @@
|
||||
|
||||
<p id="footer">
|
||||
:: Copyright © 2007 Laurent Gomila, all rights reserved ::
|
||||
Documentation generated by <a href="http://www.doxygen.org/" title="doxygen website">doxygen 1.5.2</a> ::
|
||||
</p>
|
||||
|
||||
</body>
|
||||
</html>
|
12
CSFML/header.htm
Normal file
12
CSFML/header.htm
Normal file
@ -0,0 +1,12 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html>
|
||||
<head>
|
||||
<title>SFML - Simple and Fast Multimedia Library</title>
|
||||
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
|
||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
||||
<link href="tabs.css" rel="stylesheet" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
<div id="logo">
|
||||
<img src="./logo.jpg" width="770" height="200" title="SFML home" alt="SFML logo" />
|
||||
</div>
|
41
CSFML/include/SFML/Audio.h
Normal file
41
CSFML/include/SFML/Audio.h
Normal file
@ -0,0 +1,41 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_AUDIO_H
|
||||
#define SFML_AUDIO_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#include <SFML/System.h>
|
||||
#include <SFML/Audio/Listener.h>
|
||||
#include <SFML/Audio/Music.h>
|
||||
#include <SFML/Audio/Sound.h>
|
||||
#include <SFML/Audio/SoundBuffer.h>
|
||||
#include <SFML/Audio/SoundBufferRecorder.h>
|
||||
#include <SFML/Audio/SoundRecorder.h>
|
||||
|
||||
|
||||
#endif // SFML_AUDIO_H
|
93
CSFML/include/SFML/Audio/Listener.h
Normal file
93
CSFML/include/SFML/Audio/Listener.h
Normal file
@ -0,0 +1,93 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_LISTENER_H
|
||||
#define SFML_LISTENER_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the global volume of all the sounds
|
||||
///
|
||||
/// \param Volume : New global volume, in the range [0, 100]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfListener_SetGlobalVolume(float Volume);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current value of the global volume of all the sounds
|
||||
///
|
||||
/// \return Current global volume, in the range [0, 100]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfListener_GetGlobalVolume();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the position of the listener
|
||||
///
|
||||
/// \param PosX : X position of the listener in the world
|
||||
/// \param PosY : Y position of the listener in the world
|
||||
/// \param PosZ : Z position of the listener in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfListener_SetPosition(float PosX, float PosY, float PosZ);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current position of the listener
|
||||
///
|
||||
/// \param PosX : X position of the listener in the world
|
||||
/// \param PosY : Y position of the listener in the world
|
||||
/// \param PosZ : Z position of the listener in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfListener_GetPosition(float* PosX, float* PosY, float* PosZ);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the orientation of the listener (the point
|
||||
/// he must look at)
|
||||
///
|
||||
/// \param TargetX : X position of the point the listener must look at
|
||||
/// \param TargetY : X position of the point the listener must look at
|
||||
/// \param TargetZ : X position of the point the listener must look at
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfListener_SetTarget(float TargetX, float TargetY, float TargetZ);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current orientation of the listener (the point
|
||||
/// he's looking at)
|
||||
///
|
||||
/// \param TargetX : X position of the point the listener is looking at
|
||||
/// \param TargetY : X position of the point the listener is looking at
|
||||
/// \param TargetZ : X position of the point the listener is looking at
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfListener_GetTarget(float* TargetX, float* TargetY, float* TargetZ);
|
||||
|
||||
|
||||
#endif // SFML_LISTENER_H
|
267
CSFML/include/SFML/Audio/Music.h
Normal file
267
CSFML/include/SFML/Audio/Music.h
Normal file
@ -0,0 +1,267 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_MUSIC_H
|
||||
#define SFML_MUSIC_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Audio/SoundStatus.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfMusic defines a big sound played using streaming,
|
||||
/// so usually what we call a music :)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfMusic sfMusic;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new music and load it from a file
|
||||
///
|
||||
/// \param Filename : Path of the music file to open
|
||||
///
|
||||
/// \return A new sfMusic object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfMusic* sfMusic_CreateFromFile(const char* Filename);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new music and load it from a file in memory
|
||||
///
|
||||
/// \param Data : Pointer to the file data in memory
|
||||
/// \param SizeInBytes : Size of the data to load, in bytes
|
||||
///
|
||||
/// \return A new sfMusic object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfMusic* sfMusic_CreateFromMemory(const char* Data, size_t SizeInBytes);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing music
|
||||
///
|
||||
/// \param Music : Music to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_Destroy(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a music loop state
|
||||
///
|
||||
/// \param Music : Music to set the loop state
|
||||
/// \param Loop : sfTrue to play in loop, sfFalse to play once
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_SetLoop(sfMusic* Music, sfBool Loop);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a music is looping
|
||||
///
|
||||
/// \param Music : Music to get the loop state from
|
||||
///
|
||||
/// \return sfTrue if the music is looping, sfFalse otherwise
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfMusic_GetLoop(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a music duration
|
||||
///
|
||||
/// \param Music : Music to get the duration from
|
||||
///
|
||||
/// \return Music duration, in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfMusic_GetDuration(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start playing a music
|
||||
///
|
||||
/// \param Music : Music to play
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_Play(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Pause a music
|
||||
///
|
||||
/// \param Music : Music to pause
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_Pause(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop playing a music
|
||||
///
|
||||
/// \param Music : Music to stop
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_Stop(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of channels of a music (1 = mono, 2 = stereo)
|
||||
///
|
||||
/// \param Music : Music to get the channels count from
|
||||
///
|
||||
/// \return Number of channels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfMusic_GetChannelsCount(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the stream sample rate of a music
|
||||
///
|
||||
/// \param Music : Music to get the sample rate from
|
||||
///
|
||||
/// \return Stream frequency (number of samples per second)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfMusic_GetSampleRate(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a music (stopped, paused, playing)
|
||||
///
|
||||
/// \param Music : Music to get the status from
|
||||
///
|
||||
/// \return Current status of the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundStatus sfMusic_GetStatus(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current playing position of a music
|
||||
///
|
||||
/// \param Music : Music to get the position from
|
||||
///
|
||||
/// \return Current playing position, expressed in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfMusic_GetPlayingOffset(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the pitch of a music
|
||||
///
|
||||
/// \param Music : Music to modify
|
||||
/// \param Pitch : New pitch
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_SetPitch(sfMusic* Music, float Pitch);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the volume of a music
|
||||
///
|
||||
/// \param Music : Music to modify
|
||||
/// \param Volume : Volume (in range [0, 100])
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_SetVolume(sfMusic* Music, float Volume);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a music
|
||||
///
|
||||
/// \param Music : Music to modify
|
||||
/// \param X : X position of the sound in the world
|
||||
/// \param Y : Y position of the sound in the world
|
||||
/// \param Z : Z position of the sound in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_SetPosition(sfMusic* Music, float X, float Y, float Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the minimum distance - closer than this distance,
|
||||
/// the listener will hear the music at its maximum volume.
|
||||
/// The default minimum distance is 1.0
|
||||
///
|
||||
/// \param Music : Music to modify
|
||||
/// \param MinDistance : New minimum distance for the music
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_SetMinDistance(sfMusic* Music, float MinDistance);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the attenuation factor - the higher the attenuation, the
|
||||
/// more the sound will be attenuated with distance from listener.
|
||||
/// The default attenuation factor 1.0
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param Attenuation : New attenuation factor for the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_SetAttenuation(sfMusic* Music, float Attenuation);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the pitch of a music
|
||||
///
|
||||
/// \param Music : Music to get the pitch from
|
||||
///
|
||||
/// \return Pitch value
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfMusic_GetPitch(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the volume of a music
|
||||
///
|
||||
/// \param Music : Music to get the volume from
|
||||
///
|
||||
/// \return Volume value (in range [1, 100])
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfMusic_GetVolume(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the position of a music
|
||||
///
|
||||
/// \param Music : Music to get the position from
|
||||
/// \param X : X position of the sound in the world
|
||||
/// \param Y : Y position of the sound in the world
|
||||
/// \param Z : Z position of the sound in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMusic_GetPosition(sfMusic* Music, float* X, float* Y, float* Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minimum distance of a music
|
||||
///
|
||||
/// \param Music : Music to get the minimum distance from
|
||||
///
|
||||
/// \return Minimum distance for the music
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfMusic_GetMinDistance(sfMusic* Music);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the attenuation factor of a music
|
||||
///
|
||||
/// \param Music : Music to get the attenuation factor from
|
||||
///
|
||||
/// \return Attenuation factor for the a music
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfMusic_GetAttenuation(sfMusic* Music);
|
||||
|
||||
|
||||
#endif // SFML_MUSIC_H
|
253
CSFML/include/SFML/Audio/Sound.h
Normal file
253
CSFML/include/SFML/Audio/Sound.h
Normal file
@ -0,0 +1,253 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOUND_H
|
||||
#define SFML_SOUND_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Audio/SoundBuffer.h>
|
||||
#include <SFML/Audio/SoundStatus.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSound defines the properties of the sound such as position,
|
||||
/// volume, pitch, etc.
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSound sfSound;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound
|
||||
///
|
||||
/// \return A new sfSound object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSound* sfSound_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound
|
||||
///
|
||||
/// \param Sound : Sound to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_Destroy(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start playing a sound
|
||||
///
|
||||
/// \param Sound : Sound to play
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_Play(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Pause a sound
|
||||
///
|
||||
/// \param Sound : Sound to pause
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_Pause(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop playing a sound
|
||||
///
|
||||
/// \param Sound : Sound to stop
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_Stop(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Bind a sound buffer to a sound
|
||||
///
|
||||
/// \param Sound : Sound to set the loop state
|
||||
/// \param Buffer : Buffer to bind
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetBuffer(sfSound* Sound, sfSoundBuffer* Buffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sound buffer bound to a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the buffer from
|
||||
///
|
||||
/// \return Pointer to the sound's buffer
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundBuffer* sfSound_GetBuffer(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a sound loop state
|
||||
///
|
||||
/// \param Sound : Sound to set the loop state
|
||||
/// \param Loop : sfTrue to play in loop, sfFalse to play once
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetLoop(sfSound* Sound, sfBool Loop);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a sound is looping
|
||||
///
|
||||
/// \param Sound : Sound to get the loop state from
|
||||
///
|
||||
/// \return sfTrue if the sound is looping, sfFalse otherwise
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSound_GetLoop(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a sound (stopped, paused, playing)
|
||||
///
|
||||
/// \param Sound : Sound to get the status from
|
||||
///
|
||||
/// \return Current status of the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundStatus sfSound_GetStatus(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the pitch of a sound
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param Pitch : New pitch
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetPitch(sfSound* Sound, float Pitch);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the volume of a sound
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param Volume : Volume (in range [0, 100])
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetVolume(sfSound* Sound, float Volume);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a sound
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param X : X position of the sound in the world
|
||||
/// \param Y : Y position of the sound in the world
|
||||
/// \param Z : Z position of the sound in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetPosition(sfSound* Sound, float X, float Y, float Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the minimum distance - closer than this distance,
|
||||
/// the listener will hear the sound at its maximum volume.
|
||||
/// The default minimum distance is 1.0
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param MinDistance : New minimum distance for the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetMinDistance(sfSound* Sound, float MinDistance);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the attenuation factor - the higher the attenuation, the
|
||||
/// more the sound will be attenuated with distance from listener.
|
||||
/// The default attenuation factor is 1.0
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param Attenuation : New attenuation factor for the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetAttenuation(sfSound* Sound, float Attenuation);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the current playing position of a sound
|
||||
///
|
||||
/// \param Sound : Sound to modify
|
||||
/// \param TimeOffset : New playing position, expressed in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_SetPlayingOffset(sfSound* Sound, float TimeOffset);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the pitch of a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the pitch from
|
||||
///
|
||||
/// \return Pitch value
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSound_GetPitch(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the volume of a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the volume from
|
||||
///
|
||||
/// \return Volume value (in range [1, 100])
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSound_GetVolume(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the position of a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the position from
|
||||
/// \param X : X position of the sound in the world
|
||||
/// \param Y : Y position of the sound in the world
|
||||
/// \param Z : Z position of the sound in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSound_GetPosition(sfSound* Sound, float* X, float* Y, float* Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minimum distance of a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the minimum distance from
|
||||
///
|
||||
/// \return Minimum distance for the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSound_GetMinDistance(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the attenuation factor of a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the attenuation factor from
|
||||
///
|
||||
/// \return Attenuation factor for the sound
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSound_GetAttenuation(sfSound* Sound);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current playing position of a sound
|
||||
///
|
||||
/// \param Sound : Sound to get the position from
|
||||
///
|
||||
/// \return Current playing position, expressed in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSound_GetPlayingOffset(sfSound* Sound);
|
||||
|
||||
|
||||
#endif // SFML_SOUND_H
|
147
CSFML/include/SFML/Audio/SoundBuffer.h
Normal file
147
CSFML/include/SFML/Audio/SoundBuffer.h
Normal file
@ -0,0 +1,147 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOUNDBUFFER_H
|
||||
#define SFML_SOUNDBUFFER_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSoundBuffer is the low-level for loading and manipulating
|
||||
/// sound buffers
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSoundBuffer sfSoundBuffer;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sound buffer and load it from a file
|
||||
///
|
||||
/// \param Filename : Path of the music file to open
|
||||
///
|
||||
/// \return A new sfSoundBuffer object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundBuffer* sfSoundBuffer_CreateFromFile(const char* Filename);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sound buffer and load it from a file in memory
|
||||
///
|
||||
/// \param Data : Pointer to the file data in memory
|
||||
/// \param SizeInBytes : Size of the data to load, in bytes
|
||||
///
|
||||
/// \return A new sfSoundBuffer object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundBuffer* sfSoundBuffer_CreateFromMemory(const char* Data, size_t SizeInBytes);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sound buffer and load it from an array of
|
||||
/// samples in memory - assumed format for samples is
|
||||
/// 16 bits signed integer
|
||||
///
|
||||
/// \param Samples : Pointer to the samples in memory
|
||||
/// \param SamplesCount : Number of samples pointed by Samples
|
||||
/// \param ChannelsCount : Number of channels (1 = mono, 2 = stereo, ...)
|
||||
/// \param SampleRate : Frequency (number of samples to play per second)
|
||||
///
|
||||
/// \return A new sfSoundBuffer object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundBuffer* sfSoundBuffer_CreateFromSamples(const sfInt16* Samples, size_t SamplesCount, unsigned int ChannelsCount, unsigned int SampleRate);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound buffer
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundBuffer_Destroy(sfSoundBuffer* SoundBuffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Save a sound buffer to a file
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to save
|
||||
/// \param Filename : Path of the sound file to write
|
||||
///
|
||||
/// \return sfTrue if saving has been successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSoundBuffer_SaveToFile(sfSoundBuffer* SoundBuffer, const char* Filename);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the samples contained in a sound buffer
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to get samples from
|
||||
///
|
||||
/// \return Pointer to the array of sound samples, in 16 bits signed integer format
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const sfInt16* sfSoundBuffer_GetSamples(sfSoundBuffer* SoundBuffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of samples contained in a sound buffer
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to get samples count from
|
||||
///
|
||||
/// \return Number of samples
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API size_t sfSoundBuffer_GetSamplesCount(sfSoundBuffer* SoundBuffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound buffer
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to get sample rate from
|
||||
///
|
||||
/// \return Sound frequency (number of samples per second)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSoundBuffer_GetSampleRate(sfSoundBuffer* SoundBuffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of channels of a sound buffer (1 = mono, 2 = stereo, ...)
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to get channels count from
|
||||
///
|
||||
/// \return Number of channels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSoundBuffer_GetChannelsCount(sfSoundBuffer* SoundBuffer);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the duration of a sound buffer
|
||||
///
|
||||
/// \param SoundBuffer : Sound buffer to get duration from
|
||||
///
|
||||
/// \return Sound duration, in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSoundBuffer_GetDuration(sfSoundBuffer* SoundBuffer);
|
||||
|
||||
|
||||
#endif // SFML_SOUNDBUFFER_H
|
98
CSFML/include/SFML/Audio/SoundBufferRecorder.h
Normal file
98
CSFML/include/SFML/Audio/SoundBufferRecorder.h
Normal file
@ -0,0 +1,98 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOUNDBUFFERRECORDER_H
|
||||
#define SFML_SOUNDBUFFERRECORDER_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Audio/SoundBuffer.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Specialized sfSoundRecorder which saves the captured
|
||||
/// audio data into a sound buffer
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSoundBufferRecorder sfSoundBufferRecorder;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound buffer recorder
|
||||
///
|
||||
/// \return A new sfSoundBufferRecorder object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundBufferRecorder* sfSoundBufferRecorder_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound buffer recorder
|
||||
///
|
||||
/// \param SoundBufferRecorder : Sound buffer recorder to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundBufferRecorder_Destroy(sfSoundBufferRecorder* SoundBufferRecorder);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start the capture.
|
||||
/// Warning : only one capture can happen at the same time
|
||||
///
|
||||
/// \param SoundBufferRecorder : Sound bufferrecorder to start
|
||||
/// \param SampleRate : Sound frequency (the more samples, the higher the quality)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundBufferRecorder_Start(sfSoundBufferRecorder* SoundBufferRecorder, unsigned int SampleRate);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop the capture
|
||||
///
|
||||
/// \param SoundBufferRecorder : Sound buffer recorder to stop
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundBufferRecorder_Stop(sfSoundBufferRecorder* SoundBufferRecorder);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound buffer recorder
|
||||
///
|
||||
/// \param SoundBufferRecorder : Sound buffer recorder to get sample rate from
|
||||
///
|
||||
/// \return Frequency, in samples per second
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSoundBufferRecorder_GetSampleRate(sfSoundBufferRecorder* SoundBufferRecorder);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sound buffer containing the captured audio data
|
||||
/// of a sound buffer recorder
|
||||
///
|
||||
/// \param SoundBufferRecorder : Sound buffer recorder to get the sound buffer from
|
||||
///
|
||||
/// \return Pointer to the sound buffer (you don't need to destroy it after use)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundBuffer* sfSoundBufferRecorder_GetBuffer(sfSoundBufferRecorder* SoundBufferRecorder);
|
||||
|
||||
|
||||
#endif // SFML_SOUNDBUFFERRECORDER_H
|
108
CSFML/include/SFML/Audio/SoundRecorder.h
Normal file
108
CSFML/include/SFML/Audio/SoundRecorder.h
Normal file
@ -0,0 +1,108 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOUNDRECORDER_H
|
||||
#define SFML_SOUNDRECORDER_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Audio/SoundBuffer.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSoundRecorder is an interface for capturing sound data
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSoundRecorder sfSoundRecorder;
|
||||
|
||||
typedef sfBool (*sfSoundRecorderStartCallback)(void*); ///< Type of the callback used when starting a capture
|
||||
typedef sfBool (*sfSoundRecorderProcessCallback)(const sfInt16*, size_t, void*); ///< Type of the callback used to process audio data
|
||||
typedef void (*sfSoundRecorderStopCallback)(void*); ///< Type of the callback used when stopping a capture
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound recorder with callback functions
|
||||
/// for processing captured samples
|
||||
///
|
||||
/// \param OnStart : Callback function which will be called when a new capture starts (can be NULL)
|
||||
/// \param OnProcess : Callback function which will be called each time there's audio data to process
|
||||
/// \param OnStop : Callback function which will be called when the current capture stops (can be NULL)
|
||||
/// \param UserData : Data to pass to the callback function (can be NULL)
|
||||
///
|
||||
/// \return A new sfSoundRecorder object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundRecorder* sfSoundRecorder_Create(sfSoundRecorderStartCallback OnStart,
|
||||
sfSoundRecorderProcessCallback OnProcess,
|
||||
sfSoundRecorderStopCallback OnStop,
|
||||
void* UserData);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound recorder
|
||||
///
|
||||
/// \param SoundRecorder : Sound recorder to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundRecorder_Destroy(sfSoundRecorder* SoundRecorder);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start the capture.
|
||||
/// Warning : only one capture can happen at the same time
|
||||
///
|
||||
/// \param SoundRecorder : Sound recorder to start
|
||||
/// \param SampleRate : Sound frequency (the more samples, the higher the quality)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundRecorder_Start(sfSoundRecorder* SoundRecorder, unsigned int SampleRate);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop the capture
|
||||
///
|
||||
/// \param SoundRecorder : Sound recorder to stop
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundRecorder_Stop(sfSoundRecorder* SoundRecorder);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound recorder
|
||||
///
|
||||
/// \param SoundRecorder : Sound recorder to get sample rate from
|
||||
///
|
||||
/// \return Frequency, in samples per second
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSoundRecorder_GetSampleRate(sfSoundRecorder* SoundRecorder);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell if the system supports sound capture.
|
||||
/// If not, this class won't be usable
|
||||
///
|
||||
/// \return sfTrue if audio capture is supported
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSoundRecorder_CanCapture();
|
||||
|
||||
|
||||
#endif // SFML_SOUNDRECORDER_H
|
42
CSFML/include/SFML/Audio/SoundStatus.h
Normal file
42
CSFML/include/SFML/Audio/SoundStatus.h
Normal file
@ -0,0 +1,42 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOUNDSTATUS_H
|
||||
#define SFML_SOUNDSTATUS_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
typedef enum
|
||||
{
|
||||
sfStopped, ///< Sound / music is not playing
|
||||
sfPaused, ///< Sound / music is paused
|
||||
sfPlaying ///< Sound / music is playing
|
||||
} sfSoundStatus;
|
||||
|
||||
|
||||
#endif // SFML_SOUNDSTATUS_H
|
270
CSFML/include/SFML/Audio/SoundStream.h
Normal file
270
CSFML/include/SFML/Audio/SoundStream.h
Normal file
@ -0,0 +1,270 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOUNDSTREAM_H
|
||||
#define SFML_SOUNDSTREAM_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Audio/SoundStatus.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSoundStream is a streamed sound, ie samples are acquired
|
||||
/// while the sound is playing. Use it for big sound that would
|
||||
/// require hundreds of MB in memory (see sfMusic),
|
||||
/// or for streaming sound from the network
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSoundStream sfSoundStream;
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSoundStreamChunk defines the data to fill by the
|
||||
/// OnGetData callback
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
sfInt16* Samples; ///< Pointer to the audio samples
|
||||
unsigned int NbSamples; ///< Number of samples pointed by Samples
|
||||
} sfSoundStreamChunk;
|
||||
|
||||
typedef sfBool (*sfSoundStreamStartCallback)(void*); ///< Type of the callback used to start a sound stream
|
||||
typedef sfBool (*sfSoundStreamGetDataCallback)(sfSoundStreamChunk*, void*); ///< Type of the callback used to get a sound stream data
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound stream
|
||||
///
|
||||
/// \param OnStart : Function called when the stream starts (can be NULL)
|
||||
/// \param OnGetData : Function called when the stream needs more data (can't be NULL)
|
||||
/// \param ChannelsCount : Number of channels to use (1 = mono, 2 = stereo)
|
||||
/// \param SampleRate : Sample rate of the sound (44100 = CD quality)
|
||||
/// \param UserData : Data to pass to the callback functions
|
||||
///
|
||||
/// \return A new sfSoundStream object (NULL if failed)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundStream* sfSoundStream_Create(sfSoundStreamStartCallback OnStart,
|
||||
sfSoundStreamGetDataCallback OnGetData,
|
||||
unsigned int ChannelsCount,
|
||||
unsigned int SampleRate,
|
||||
void* UserData);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_Destroy(sfSoundStream* SoundStreamStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start playing a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to play
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_Play(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Pause a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to pause
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_Pause(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop playing a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to stop
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_Stop(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a sound stream (stopped, paused, playing)
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the status from
|
||||
///
|
||||
/// \return Current status of the sound stream
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSoundStatus sfSoundStream_GetStatus(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of channels of a sound stream
|
||||
/// (1 = mono, 2 = stereo)
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the channels count from
|
||||
///
|
||||
/// \return Number of channels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSoundStream_GetChannelsCount(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the sample rate from
|
||||
///
|
||||
/// \return Stream frequency (number of samples per second)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSoundStream_GetSampleRate(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the pitch of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to modify
|
||||
/// \param Pitch : New pitch
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_SetPitch(sfSoundStream* SoundStream, float Pitch);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the volume of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to modify
|
||||
/// \param Volume : Volume (in range [0, 100])
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_SetVolume(sfSoundStream* SoundStream, float Volume);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to modify
|
||||
/// \param X : X position of the sound stream in the world
|
||||
/// \param Y : Y position of the sound stream in the world
|
||||
/// \param Z : Z position of the sound stream in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_SetPosition(sfSoundStream* SoundStream, float X, float Y, float Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the minimum distance - closer than this distance,
|
||||
/// the listener will hear the sound stream at its maximum volume.
|
||||
/// The default minimum distance is 1.0
|
||||
///
|
||||
/// \param SoundStream : Sound stream to modify
|
||||
/// \param MinDistance : New minimum distance for the sound stream
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_SetMinDistance(sfSoundStream* SoundStream, float MinDistance);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the attenuation factor - the higher the attenuation, the
|
||||
/// more the sound stream will be attenuated with distance from listener.
|
||||
/// The default attenuation factor 1.0
|
||||
///
|
||||
/// \param SoundStream : Sound stream to modify
|
||||
/// \param Attenuation : New attenuation factor for the sound stream
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_SetAttenuation(sfSoundStream* SoundStream, float Attenuation);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a stream loop state
|
||||
///
|
||||
/// \param SoundStream : Stream to set the loop state
|
||||
/// \param Loop : sfTrue to play in loop, sfFalse to play once
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_SetLoop(sfSoundStream* SoundStream, sfBool Loop);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the pitch of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the pitch from
|
||||
///
|
||||
/// \return Pitch value
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSoundStream_GetPitch(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the volume of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the volume from
|
||||
///
|
||||
/// \return Volume value (in range [1, 100])
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSoundStream_GetVolume(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the position of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the position from
|
||||
/// \param X : X position of the sound stream in the world
|
||||
/// \param Y : Y position of the sound stream in the world
|
||||
/// \param Z : Z position of the sound stream in the world
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSoundStream_GetPosition(sfSoundStream* SoundStream, float* X, float* Y, float* Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minimum distance of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the minimum distance from
|
||||
///
|
||||
/// \return Minimum distance for the sound stream
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSoundStream_GetMinDistance(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the attenuation factor of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the attenuation factor from
|
||||
///
|
||||
/// \return Attenuation factor for the sound stream
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSoundStream_GetAttenuation(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a stream is looping
|
||||
///
|
||||
/// \param SoundStream : Soundstream to get the loop state from
|
||||
///
|
||||
/// \return sfTrue if the stream is looping, sfFalse otherwise
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSoundStream_GetLoop(sfSoundStream* SoundStream);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current playing position of a sound stream
|
||||
///
|
||||
/// \param SoundStream : Sound stream to get the position from
|
||||
///
|
||||
/// \return Current playing position, expressed in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSoundStream_GetPlayingOffset(sfSoundStream* SoundStream);
|
||||
|
||||
|
||||
#endif // SFML_SOUNDSTREAM_H
|
120
CSFML/include/SFML/Config.h
Normal file
120
CSFML/include/SFML/Config.h
Normal file
@ -0,0 +1,120 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_CONFIG_H
|
||||
#define SFML_CONFIG_H
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Identify the operating system
|
||||
////////////////////////////////////////////////////////////
|
||||
#if defined(_WIN32) || defined(__WIN32__)
|
||||
|
||||
// Windows
|
||||
#define CSFML_SYSTEM_WINDOWS
|
||||
|
||||
#elif defined(linux) || defined(__linux)
|
||||
|
||||
// Linux
|
||||
#define CSFML_SYSTEM_LINUX
|
||||
|
||||
#elif defined(__APPLE__) || defined(MACOSX) || defined(macintosh) || defined(Macintosh)
|
||||
|
||||
// MacOS
|
||||
#define CSFML_SYSTEM_MACOS
|
||||
|
||||
#else
|
||||
|
||||
// Unsupported system
|
||||
#error This operating system is not supported by SFML library
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Define portable import / export macros
|
||||
////////////////////////////////////////////////////////////
|
||||
#ifdef CSFML_EXPORTS
|
||||
|
||||
#define CSFML_API extern "C"
|
||||
|
||||
#else
|
||||
|
||||
#define CSFML_API extern
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Define a portable boolean type
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef int sfBool;
|
||||
#define sfFalse 0
|
||||
#define sfTrue 1
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Define portable types
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <stdlib.h>
|
||||
#include <limits.h>
|
||||
|
||||
// 8 bits integer types
|
||||
#if UCHAR_MAX == 0xFF
|
||||
typedef signed char sfInt8;
|
||||
typedef unsigned char sfUint8;
|
||||
#else
|
||||
#error No 8 bits integer type for this platform
|
||||
#endif
|
||||
|
||||
// 16 bits integer types
|
||||
#if USHRT_MAX == 0xFFFF
|
||||
typedef signed short sfInt16;
|
||||
typedef unsigned short sfUint16;
|
||||
#elif UINT_MAX == 0xFFFF
|
||||
typedef signed int sfInt16;
|
||||
typedef unsigned int sfUint16;
|
||||
#elif ULONG_MAX == 0xFFFF
|
||||
typedef signed long sfInt16;
|
||||
typedef unsigned long sfUint16;
|
||||
#else
|
||||
#error No 16 bits integer type for this platform
|
||||
#endif
|
||||
|
||||
// 32 bits integer types
|
||||
#if USHRT_MAX == 0xFFFFFFFF
|
||||
typedef signed short sfInt32;
|
||||
typedef unsigned short sfUint32;
|
||||
#elif UINT_MAX == 0xFFFFFFFF
|
||||
typedef signed int sfInt32;
|
||||
typedef unsigned int sfUint32;
|
||||
#elif ULONG_MAX == 0xFFFFFFFF
|
||||
typedef signed long sfInt32;
|
||||
typedef unsigned long sfUint32;
|
||||
#else
|
||||
#error No 32 bits integer type for this platform
|
||||
#endif
|
||||
|
||||
|
||||
#endif // SFML_CONFIG_H
|
43
CSFML/include/SFML/Graphics.h
Normal file
43
CSFML/include/SFML/Graphics.h
Normal file
@ -0,0 +1,43 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_GRAPHICS_H
|
||||
#define SFML_GRAPHICS_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#include <SFML/Window.h>
|
||||
#include <SFML/Graphics/Color.h>
|
||||
#include <SFML/Graphics/Image.h>
|
||||
#include <SFML/Graphics/PostFX.h>
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
#include <SFML/Graphics/RenderWindow.h>
|
||||
#include <SFML/Graphics/Sprite.h>
|
||||
#include <SFML/Graphics/String.h>
|
||||
#include <SFML/Graphics/View.h>
|
||||
|
||||
|
||||
#endif // SFML_GRAPHICS_H
|
46
CSFML/include/SFML/Graphics/BlendMode.h
Normal file
46
CSFML/include/SFML/Graphics/BlendMode.h
Normal file
@ -0,0 +1,46 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_BLENDMODE_H
|
||||
#define SFML_BLENDMODE_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enumerate the blending modes for drawable objects
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfBlendAlpha, ///< Pixel = Src * a + Dest * (1 - a)
|
||||
sfBlendAdd, ///< Pixel = Src + Dest
|
||||
sfBlendMultiply, ///< Pixel = Src * Dest
|
||||
sfBlendNone ///< No blending
|
||||
} sfBlendMode;
|
||||
|
||||
|
||||
#endif // SFML_BLENDMODE_H
|
107
CSFML/include/SFML/Graphics/Color.h
Normal file
107
CSFML/include/SFML/Graphics/Color.h
Normal file
@ -0,0 +1,107 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_COLOR_H
|
||||
#define SFML_COLOR_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfColor is an utility class for manipulating colors
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
sfUint8 r;
|
||||
sfUint8 g;
|
||||
sfUint8 b;
|
||||
sfUint8 a;
|
||||
} sfColor;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Define some common colors
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfBlack;
|
||||
CSFML_API sfColor sfWhite;
|
||||
CSFML_API sfColor sfRed;
|
||||
CSFML_API sfColor sfGreen;
|
||||
CSFML_API sfColor sfBlue;
|
||||
CSFML_API sfColor sfYellow;
|
||||
CSFML_API sfColor sfMagenta;
|
||||
CSFML_API sfColor sfCyan;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a color from its 3 RGB components
|
||||
///
|
||||
/// \param R : Red component (0 .. 255)
|
||||
/// \param G : Green component (0 .. 255)
|
||||
/// \param B : Blue component (0 .. 255)
|
||||
///
|
||||
/// \return sfColor constructed from the components
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfColor_FromRGB(sfUint8 R, sfUint8 G, sfUint8 B);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a color from its 4 RGBA components
|
||||
///
|
||||
/// \param R : Red component (0 .. 255)
|
||||
/// \param G : Green component (0 .. 255)
|
||||
/// \param B : Blue component (0 .. 255)
|
||||
/// \param A : Alpha component (0 .. 255)
|
||||
///
|
||||
/// \return sfColor constructed from the components
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfColor_FromRGBA(sfUint8 R, sfUint8 G, sfUint8 B, sfUint8 A);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Add two colors
|
||||
///
|
||||
/// \param Color1 : First color
|
||||
/// \param Color2 : Second color
|
||||
///
|
||||
/// \return Component-wise saturated addition of the two colors
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfColor_Add(sfColor Color1, sfColor Color2);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Modulate two colors
|
||||
///
|
||||
/// \param Color1 : First color
|
||||
/// \param Color2 : Second color
|
||||
///
|
||||
/// \return Component-wise multiplication of the two colors
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfColor_Modulate(sfColor Color1, sfColor Color2);
|
||||
|
||||
|
||||
#endif // SFML_COLOR_H
|
102
CSFML/include/SFML/Graphics/Font.h
Normal file
102
CSFML/include/SFML/Graphics/Font.h
Normal file
@ -0,0 +1,102 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_FONT_H
|
||||
#define SFML_FONT_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Graphics/Glyph.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfFont is the low-level class for loading and
|
||||
/// manipulating character fonts (see sfString)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfFont sfFont;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new empty font
|
||||
///
|
||||
/// \return A new sfFont object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFont* sfFont_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new font from a file
|
||||
///
|
||||
/// \param Filename : Path of the font file to load
|
||||
/// \param CharSize : Size of characters in bitmap - the bigger, the higher quality
|
||||
/// \param Charset : Characters set to generate (just pass NULL to get the default charset)
|
||||
///
|
||||
/// \return A new sfFont object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFont* sfFont_CreateFromFile(const char* Filename, unsigned int CharSize, const sfUint32* Charset);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image font a file in memory
|
||||
///
|
||||
/// \param Data : Pointer to the file data in memory
|
||||
/// \param SizeInBytes : Size of the data to load, in bytes
|
||||
/// \param CharSize : Size of characters in bitmap - the bigger, the higher quality
|
||||
/// \param Charset : Characters set to generate (just pass NULL to get the default charset)
|
||||
///
|
||||
/// \return A new sfFont object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFont* sfFont_CreateFromMemory(const char* Data, size_t SizeInBytes, unsigned int CharSize, const sfUint32* Charset);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing font
|
||||
///
|
||||
/// \param Font : Font to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfFont_Destroy(sfFont* Font);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the base size of characters in a font;
|
||||
/// All glyphs dimensions are based on this value
|
||||
///
|
||||
/// \param Font : Font object
|
||||
///
|
||||
/// \return Base size of characters
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfFont_GetCharacterSize(sfFont* Font);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the built-in default font (Arial)
|
||||
///
|
||||
/// \return Pointer to the default font
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFont* sfFont_GetDefaultFont();
|
||||
|
||||
|
||||
#endif // SFML_IMAGE_H
|
45
CSFML/include/SFML/Graphics/Glyph.h
Normal file
45
CSFML/include/SFML/Graphics/Glyph.h
Normal file
@ -0,0 +1,45 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_GLYPH_H
|
||||
#define SFML_GLYPH_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfGlyph describes a glyph (a visual character)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
int Advance; ///< Offset to move horizontically to the next character
|
||||
sfIntRect Rectangle; ///< Bounding rectangle of the glyph, in relative coordinates
|
||||
sfFloatRect TexCoords; ///< Texture coordinates of the glyph inside the bitmap font
|
||||
} sfGlyph;
|
||||
|
||||
|
||||
#endif // SFML_GLYPH_H
|
239
CSFML/include/SFML/Graphics/Image.h
Normal file
239
CSFML/include/SFML/Graphics/Image.h
Normal file
@ -0,0 +1,239 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_IMAGE_H
|
||||
#define SFML_IMAGE_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/Color.h>
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
|
||||
|
||||
typedef struct sfRenderWindow sfRenderWindow;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfImage is the low-level class for loading and
|
||||
/// manipulating images
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfImage sfImage;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new empty image
|
||||
///
|
||||
/// \return A new sfImage object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfImage_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image filled with a color
|
||||
///
|
||||
/// \param Width : Image width
|
||||
/// \param Height : Image height
|
||||
/// \param Col : Image color
|
||||
///
|
||||
/// \return A new sfImage object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfImage_CreateFromColor(unsigned int Width, unsigned int Height, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image from an array of pixels in memory
|
||||
///
|
||||
/// \param Width : Image width
|
||||
/// \param Height : Image height
|
||||
/// \param Data : Pointer to the pixels in memory (assumed format is RGBA)
|
||||
///
|
||||
/// \return A new sfImage object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfImage_CreateFromPixels(unsigned int Width, unsigned int Height, const sfUint8* Data);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image from a file
|
||||
///
|
||||
/// \param Filename : Path of the image file to load
|
||||
///
|
||||
/// \return A new sfImage object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfImage_CreateFromFile(const char* Filename);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image from a file in memory
|
||||
///
|
||||
/// \param Data : Pointer to the file data in memory
|
||||
/// \param SizeInBytes : Size of the data to load, in bytes
|
||||
///
|
||||
/// \return A new sfImage object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfImage_CreateFromMemory(const char* Data, size_t SizeInBytes);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing image
|
||||
///
|
||||
/// \param Image : Image to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfImage_Destroy(sfImage* Image);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Save the content of an image to a file
|
||||
///
|
||||
/// \param Image : Image to save
|
||||
/// \param Filename : Path of the file to save (overwritten if already exist)
|
||||
///
|
||||
/// \return sfTrue if saving was successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfImage_SaveToFile(sfImage* Image, const char* Filename);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a transparency mask for an image from a specified colorkey
|
||||
///
|
||||
/// \param Image : Image to modify
|
||||
/// \param ColorKey : Color to become transparent
|
||||
/// \param Alpha : Alpha value to use for transparent pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfImage_CreateMaskFromColor(sfImage* Image, sfColor ColorKey, sfUint8 Alpha);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Copy pixels from another image onto this one.
|
||||
/// This function does a slow pixel copy and should only
|
||||
/// be used at initialization time
|
||||
///
|
||||
/// \param Image : Destination image
|
||||
/// \param Source : Source image to copy
|
||||
/// \param DestX : X coordinate of the destination position
|
||||
/// \param DestY : Y coordinate of the destination position
|
||||
/// \param SourceRect : Sub-rectangle of the source image to copy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfImage_Copy(sfImage* Image, sfImage* Source, unsigned int DestX, unsigned int DestY, sfIntRect SourceRect);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create the image from the current contents of the
|
||||
/// given window
|
||||
///
|
||||
/// \param Image : Destination image
|
||||
/// \param Window : Window to capture
|
||||
/// \param SourceRect : Sub-rectangle of the screen to copy (empty by default - entire image)
|
||||
///
|
||||
/// \return True if creation was successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfImage_CopyScreen(sfImage* Image, sfRenderWindow* Window, sfIntRect SourceRect);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the color of a pixel of an image
|
||||
/// Don't forget to call Update when you end modifying pixels
|
||||
///
|
||||
/// \param Image : Image to modify
|
||||
/// \param X : X coordinate of pixel in the image
|
||||
/// \param Y : Y coordinate of pixel in the image
|
||||
/// \param Col : New color for pixel (X, Y)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfImage_SetPixel(sfImage* Image, unsigned int X, unsigned int Y, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a pixel from an image
|
||||
///
|
||||
/// \param Image : Image to read
|
||||
/// \param X : X coordinate of pixel in the image
|
||||
/// \param Y : Y coordinate of pixel in the image
|
||||
///
|
||||
/// \return Color of pixel (x, y)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfImage_GetPixel(sfImage* Image, unsigned int X, unsigned int Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a read-only pointer to the array of pixels of an image (8 bits integers RGBA)
|
||||
/// Array size is sfImage_GetWidth() x sfImage_GetHeight() x 4
|
||||
/// This pointer becomes invalid if you reload or resize the image
|
||||
///
|
||||
/// \param Image : Image to read
|
||||
///
|
||||
/// \return Pointer to the array of pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const sfUint8* sfImage_GetPixelsPtr(sfImage* Image);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Bind the image for rendering
|
||||
///
|
||||
/// \param Image : Image to bind
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfImage_Bind(sfImage* Image);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable or disable image smooth filter
|
||||
///
|
||||
/// \param Image : Image to modify
|
||||
/// \param Smooth : sfTrue to enable smoothing filter, false to disable it
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfImage_SetSmooth(sfImage* Image, sfBool Smooth);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the width of the image
|
||||
///
|
||||
/// \param Image : Image to read
|
||||
///
|
||||
/// \return Width in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfImage_GetWidth(sfImage* Image);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the height of the image
|
||||
///
|
||||
/// \param Image : Image to read
|
||||
///
|
||||
/// \return Height in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfImage_GetHeight(sfImage* Image);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tells whether the smoothing filter is enabled or not on an image
|
||||
///
|
||||
/// \param Image : Image to read
|
||||
///
|
||||
/// \return sfTrue if the smoothing filter is enabled
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfImage_IsSmooth(sfImage* Image);
|
||||
|
||||
|
||||
#endif // SFML_IMAGE_H
|
128
CSFML/include/SFML/Graphics/PostFX.h
Normal file
128
CSFML/include/SFML/Graphics/PostFX.h
Normal file
@ -0,0 +1,128 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_POSTFX_H
|
||||
#define SFML_POSTFX_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/Image.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// PostFX is used to apply a post effect to a window
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfPostFX sfPostFX;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new post-fx from a file
|
||||
///
|
||||
/// \param Filename : File to load
|
||||
///
|
||||
/// \return A new sfPostFX object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfPostFX* sfPostFX_CreateFromFile(const char* Filename);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new post-fx from an effect source code
|
||||
///
|
||||
/// \param Effect : Source code of the effect
|
||||
///
|
||||
/// \return A new sfPostFX object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfPostFX* sfPostFX_CreateFromMemory(const char* Effect);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing post-fx
|
||||
///
|
||||
/// \param PostFX : PostFX to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPostFX_Destroy(sfPostFX* PostFX);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change a parameter of a post-fx (1 float)
|
||||
///
|
||||
/// \param PostFX : Post-effect to modify
|
||||
/// \param Name : Parameter name in the effect
|
||||
/// \param X : Value to assign
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPostFX_SetParameter1(sfPostFX* PostFX, const char* Name, float X);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change a parameter of a post-fx (2 floats)
|
||||
///
|
||||
/// \param PostFX : Post-effect to modify
|
||||
/// \param Name : Parameter name in the effect
|
||||
/// \param X, Y : Values to assign
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPostFX_SetParameter2(sfPostFX* PostFX, const char* Name, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change a parameter of a post-fx (3 floats)
|
||||
///
|
||||
/// \param PostFX : Post-effect to modify
|
||||
/// \param Name : Parameter name in the effect
|
||||
/// \param X, Y, Z : Values to assign
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPostFX_SetParameter3(sfPostFX* PostFX, const char* Name, float X, float Y, float Z);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change a parameter of a post-fx (4 floats)
|
||||
///
|
||||
/// \param PostFX : Post-effect to modify
|
||||
/// \param Name : Parameter name in the effect
|
||||
/// \param X, Y, Z, W : Values to assign
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPostFX_SetParameter4(sfPostFX* PostFX, const char* Name, float X, float Y, float Z, float W);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a texture parameter in a post-fx
|
||||
///
|
||||
/// \param PostFX : Post-effect to modify
|
||||
/// \param Name : Texture name in the effect
|
||||
/// \param Texture : Image to set (pass NULL to use content of current framebuffer)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPostFX_SetTexture(sfPostFX* PostFX, const char* Name, sfImage* Texture);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not the system supports post-effects
|
||||
///
|
||||
/// \return sfTrue if the system can use post-effects
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfPostFX_CanUsePostFX();
|
||||
|
||||
|
||||
#endif // SFML_POSTFX_H
|
93
CSFML/include/SFML/Graphics/Rect.h
Normal file
93
CSFML/include/SFML/Graphics/Rect.h
Normal file
@ -0,0 +1,93 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_RECT_H
|
||||
#define SFML_RECT_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfFloatRect and sfIntRect are utility classes for
|
||||
/// manipulating rectangles.
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
float Left;
|
||||
float Top;
|
||||
float Right;
|
||||
float Bottom;
|
||||
} sfFloatRect;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
int Left;
|
||||
int Top;
|
||||
int Right;
|
||||
int Bottom;
|
||||
} sfIntRect;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Move a rectangle by the given offset
|
||||
///
|
||||
/// \param Rect : Rectangle to move
|
||||
/// \param OffsetX : Horizontal offset
|
||||
/// \param OffsetY : Vertical offset
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfFloatRect_Offset(sfFloatRect* Rect, float OffsetX, float OffsetY);
|
||||
CSFML_API void sfIntRect_Offset(sfIntRect* Rect, int OffsetX, int OffsetY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Check if a point is inside a rectangle's area
|
||||
///
|
||||
/// \param Rect : Rectangle to test
|
||||
/// \param X : X coordinate of the point to test
|
||||
/// \param Y : Y coordinate of the point to test
|
||||
///
|
||||
/// \return sfTrue if the point is inside
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfFloatRect_Contains(sfFloatRect* Rect, float X, float Y);
|
||||
CSFML_API sfBool sfIntRect_Contains(sfIntRect* Rect, int X, int Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Check intersection between two rectangles
|
||||
///
|
||||
/// \param Rect1 : First rectangle to test
|
||||
/// \param Rect2 : Second rectangle to test
|
||||
/// \param OverlappingRect : Rectangle to be filled with overlapping rect (can be NULL)
|
||||
///
|
||||
/// \return sfTrue if rectangles overlap
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfFloatRect_Intersects(sfFloatRect* Rect1, sfFloatRect* Rect2, sfFloatRect* OverlappingRect);
|
||||
CSFML_API sfBool sfIntRect_Intersects(sfIntRect* Rect1, sfIntRect* Rect2, sfIntRect* OverlappingRect);
|
||||
|
||||
|
||||
#endif // SFML_RECT_H
|
365
CSFML/include/SFML/Graphics/RenderWindow.h
Normal file
365
CSFML/include/SFML/Graphics/RenderWindow.h
Normal file
@ -0,0 +1,365 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_RENDERWINDOW_H
|
||||
#define SFML_RENDERWINDOW_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/Color.h>
|
||||
#include <SFML/Graphics/Image.h>
|
||||
#include <SFML/Graphics/PostFX.h>
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
#include <SFML/Graphics/Shape.h>
|
||||
#include <SFML/Graphics/Sprite.h>
|
||||
#include <SFML/Graphics/String.h>
|
||||
#include <SFML/Graphics/View.h>
|
||||
#include <SFML/Window/Event.h>
|
||||
#include <SFML/Window/Input.h>
|
||||
#include <SFML/Window/VideoMode.h>
|
||||
#include <SFML/Window/Window.h>
|
||||
#include <SFML/Window/WindowHandle.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfRenderWindow is a simple wrapper for sfWindow that
|
||||
/// allows easy 2D rendering
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfRenderWindow sfRenderWindow;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new renderwindow
|
||||
///
|
||||
/// \param Mode : Video mode to use
|
||||
/// \param Title : Title of the window
|
||||
/// \param Style : Window style
|
||||
/// \param Params : Creation settings
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfRenderWindow* sfRenderWindow_Create(sfVideoMode Mode, const char* Title, unsigned long Style, sfWindowSettings Params);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a renderwindow from an existing control
|
||||
///
|
||||
/// \param Handle : Platform-specific handle of the control
|
||||
/// \param Params : Creation settings
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfRenderWindow* sfRenderWindow_CreateFromHandle(sfWindowHandle Handle, sfWindowSettings Params);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing renderwindow
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_Destroy(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Close a renderwindow (but doesn't destroy the internal data)
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow to close
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_Close(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a renderwindow is opened
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfRenderWindow_IsOpened(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the width of the rendering region of a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
/// \return Width in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfRenderWindow_GetWidth(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the height of the rendering region of a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
/// \return Height in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfRenderWindow_GetHeight(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the creation settings of a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
/// \return Settings used to create the window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfWindowSettings sfRenderWindow_GetSettings(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the event on top of events stack of a window, if any, and pop it
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Event : Event to fill, if any
|
||||
///
|
||||
/// \return sfTrue if an event was returned, sfFalse if events stack was empty
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfRenderWindow_GetEvent(sfRenderWindow* RenderWindow, sfEvent* Event);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable / disable vertical synchronization on a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Enabled : sfTrue to enable v-sync, sfFalse to deactivate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_UseVerticalSync(sfRenderWindow* RenderWindow, sfBool Enabled);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Show or hide the mouse cursor on a window
|
||||
///
|
||||
/// \param RenderWindow : RenderWindow object
|
||||
/// \param Show : sfTrue to show, sfFalse to hide
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_ShowMouseCursor(sfRenderWindow* RenderWindow, sfBool Show);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the position of the mouse cursor on a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Left : Left coordinate of the cursor, relative to the window
|
||||
/// \param Top : Top coordinate of the cursor, relative to the window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetCursorPosition(sfRenderWindow* RenderWindow, unsigned int Left, unsigned int Top);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the position of a window on screen.
|
||||
/// Only works for top-level windows
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Left : Left position
|
||||
/// \param Top : Top position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetPosition(sfRenderWindow* RenderWindow, int Left, int Top);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the size of the rendering region of a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Width : New Width
|
||||
/// \param Height : New Height
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetSize(sfRenderWindow* RenderWindow, unsigned int Width, unsigned int Height);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Show or hide a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param State : sfTrue to show, sfFalse to hide
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_Show(sfRenderWindow* RenderWindow, sfBool State);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable or disable automatic key-repeat for keydown events.
|
||||
/// Automatic key-repeat is enabled by default
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Enabled : sfTrue to enable, sfFalse to disable
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_EnableKeyRepeat(sfRenderWindow* RenderWindow, sfBool Enabled);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the window's icon
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Width : Icon's width, in pixels
|
||||
/// \param Height : Icon's height, in pixels
|
||||
/// \param Pixels : Pointer to the pixels in memory, format must be RGBA 32 bits
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetIcon(sfRenderWindow* RenderWindow, unsigned int Width, unsigned int Height, sfUint8* Pixels);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Activate or deactivate a window as the current target for rendering
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Active : sfTrue to activate, sfFalse to deactivate
|
||||
///
|
||||
/// \return True if operation was successful, false otherwise
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfRenderWindow_SetActive(sfRenderWindow* RenderWindow, sfBool Active);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Display a window on screen
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_Display(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the input manager of a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
/// \return Reference to the input
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfInput* sfRenderWindow_GetInput(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Limit the framerate to a maximum fixed frequency for a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
/// \param Limit : Framerate limit, in frames per seconds (use 0 to disable limit)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetFramerateLimit(sfRenderWindow* RenderWindow, unsigned int Limit);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get time elapsed since last frame of a window
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
///
|
||||
/// \return Time elapsed, in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfRenderWindow_GetFrameTime(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the joystick threshold, ie. the value below which
|
||||
/// no move event will be generated
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow object
|
||||
/// \param Threshold : New threshold, in range [0, 100]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetJoystickThreshold(sfRenderWindow* RenderWindow, float Threshold);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Draw something on a renderwindow
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow to draw in
|
||||
/// \param PostFX / Sprite / String / shape : Object to draw
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_DrawPostFX(sfRenderWindow* RenderWindow, sfPostFX* PostFX);
|
||||
CSFML_API void sfRenderWindow_DrawSprite(sfRenderWindow* RenderWindow, sfSprite* Sprite);
|
||||
CSFML_API void sfRenderWindow_DrawShape (sfRenderWindow* RenderWindow, sfShape* Shape);
|
||||
CSFML_API void sfRenderWindow_DrawString(sfRenderWindow* RenderWindow, sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Save the content of a renderwindow to an image
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow to capture
|
||||
///
|
||||
/// \return Image instance containing the contents of the screen
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfRenderWindow_Capture(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Clear the screen with the given color
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow to modify
|
||||
/// \param Color : Fill color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_Clear(sfRenderWindow* RenderWindow, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the current active view of a renderwindow
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow to modify
|
||||
/// \param NewView : Pointer to the new view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_SetView(sfRenderWindow* RenderWindow, sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current active view of a renderwindow
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow
|
||||
///
|
||||
/// \return Current active view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const sfView* sfRenderWindow_GetView(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the default view of a renderwindow
|
||||
///
|
||||
/// \param RenderWindow : Renderwindow
|
||||
///
|
||||
/// \return Default view of the render window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfView* sfRenderWindow_GetDefaultView(sfRenderWindow* RenderWindow);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Convert a point in window coordinates into view coordinates
|
||||
///
|
||||
/// \param RenderWindow : Target Renderwindow
|
||||
/// \param WindowX : X coordinate of the point to convert, relative to the window
|
||||
/// \param WindowY : Y coordinate of the point to convert, relative to the window
|
||||
/// \param ViewX : Pointer to fill with the X coordinate of the converted point
|
||||
/// \param ViewY : Pointer to fill with the Y coordinate of the converted point
|
||||
/// \param TargetView : Target view to convert the point to (pass NULL to use the current view)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_ConvertCoords(sfRenderWindow* RenderWindow, unsigned int WindowX, unsigned int WindowY, float* ViewX, float* ViewY, sfView* TargetView);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell SFML to preserve external OpenGL states, at the expense of
|
||||
/// more CPU charge. Use this function if you don't want SFML
|
||||
/// to mess up your own OpenGL states (if any).
|
||||
/// Don't enable state preservation if not needed, as it will allow
|
||||
/// SFML to do internal optimizations and improve performances.
|
||||
/// This parameter is false by default
|
||||
///
|
||||
/// \param RenderWindow : Target Renderwindow
|
||||
/// \param Preserve : True to preserve OpenGL states, false to let SFML optimize
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRenderWindow_PreserveOpenGLStates(sfRenderWindow* RenderWindow, sfBool Preserve);
|
||||
|
||||
|
||||
#endif // SFML_RENDERWINDOW_H
|
460
CSFML/include/SFML/Graphics/Shape.h
Normal file
460
CSFML/include/SFML/Graphics/Shape.h
Normal file
@ -0,0 +1,460 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_Shape_H
|
||||
#define SFML_Shape_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/BlendMode.h>
|
||||
#include <SFML/Graphics/Color.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfShape defines a drawable convex Shape ; it also defines
|
||||
/// helper functions to draw simple Shapes like
|
||||
/// lines, rectangles, circles, etc.
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfShape sfShape;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new shape
|
||||
///
|
||||
/// \return A new sfShape object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfShape* sfShape_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new shape made of a single line
|
||||
///
|
||||
/// \param P1X, P1Y : Position of the first point
|
||||
/// \param P2X, P2Y : Position second point
|
||||
/// \param Thickness : Line thickness
|
||||
/// \param Col : Color used to draw the line
|
||||
/// \param Outline : Outline width
|
||||
/// \param OutlineCol : Color used to draw the outline
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfShape* sfShape_CreateLine(float P1X, float P1Y, float P2X, float P2Y, float Thickness, sfColor Col, float Outline, sfColor OutlineCol);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new shape made of a single rectangle
|
||||
///
|
||||
/// \param P1X, P1Y : Position of the first point
|
||||
/// \param P2X, P2Y : Position second point
|
||||
/// \param Col : Color used to fill the rectangle
|
||||
/// \param Outline : Outline width
|
||||
/// \param OutlineCol : Color used to draw the outline
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfShape* sfShape_CreateRectangle(float P1X, float P1Y, float P2X, float P2Y, sfColor Col, float Outline, sfColor OutlineCol);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new shape made of a single circle
|
||||
///
|
||||
/// \param X, Y : Position of the center
|
||||
/// \param Radius : Radius
|
||||
/// \param Col : Color used to fill the circle
|
||||
/// \param Outline : Outline width
|
||||
/// \param OutlineCol : Color used to draw the outline
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfShape* sfShape_CreateCircle(float X, float Y, float Radius, sfColor Col, float Outline, sfColor OutlineCol);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Shape
|
||||
///
|
||||
/// \param Shape : Shape to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_Destroy(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the X position of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param X : New X coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetX(sfShape* Shape, float X);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the Y position of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Y : New Y coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetY(sfShape* Shape, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param X : New X coordinate
|
||||
/// \param Y : New Y coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetPosition(sfShape* Shape, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the horizontal scale of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Scale : New scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetScaleX(sfShape* Shape, float Scale);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the vertical scale of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Scale : New scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetScaleY(sfShape* Shape, float Scale);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the scale of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param ScaleX : New horizontal scale (must be strictly positive)
|
||||
/// \param ScaleY : New vertical scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetScale(sfShape* Shape, float ScaleX, float ScaleY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the orientation of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Rotation : Angle of rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetRotation(sfShape* Shape, float Rotation);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the center of a shape, in coordinates relative to
|
||||
/// its left-top corner
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param X : X coordinate of the center
|
||||
/// \param Y : Y coordinate of the center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetCenter(sfShape* Shape, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the color of a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Color : New color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetColor(sfShape* Shape, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the blending mode for a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Mode : New blending mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetBlendMode(sfShape* Shape, sfBlendMode Mode);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X position of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current X position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetX(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the Y position of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current Y position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetY(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the horizontal scale of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current X scale factor (always positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetScaleX(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the vertical scale of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current Y scale factor (always positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetScaleY(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the orientation of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetRotation(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X position of the center a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current X center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetCenterX(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the Y position of the center a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current Y center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetCenterY(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the color of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfShape_GetColor(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current blending mode of a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Current blending mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBlendMode sfShape_GetBlendMode(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Move a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param OffsetX : Offset on the X axis
|
||||
/// \param OffsetY : Offset on the Y axis
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_Move(sfShape* Shape, float OffsetX, float OffsetY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Scale a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param FactorX : Horizontal scaling factor (must be strictly positive)
|
||||
/// \param FactorY : Vertical scaling factor (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_Scale(sfShape* Shape, float FactorX, float FactorY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Rotate a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Angle : Angle of rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_Rotate(sfShape* Shape, float Angle);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Transform a point from global coordinates into the shape's local coordinates
|
||||
/// (ie it applies the inverse of object's center, translation, rotation and scale to the point)
|
||||
///
|
||||
/// \param Shape : Shape object
|
||||
/// \param PointX : X coordinate of the point to transform
|
||||
/// \param PointY : Y coordinate of the point to transform
|
||||
/// \param X : Value to fill with the X coordinate of the converted point
|
||||
/// \param Y : Value to fill with the y coordinate of the converted point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_TransformToLocal(sfShape* Shape, float PointX, float PointY, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Transform a point from the shape's local coordinates into global coordinates
|
||||
/// (ie it applies the object's center, translation, rotation and scale to the point)
|
||||
///
|
||||
/// \param Shape : Shape object
|
||||
/// \param PointX : X coordinate of the point to transform
|
||||
/// \param PointY : Y coordinate of the point to transform
|
||||
/// \param X : Value to fill with the X coordinate of the converted point
|
||||
/// \param Y : Value to fill with the y coordinate of the converted point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_TransformToGlobal(sfShape* Shape, float PointX, float PointY, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Add a point to a shape
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param X, Y : Position of the point
|
||||
/// \param Col : Color of the point
|
||||
/// \param OutlineCol : Outline color of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_AddPoint(sfShape* Shape, float X, float Y, sfColor Col, sfColor OutlineCol);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable or disable filling a shape.
|
||||
/// Fill is enabled by default
|
||||
///
|
||||
/// \param Enable : True to enable, false to disable
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_EnableFill(sfShape* Shape, sfBool Enable);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable or disable drawing a shape outline.
|
||||
/// Outline is enabled by default
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Enable : True to enable, false to disable
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_EnableOutline(sfShape* Shape, sfBool Enable);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the width of a shape outline
|
||||
///
|
||||
/// \param Shape : Shape to modify
|
||||
/// \param Width : New width
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetOutlineWidth(sfShape* Shape, float Width);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the width of a shape outline
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \param return Current outline width
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfShape_GetOutlineWidth(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the number of points composing a shape
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
///
|
||||
/// \return Total number of points
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfShape_GetNbPoints(sfShape* Shape);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a the position of a shape's point
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
/// \param Index : Index of the point to get
|
||||
/// \param X : Variable to fill with the X coordinate of the point
|
||||
/// \param Y : Variable to fill with the Y coordinate of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_GetPointPosition(sfShape* Shape, unsigned int Index, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a the color of a shape's point
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
/// \param Index : Index of the point to get
|
||||
///
|
||||
/// \return Color of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfShape_GetPointColor(sfShape* Shape, unsigned int Index);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a the outline color of a shape's point
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
/// \param Index : Index of the point to get
|
||||
///
|
||||
/// \return Outline color of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfShape_GetPointOutlineColor(sfShape* Shape, unsigned int Index);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a the position of a shape's point
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
/// \param Index : Index of the point to get
|
||||
/// \param X : X coordinate of the point
|
||||
/// \param Y : Y coordinate of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetPointPosition(sfShape* Shape, unsigned int Index, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a the color of a shape's point
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
/// \param Index : Index of the point to get
|
||||
/// \param Color : Color of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetPointColor(sfShape* Shape, unsigned int Index, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a the outline color of a shape's point
|
||||
///
|
||||
/// \param Shape : Shape to read
|
||||
/// \param Index : Index of the point to get
|
||||
/// \param Color : Outline color of the point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfShape_SetPointOutlineColor(sfShape* Shape, unsigned int Index, sfColor Color);
|
||||
|
||||
|
||||
#endif // SFML_Shape_H
|
399
CSFML/include/SFML/Graphics/Sprite.h
Normal file
399
CSFML/include/SFML/Graphics/Sprite.h
Normal file
@ -0,0 +1,399 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SPRITE_H
|
||||
#define SFML_SPRITE_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/BlendMode.h>
|
||||
#include <SFML/Graphics/Color.h>
|
||||
#include <SFML/Graphics/Image.h>
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSprite defines a sprite : texture, transformations,
|
||||
/// color, and draw on screen
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSprite sfSprite;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sprite
|
||||
///
|
||||
/// \return A new sfSprite object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSprite* sfSprite_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_Destroy(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the X position of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param X : New X coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetX(sfSprite* Sprite, float X);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the T position of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Y : New Y coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetY(sfSprite* Sprite, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param X : New X coordinate
|
||||
/// \param Y : New Y coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetPosition(sfSprite* Sprite, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the horizontal scale of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Scale : New scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetScaleX(sfSprite* Sprite, float Scale);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the vertical scale of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Scale : New scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetScaleY(sfSprite* Sprite, float Scale);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the scale of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param ScaleX : New horizontal scale (must be strictly positive)
|
||||
/// \param ScaleY : New vertical scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetScale(sfSprite* Sprite, float ScaleX, float ScaleY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the orientation of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Rotation : Angle of rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetRotation(sfSprite* Sprite, float Rotation);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the center of a sprite, in coordinates relative to
|
||||
/// its left-top corner
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param X : X coordinate of the center
|
||||
/// \param Y : Y coordinate of the center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetCenter(sfSprite* Sprite, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the color of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Color : New color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetColor(sfSprite* Sprite, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the blending mode for a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Mode : New blending mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetBlendMode(sfSprite* Sprite, sfBlendMode Mode);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X position of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current X position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetX(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the Y position of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current Y position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetY(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the horizontal scale of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current X scale factor (always positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetScaleX(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the vertical scale of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current Y scale factor (always positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetScaleY(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the orientation of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetRotation(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X position of the center a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current X center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetCenterX(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the Y position of the center a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current Y center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetCenterY(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the color of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfSprite_GetColor(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current blending mode of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Current blending mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBlendMode sfSprite_GetBlendMode(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Move a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param OffsetX : Offset on the X axis
|
||||
/// \param OffsetY : Offset on the Y axis
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_Move(sfSprite* Sprite, float OffsetX, float OffsetY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Scale a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param FactorX : Horizontal scaling factor (must be strictly positive)
|
||||
/// \param FactorY : Vertical scaling factor (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_Scale(sfSprite* Sprite, float FactorX, float FactorY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Rotate a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Angle : Angle of rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_Rotate(sfSprite* Sprite, float Angle);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Transform a point from global coordinates into the sprite's local coordinates
|
||||
/// (ie it applies the inverse of object's center, translation, rotation and scale to the point)
|
||||
///
|
||||
/// \param Sprite : Sprite object
|
||||
/// \param PointX : X coordinate of the point to transform
|
||||
/// \param PointY : Y coordinate of the point to transform
|
||||
/// \param X : Value to fill with the X coordinate of the converted point
|
||||
/// \param Y : Value to fill with the y coordinate of the converted point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_TransformToLocal(sfSprite* Sprite, float PointX, float PointY, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Transform a point from the sprite's local coordinates into global coordinates
|
||||
/// (ie it applies the object's center, translation, rotation and scale to the point)
|
||||
///
|
||||
/// \param Sprite : Sprite object
|
||||
/// \param PointX : X coordinate of the point to transform
|
||||
/// \param PointY : Y coordinate of the point to transform
|
||||
/// \param X : Value to fill with the X coordinate of the converted point
|
||||
/// \param Y : Value to fill with the y coordinate of the converted point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_TransformToGlobal(sfSprite* Sprite, float PointX, float PointY, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the image of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Image : New image
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetImage(sfSprite* Sprite, sfImage* Image);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the sub-rectangle of a sprite inside the source image
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param SubRect : New sub-rectangle
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_SetSubRect(sfSprite* Sprite, sfIntRect SubRect);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Resize a sprite (by changing its scale factors)
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Width : New width (must be strictly positive)
|
||||
/// \param Height : New height (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_Resize(sfSprite* Sprite, float Width, float Height);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Flip a sprite horizontally
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Flipped : sfTrue to flip the sprite
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_FlipX(sfSprite* Sprite, sfBool Flipped);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Flip a sprite vertically
|
||||
///
|
||||
/// \param Sprite : Sprite to modify
|
||||
/// \param Flipped : sfTrue to flip the sprite
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSprite_FlipY(sfSprite* Sprite, sfBool Flipped);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the source image of a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Pointer to the image (can be NULL)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfImage* sfSprite_GetImage(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sub-rectangle of a sprite inside the source image
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Sub-rectangle
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIntRect sfSprite_GetSubRect(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a sprite width
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Width of the sprite
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetWidth(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a sprite height
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
///
|
||||
/// \return Height of the sprite
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfSprite_GetHeight(sfSprite* Sprite);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the color of a given pixel in a sprite
|
||||
///
|
||||
/// \param Sprite : Sprite to read
|
||||
/// \param X : X coordinate of the pixel to get
|
||||
/// \param Y : Y coordinate of the pixel to get
|
||||
///
|
||||
/// \return Color of pixel (X, Y)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfSprite_GetPixel(sfSprite* Sprite, unsigned int X, unsigned int Y);
|
||||
|
||||
|
||||
#endif // SFML_SPRITE_H
|
430
CSFML/include/SFML/Graphics/String.h
Normal file
430
CSFML/include/SFML/Graphics/String.h
Normal file
@ -0,0 +1,430 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_STRING_H
|
||||
#define SFML_STRING_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/BlendMode.h>
|
||||
#include <SFML/Graphics/Color.h>
|
||||
#include <SFML/Graphics/Font.h>
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfString defines a graphical 2D text, that can be drawn on screen
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfString sfString;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfString styles
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfStringRegular = 0, ///< Regular characters, no style
|
||||
sfStringBold = 1 << 0, ///< Characters are bold
|
||||
sfStringItalic = 1 << 1, ///< Characters are in italic
|
||||
sfStringUnderlined = 1 << 2 ///< Characters are underlined
|
||||
} sfStringStyle;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new string
|
||||
///
|
||||
/// \return A new sfString object, or NULL if it failed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfString* sfString_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing string
|
||||
///
|
||||
/// \param String : String to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_Destroy(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the X position of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param X : New X coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetX(sfString* String, float X);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the Y position of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Y : New Y coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetY(sfString* String, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Left : New left coordinate
|
||||
/// \param Top : New top coordinate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetPosition(sfString* String, float Left, float Top);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the horizontal scale of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Scale : New scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetScaleX(sfString* String, float Scale);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the vertical scale of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Scale : New scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetScaleY(sfString* String, float Scale);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the scale of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param ScaleX : New horizontal scale (must be strictly positive)
|
||||
/// \param ScaleY : New vertical scale (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetScale(sfString* String, float ScaleX, float ScaleY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the orientation of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Rotation : Angle of rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetRotation(sfString* String, float Rotation);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the center of a string, in coordinates
|
||||
/// relative to its left-top corner
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param X : X coordinate of the center
|
||||
/// \param Y : Y coordinate of the center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetCenter(sfString* String, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the color of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Color : New color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetColor(sfString* String, sfColor Color);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the blending mode for a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Mode : New blending mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetBlendMode(sfString* String, sfBlendMode Mode);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X position of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current X position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetX(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the top Y of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current Y position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetY(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the horizontal scale of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current X scale factor (always positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetScaleX(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the vertical scale of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current Y scale factor (always positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetScaleY(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the orientation of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetRotation(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X position of the center a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current X center position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetCenterX(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the top Y of the center of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current Y center position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetCenterY(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the color of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current color
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfColor sfString_GetColor(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current blending mode of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current blending mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBlendMode sfString_GetBlendMode(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Move a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param OffsetX : Offset on the X axis
|
||||
/// \param OffsetY : Offset on the Y axis
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_Move(sfString* String, float OffsetX, float OffsetY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Scale a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param FactorX : Horizontal scaling factor (must be strictly positive)
|
||||
/// \param FactorY : Vertical scaling factor (must be strictly positive)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_Scale(sfString* String, float FactorX, float FactorY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Rotate a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Angle : Angle of rotation, in degrees
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_Rotate(sfString* String, float Angle);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Transform a point from global coordinates into the string's local coordinates
|
||||
/// (ie it applies the inverse of object's center, translation, rotation and scale to the point)
|
||||
///
|
||||
/// \param String : String object
|
||||
/// \param PointX : X coordinate of the point to transform
|
||||
/// \param PointY : Y coordinate of the point to transform
|
||||
/// \param X : Value to fill with the X coordinate of the converted point
|
||||
/// \param Y : Value to fill with the y coordinate of the converted point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_TransformToLocal(sfString* String, float PointX, float PointY, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Transform a point from the string's local coordinates into global coordinates
|
||||
/// (ie it applies the object's center, translation, rotation and scale to the point)
|
||||
///
|
||||
/// \param String : String object
|
||||
/// \param PointX : X coordinate of the point to transform
|
||||
/// \param PointY : Y coordinate of the point to transform
|
||||
/// \param X : Value to fill with the X coordinate of the converted point
|
||||
/// \param Y : Value to fill with the y coordinate of the converted point
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_TransformToGlobal(sfString* String, float PointX, float PointY, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the text of a string (from a multibyte string)
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Text : New text
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetText(sfString* String, const char* Text);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the text of a string (from a unicode string)
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Text : New text
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetUnicodeText(sfString* String, const sfUint32* Text);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the font of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Font : Font to use
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetFont(sfString* String, sfFont* Font);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the size of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Size : New size, in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetSize(sfString* String, float Size);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the style of a string
|
||||
///
|
||||
/// \param String : String to modify
|
||||
/// \param Size : New style (see sfStringStyle enum)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_SetStyle(sfString* String, unsigned long Style);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the text of a string (returns a unicode string)
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Text as UTF-32
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const sfUint32* sfString_GetUnicodeText(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the text of a string (returns an ANSI string)
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Text an a locale-dependant ANSI string
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfString_GetText(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the font used by a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Pointer to the font
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFont* sfString_GetFont(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the size of the characters of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Size of the characters
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfString_GetSize(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the style of a string
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Current string style (see sfStringStyle enum)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned long sfString_GetStyle(sfString* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the visual position of the Index-th character of the string,
|
||||
/// in coordinates relative to the string
|
||||
/// (note : translation, center, rotation and scale are not applied)
|
||||
///
|
||||
/// \param String : String to read
|
||||
/// \param Index : Index of the character
|
||||
/// \param X : Value to fill with the X coordinate of the position
|
||||
/// \param Y : Value to fill with the y coordinate of the position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfString_GetCharacterPos(sfString* String, size_t Index, float* X, float* Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the bounding rectangle of a string on screen
|
||||
///
|
||||
/// \param String : String to read
|
||||
///
|
||||
/// \return Rectangle contaning the string in screen coordinates
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFloatRect sfString_GetRect(sfString* String);
|
||||
|
||||
|
||||
#endif // SFML_STRING_H
|
163
CSFML/include/SFML/Graphics/View.h
Normal file
163
CSFML/include/SFML/Graphics/View.h
Normal file
@ -0,0 +1,163 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_VIEW_H
|
||||
#define SFML_VIEW_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Graphics/Rect.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// This class defines a view (position, size, etc.) ;
|
||||
/// you can consider it as a 2D camera
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfView sfView;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a default view (1000x1000)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfView* sfView_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a view from a rectangle
|
||||
///
|
||||
/// \param Rect : Rectangle defining the bounds of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfView* sfView_CreateFromRect(sfFloatRect Rect);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing view
|
||||
///
|
||||
/// \param View : View to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfView_Destroy(sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the center of a view
|
||||
///
|
||||
/// \param View : View to modify
|
||||
/// \param X : X coordinate of the new center
|
||||
/// \param Y : Y coordinate of the new center
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfView_SetCenter(sfView* View, float X, float Y);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the half-size of a view
|
||||
///
|
||||
/// \param View : View to modify
|
||||
/// \param HalfWidth : New half-width
|
||||
/// \param HalfHeight : New half-height
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfView_SetHalfSize(sfView* View, float HalfWidth, float HalfHeight);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Rebuild a view from a rectangle
|
||||
///
|
||||
/// \param View : View to modify
|
||||
/// \param ViewRect : Rectangle defining the position and size of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfView_SetFromRect(sfView* View, sfFloatRect ViewRect);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the X coordinate of the center of a view
|
||||
///
|
||||
/// \param View : View to read
|
||||
///
|
||||
/// \return X coordinate of the center of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfView_GetCenterX(sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the Y coordinate of the center of a view
|
||||
///
|
||||
/// \param View : View to read
|
||||
///
|
||||
/// \return Y coordinate of the center of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfView_GetCenterY(sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the half-width of the view
|
||||
///
|
||||
/// \param View : View to read
|
||||
///
|
||||
/// \return Half-width of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfView_GetHalfSizeX(sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the half-height of the view
|
||||
///
|
||||
/// \param View : View to read
|
||||
///
|
||||
/// \return Half-height of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfView_GetHalfSizeY(sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the bounding rectangle of a view
|
||||
///
|
||||
/// \param View : View to read
|
||||
///
|
||||
/// \return Bounding rectangle of the view
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFloatRect sfView_GetRect(sfView* View);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Move a view
|
||||
///
|
||||
/// \param View : View to move
|
||||
/// \param OffsetX : Offset to move the view, on X axis
|
||||
/// \param OffsetY : Offset to move the view, on Y axis
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfView_Move(sfView* View, float OffsetX, float OffsetY);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Resize a view rectangle to simulate a zoom / unzoom effect
|
||||
///
|
||||
/// \param View : View to zoom
|
||||
/// \param Factor : Zoom factor to apply, relative to the current zoom
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfView_Zoom(sfView* View, float Factor);
|
||||
|
||||
|
||||
#endif // SFML_VIEW_H
|
40
CSFML/include/SFML/Network.h
Normal file
40
CSFML/include/SFML/Network.h
Normal file
@ -0,0 +1,40 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_NETWORK_H
|
||||
#define SFML_NETWORK_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#include <SFML/System.h>
|
||||
#include <SFML/Network/IPAddress.h>
|
||||
#include <SFML/Network/Packet.h>
|
||||
#include <SFML/Network/Selector.h>
|
||||
#include <SFML/Network/SocketTCP.h>
|
||||
#include <SFML/Network/SocketUDP.h>
|
||||
|
||||
|
||||
#endif // SFML_NETWORK_H
|
486
CSFML/include/SFML/Network/Ftp.h
Normal file
486
CSFML/include/SFML/Network/Ftp.h
Normal file
@ -0,0 +1,486 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_FTP_H
|
||||
#define SFML_FTP_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Network/IPAddress.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enumerate all the FTP file transfer modes
|
||||
////////////////////////////////////////////////////////////
|
||||
enum sfFtpTransferMode
|
||||
{
|
||||
sfFtpBinary, ///< Binary mode (file is transfered as a sequence of bytes)
|
||||
sfFtpAscii, ///< Text mode using ASCII encoding
|
||||
sfFtpEbcdic ///< Text mode using EBCDIC encoding
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enumerate all the valid status codes returned in
|
||||
/// a FTP response
|
||||
////////////////////////////////////////////////////////////
|
||||
enum sfFtpStatus
|
||||
{
|
||||
// 1xx: the requested action is being initiated,
|
||||
// expect another reply before proceeding with a new command
|
||||
sfFtpRestartMarkerReply = 110, ///< Restart marker reply
|
||||
sfFtpServiceReadySoon = 120, ///< Service ready in N minutes
|
||||
sfFtpDataConnectionAlreadyOpened = 125, ///< Data connection already opened, transfer starting
|
||||
sfFtpOpeningDataConnection = 150, ///< File status ok, about to open data connection
|
||||
|
||||
// 2xx: the requested action has been successfully completed
|
||||
sfFtpOk = 200, ///< Command ok
|
||||
sfFtpPointlessCommand = 202, ///< Command not implemented
|
||||
sfFtpSystemStatus = 211, ///< System status, or system help reply
|
||||
sfFtpDirectoryStatus = 212, ///< Directory status
|
||||
sfFtpFileStatus = 213, ///< File status
|
||||
sfFtpHelpMessage = 214, ///< Help message
|
||||
sfFtpSystemType = 215, ///< NAME system type, where NAME is an official system name from the list in the Assigned Numbers document
|
||||
sfFtpServiceReady = 220, ///< Service ready for new user
|
||||
sfFtpClosingConnection = 221, ///< Service closing control connection
|
||||
sfFtpDataConnectionOpened = 225, ///< Data connection open, no transfer in progress
|
||||
sfFtpClosingDataConnection = 226, ///< Closing data connection, requested file action successful
|
||||
sfFtpEnteringPassiveMode = 227, ///< Entering passive mode
|
||||
sfFtpLoggedIn = 230, ///< User logged in, proceed. Logged out if appropriate
|
||||
sfFtpFileActionOk = 250, ///< Requested file action ok
|
||||
sfFtpDirectoryOk = 257, ///< PATHNAME created
|
||||
|
||||
// 3xx: the command has been accepted, but the requested action
|
||||
// is dormant, pending receipt of further information
|
||||
sfFtpNeedPassword = 331, ///< User name ok, need password
|
||||
sfFtpNeedAccountToLogIn = 332, ///< Need account for login
|
||||
sfFtpNeedInformation = 350, ///< Requested file action pending further information
|
||||
|
||||
// 4xx: the command was not accepted and the requested action did not take place,
|
||||
// but the error condition is temporary and the action may be requested again
|
||||
sfFtpServiceUnavailable = 421, ///< Service not available, closing control connection
|
||||
sfFtpDataConnectionUnavailable = 425, ///< Can't open data connection
|
||||
sfFtpTransferAborted = 426, ///< Connection closed, transfer aborted
|
||||
sfFtpFileActionAborted = 450, ///< Requested file action not taken
|
||||
sfFtpLocalError = 451, ///< Requested action aborted, local error in processing
|
||||
sfFtpInsufficientStorageSpace = 452, ///< Requested action not taken; insufficient storage space in system, file unavailable
|
||||
|
||||
// 5xx: the command was not accepted and
|
||||
// the requested action did not take place
|
||||
sfFtpCommandUnknown = 500, ///< Syntax error, command unrecognized
|
||||
sfFtpParametersUnknown = 501, ///< Syntax error in parameters or arguments
|
||||
sfFtpCommandNotImplemented = 502, ///< Command not implemented
|
||||
sfFtpBadCommandSequence = 503, ///< Bad sequence of commands
|
||||
sfFtpParameterNotImplemented = 504, ///< Command not implemented for that parameter
|
||||
sfFtpNotLoggedIn = 530, ///< Not logged in
|
||||
sfFtpNeedAccountToStore = 532, ///< Need account for storing files
|
||||
sfFtpFileUnavailable = 550, ///< Requested action not taken, file unavailable
|
||||
sfFtpPageTypeUnknown = 551, ///< Requested action aborted, page type unknown
|
||||
sfFtpNotEnoughMemory = 552, ///< Requested file action aborted, exceeded storage allocation
|
||||
sfFtpFilenameNotAllowed = 553, ///< Requested action not taken, file name not allowed
|
||||
|
||||
// 10xx: SFML custom codes
|
||||
sfFtpInvalidResponse = 1000, ///< Response is not a valid FTP one
|
||||
sfFtpConnectionFailed = 1001, ///< Connection with server failed
|
||||
sfFtpConnectionClosed = 1002, ///< Connection with server closed
|
||||
sfFtpInvalidFile = 1003 ///< Invalid file to upload / download
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfFtpListingResponse wraps a FTP directory listing response,
|
||||
/// which is basically :
|
||||
/// - a status code
|
||||
/// - a message
|
||||
/// - a list of directory and files
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfFtpListingResponse sfFtpListingResponse;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Ftp listing response
|
||||
///
|
||||
/// \param FtpResponse : Ftp listing response to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfFtpListingResponse_Destroy(sfFtpListingResponse* FtpListingResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Convenience function to check if the response status code
|
||||
/// means a success
|
||||
///
|
||||
/// \param FtpListingResponse : Ftp listing response
|
||||
///
|
||||
/// \return sfTrue if status is success (code < 400)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfFtpListingResponse_IsOk(sfFtpListingResponse* FtpListingResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the response status code
|
||||
///
|
||||
/// \param FtpListingResponse : Ftp listing response
|
||||
///
|
||||
/// \return Status code
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpStatus sfFtpListingResponse_GetStatus(sfFtpListingResponse* FtpListingResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the full message contained in the response
|
||||
///
|
||||
/// \param FtpListingResponse : Ftp listing response
|
||||
///
|
||||
/// \return The response message
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfFtpListingResponse_GetMessage(sfFtpListingResponse* FtpListingResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the number of filenames in the listing
|
||||
///
|
||||
/// \param FtpListingResponse : Ftp listing response
|
||||
///
|
||||
/// \return Total number of filenames
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API size_t sfFtpListingResponse_GetCount(sfFtpListingResponse* FtpListingResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the Index-th filename in the directory
|
||||
///
|
||||
/// \param FtpListingResponse : Ftp listing response
|
||||
/// \param Index : Index of the filename to get
|
||||
///
|
||||
/// \return Index-th filename
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfFtpListingResponse_GetFilename(sfFtpListingResponse* FtpListingResponse, size_t Index);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfFtpDirectoryResponse wraps a FTP directory response, which is basically :
|
||||
/// - a status code
|
||||
/// - a message
|
||||
/// - a directory name
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfFtpDirectoryResponse sfFtpDirectoryResponse;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Ftp directory response
|
||||
///
|
||||
/// \param FtpDirectoryResponse : Ftp directory response to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfFtpDirectoryResponse_Destroy(sfFtpDirectoryResponse* FtpDirectoryResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Convenience function to check if the response status code
|
||||
/// means a success
|
||||
///
|
||||
/// \param FtpDirectoryResponse : Ftp directory response
|
||||
///
|
||||
/// \return sfTrue if status is success (code < 400)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfFtpDirectoryResponse_IsOk(sfFtpDirectoryResponse* FtpDirectoryResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the response status code
|
||||
///
|
||||
/// \param FtpDirectoryResponse : Ftp directory response
|
||||
///
|
||||
/// \return Status code
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpStatus sfFtpDirectoryResponse_GetStatus(sfFtpDirectoryResponse* FtpDirectoryResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the full message contained in the response
|
||||
///
|
||||
/// \param FtpDirectoryResponse : Ftp directory response
|
||||
///
|
||||
/// \return The response message
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfFtpDirectoryResponse_GetMessage(sfFtpDirectoryResponse* FtpDirectoryResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the directory returned in the response
|
||||
///
|
||||
/// \param FtpDirectoryResponse : Ftp directory response
|
||||
///
|
||||
/// \return Directory name
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfFtpDirectoryResponse_GetDirectory(sfFtpDirectoryResponse* FtpDirectoryResponse);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfFtpResponse wraps a FTP response, which is basically :
|
||||
/// - a status code
|
||||
/// - a message
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfFtpResponse sfFtpResponse;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Ftp response
|
||||
///
|
||||
/// \param FtpResponse : Ftp response to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfFtpResponse_Destroy(sfFtpResponse* FtpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Convenience function to check if the response status code
|
||||
/// means a success
|
||||
///
|
||||
/// \param FtpResponse : Ftp response
|
||||
///
|
||||
/// \return sfTrue if status is success (code < 400)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfFtpResponse_IsOk(sfFtpResponse* FtpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the response status code
|
||||
///
|
||||
/// \param FtpResponse : Ftp response
|
||||
///
|
||||
/// \return Status code
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpStatus sfFtpResponse_GetStatus(sfFtpResponse* FtpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the full message contained in the response
|
||||
///
|
||||
/// \param FtpResponse : Ftp response
|
||||
///
|
||||
/// \return The response message
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfFtpResponse_GetMessage(sfFtpResponse* FtpResponse);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfFtp provides methods for manipulating the FTP
|
||||
/// protocol (described in RFC 959).
|
||||
/// It provides easy access and transfers to remote
|
||||
/// directories and files on a FTP server
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfFtp sfFtp;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new Ftp
|
||||
///
|
||||
/// \return Pointer to the new Ftp
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtp* sfFtp_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Ftp
|
||||
///
|
||||
/// \param Ftp : Ftp to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfFtp_Destroy(sfFtp* Ftp);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Connect to the specified FTP server
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param Server : FTP server to connect to
|
||||
/// \param Port : Port used for connection (21 by default, standard FTP port)
|
||||
/// \param Timeout : Maximum time to wait (0 to use no timeout)
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_Connect(sfFtp* Ftp, sfIPAddress Server, unsigned short Port, float Timeout);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Log in using anonymous account
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_LoginAnonymous(sfFtp* Ftp);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Log in using a username and a password
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param UserName : User name
|
||||
/// \param Password : Password
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_Login(sfFtp* Ftp, const char* UserName, const char* Password);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Close the connection with FTP server
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_Disconnect(sfFtp* Ftp);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Send a null command just to prevent from being disconnected
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_KeepAlive(sfFtp* Ftp);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current working directory
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpDirectoryResponse* sfFtp_GetWorkingDirectory(sfFtp* Ftp);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the contents of the given directory
|
||||
/// (subdirectories and files)
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param Directory : Directory to list ("" by default, the current one)
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpListingResponse* sfFtp_GetDirectoryListing(sfFtp* Ftp, const char* Directory);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the current working directory
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param Directory : New directory, relative to the current one
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_ChangeDirectory(sfFtp* Ftp, const char* Directory);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Go to the parent directory of the current one
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_ParentDirectory(sfFtp* Ftp);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new directory
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param Name : Name of the directory to create
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_MakeDirectory(sfFtp* Ftp, const char* Name);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Remove an existing directory
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param Name : Name of the directory to remove
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_DeleteDirectory(sfFtp* Ftp, const char* Name);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Rename a file
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param File : File to rename
|
||||
/// \param NewName : New name
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_RenameFile(sfFtp* Ftp, const char* File, const char* NewName);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Remove an existing file
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param Name : File to remove
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_DeleteFile(sfFtp* Ftp, const char* Name);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Download a file from the server
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param DistantFile : Path of the distant file to download
|
||||
/// \param DestPath : Where to put to file on the local computer
|
||||
/// \param Mode : Transfer mode (binary by default)
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_Download(sfFtp* Ftp, const char* DistantFile, const char* DestPath, sfFtpTransferMode Mode);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Upload a file to the server
|
||||
///
|
||||
/// \param Ftp : Ftp instance
|
||||
/// \param LocalFile : Path of the local file to upload
|
||||
/// \param DestPath : Where to put to file on the server
|
||||
/// \param Mode : Transfer mode (binary by default)
|
||||
///
|
||||
/// \return Server response to the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfFtpResponse* sfFtp_Upload(sfFtp* Ftp, const char* LocalFile, const char* DestPath, sfFtpTransferMode Mode);
|
||||
|
||||
|
||||
#endif // SFML_FTP_H
|
282
CSFML/include/SFML/Network/Http.h
Normal file
282
CSFML/include/SFML/Network/Http.h
Normal file
@ -0,0 +1,282 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_HTTP_H
|
||||
#define SFML_HTTP_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enumerate the available HTTP methods for a request
|
||||
////////////////////////////////////////////////////////////
|
||||
enum sfHttpMethod
|
||||
{
|
||||
sfHttpGet, ///< Request in get mode, standard method to retrieve a page
|
||||
sfHttpPost, ///< Request in post mode, usually to send data to a page
|
||||
sfHttpHead ///< Request a page's header only
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enumerate all the valid status codes returned in
|
||||
/// a HTTP response
|
||||
////////////////////////////////////////////////////////////
|
||||
enum sfHttpStatus
|
||||
{
|
||||
// 2xx: success
|
||||
sfHttpOk = 200, ///< Most common code returned when operation was successful
|
||||
sfHttpCreated = 201, ///< The resource has successfully been created
|
||||
sfHttpAccepted = 202, ///< The request has been accepted, but will be processed later by the server
|
||||
sfHttpNoContent = 204, ///< Sent when the server didn't send any data in return
|
||||
|
||||
// 3xx: redirection
|
||||
sfHttpMultipleChoices = 300, ///< The requested page can be accessed from several locations
|
||||
sfHttpMovedPermanently = 301, ///< The requested page has permanently moved to a new location
|
||||
sfHttpMovedTemporarily = 302, ///< The requested page has temporarily moved to a new location
|
||||
sfHttpNotModified = 304, ///< For conditionnal requests, means the requested page hasn't changed and doesn't need to be refreshed
|
||||
|
||||
// 4xx: client error
|
||||
sfHttpBadRequest = 400, ///< The server couldn't understand the request (syntax error)
|
||||
sfHttpUnauthorized = 401, ///< The requested page needs an authentification to be accessed
|
||||
sfHttpForbidden = 403, ///< The requested page cannot be accessed at all, even with authentification
|
||||
sfHttpNotFound = 404, ///< The requested page doesn't exist
|
||||
|
||||
// 5xx: server error
|
||||
sfHttpInternalServerError = 500, ///< The server encountered an unexpected error
|
||||
sfHttpNotImplemented = 501, ///< The server doesn't implement a requested feature
|
||||
sfHttpBadGateway = 502, ///< The gateway server has received an error from the source server
|
||||
sfHttpServiceNotAvailable = 503, ///< The server is temporarily unavailable (overloaded, in maintenance, ...)
|
||||
|
||||
// 10xx: SFML custom codes
|
||||
sfHttpInvalidResponse = 1000, ///< Response is not a valid HTTP one
|
||||
sfHttpConnectionFailed = 1001 ///< Connection with server failed
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfHttpRequest wraps an HTTP request, which is basically :
|
||||
/// - a header with a method, a target URI, and a set of field/value pairs
|
||||
/// - an optional body (for POST requests)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfHttpRequest sfHttpRequest;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new Http request
|
||||
///
|
||||
/// \return Pointer to the new Http request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfHttpRequest* sfHttpRequest_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Http request
|
||||
///
|
||||
/// \param HttpRequest : Http request to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpRequest_Destroy(sfHttpRequest* HttpRequest);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the value of a field; the field is added if it doesn't exist
|
||||
///
|
||||
/// \param HttpRequest : Http request to modify
|
||||
/// \param Field : Name of the field to set (case-insensitive)
|
||||
/// \param Value : Value of the field
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpRequest_SetField(sfHttpRequest* HttpRequest, const char* Field, const char* Value);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the request method.
|
||||
/// This parameter is sfHttpGet by default
|
||||
///
|
||||
/// \param HttpRequest : Http request to modify
|
||||
/// \param RequestMethod : Method to use for the request
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpRequest_SetMethod(sfHttpRequest* HttpRequest, sfHttpMethod Method);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the target URI of the request.
|
||||
/// This parameter is "/" by default
|
||||
///
|
||||
/// \param HttpRequest : Http request to modify
|
||||
/// \param URI : URI to request, local to the host
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpRequest_SetURI(sfHttpRequest* HttpRequest, const char* URI);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the HTTP version of the request.
|
||||
/// This parameter is 1.0 by default
|
||||
///
|
||||
/// \param HttpRequest : Http request to modify
|
||||
/// \param Major : Major version number
|
||||
/// \param Minor : Minor version number
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpRequest_SetHttpVersion(sfHttpRequest* HttpRequest, unsigned int Major, unsigned int Minor);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the body of the request. This parameter is optional and
|
||||
/// makes sense only for POST requests.
|
||||
/// This parameter is empty by default
|
||||
///
|
||||
/// \param HttpRequest : Http request to modify
|
||||
/// \param Body : Content of the request body
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpRequest_SetBody(sfHttpRequest* HttpRequest, const char* Body);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfHttpResponse wraps an HTTP response, which is basically :
|
||||
/// - a header with a status code and a set of field/value pairs
|
||||
/// - a body (the content of the requested resource)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfHttpResponse sfHttpResponse;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Http response
|
||||
///
|
||||
/// \param HttpResponse : Http response to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttpResponse_Destroy(sfHttpResponse* HttpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the value of a field; returns NULL if the field doesn't exist
|
||||
///
|
||||
/// \param HttpResponse : Http response
|
||||
/// \param Field : Field to get
|
||||
///
|
||||
/// \return Value of the field (NULL if it doesn't exist)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfHttpResponse_GetField(sfHttpResponse* HttpResponse, const char* Field);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a response
|
||||
///
|
||||
/// \param HttpResponse : Http response
|
||||
///
|
||||
/// \return Status of the response
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfHttpStatus sfHttpResponse_GetStatus(sfHttpResponse* HttpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the major HTTP version of a response
|
||||
///
|
||||
/// \param HttpResponse : Http response
|
||||
///
|
||||
/// \return HTTP major version of the response
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfHttpResponse_GetMajorVersion(sfHttpResponse* HttpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minor HTTP version of a response
|
||||
///
|
||||
/// \param HttpResponse : Http response
|
||||
///
|
||||
/// \return HTTP minor version of the response
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfHttpResponse_GetMinorVersion(sfHttpResponse* HttpResponse);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the body of the response. The body can contain :
|
||||
/// - the requested page (for GET requests)
|
||||
/// - a response from the server (for POST requests)
|
||||
/// - nothing (for HEAD requests)
|
||||
/// - an error message (in case of an error)
|
||||
///
|
||||
/// \param HttpResponse : Http response
|
||||
///
|
||||
/// \return Body of the response (empty string if no body)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfHttpResponse_GetBody(sfHttpResponse* HttpResponse);
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfHttp provides methods for manipulating the HTTP
|
||||
/// protocol (described in RFC 1945).
|
||||
/// It can connect to a website, get its files, send requests, etc.
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfHttp sfHttp;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new Http object
|
||||
///
|
||||
/// \return Pointer to the new Http
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfHttp* sfHttp_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing Http object
|
||||
///
|
||||
/// \param Http : Http to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttp_Destroy(sfHttp* Http);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the target host of a Http server
|
||||
///
|
||||
/// \param Http : Http object
|
||||
/// \param Host : Web server to connect to
|
||||
/// \param Port : Port to use for connection (0 to use the standard port of the protocol used)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfHttp_SetHost(sfHttp* Http, const char* Host, unsigned short Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Send a HTTP request and return the server's response.
|
||||
/// You must be connected to a host before sending requests.
|
||||
/// Any missing mandatory header field will be added with an appropriate value.
|
||||
/// Warning : this function waits for the server's response and may
|
||||
/// not return instantly; use a thread if you don't want to block your
|
||||
/// application.
|
||||
///
|
||||
/// \param Http : Http object
|
||||
/// \param Request : Request to send
|
||||
/// \param Timeout : Maximum time to wait (0 to use no timeout)
|
||||
///
|
||||
/// \return Server's response, or NULL if request is invalid
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfHttpResponse* sfHttp_SendRequest(sfHttp* Http, sfHttpRequest* Request, float Timeout);
|
||||
|
||||
|
||||
#endif // SFML_HTTP_H
|
133
CSFML/include/SFML/Network/IPAddress.h
Normal file
133
CSFML/include/SFML/Network/IPAddress.h
Normal file
@ -0,0 +1,133 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_IPADDRESS_H
|
||||
#define SFML_IPADDRESS_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfIPAddress provides easy manipulation of IP v4 addresses
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
char Address[16];
|
||||
} sfIPAddress;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct an address from a string
|
||||
///
|
||||
/// \param String : IP address ("xxx.xxx.xxx.xxx") or network name
|
||||
///
|
||||
/// \return Resulting address
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIPAddress sfIPAddress_FromString(const char* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct an address from 4 bytes
|
||||
///
|
||||
/// \param Byte0 : First byte of the address
|
||||
/// \param Byte1 : Second byte of the address
|
||||
/// \param Byte2 : Third byte of the address
|
||||
/// \param Byte3 : Fourth byte of the address
|
||||
///
|
||||
/// \return Resulting address
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIPAddress sfIPAddress_FromBytes(sfUint8 Byte0, sfUint8 Byte1, sfUint8 Byte2, sfUint8 Byte3);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct the address from a 32-bits integer
|
||||
///
|
||||
/// \param Address : 4 bytes of the address packed into a 32-bits integer
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIPAddress sfIPAddress_FromInteger(sfUint32 Address);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell if an address is a valid one
|
||||
///
|
||||
/// \param Address : Address to check
|
||||
///
|
||||
/// \return sfTrue if address has a valid syntax
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfIPAddress_IsValid(sfIPAddress Address);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a string representation of an address
|
||||
///
|
||||
/// \param Address : Address to convert
|
||||
/// \param String : Char array to fill (size must be >= 16)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfIPAddress_ToString(sfIPAddress Address, char* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get an integer representation of the address
|
||||
///
|
||||
/// \param Address : Address to convert
|
||||
///
|
||||
/// \return 32-bits integer containing the 4 bytes of the address, in system endianness
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfUint32 sfIPAddress_ToInteger(sfIPAddress Address);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the computer's local IP address (from the LAN point of view)
|
||||
///
|
||||
/// \return Local IP address
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIPAddress sfIPAddress_GetLocalAddress();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the computer's public IP address (from the web point of view).
|
||||
/// The only way to get a public address is to ask it to a
|
||||
/// distant website ; as a consequence, this function may be
|
||||
/// very slow -- use it as few as possible !
|
||||
///
|
||||
/// \param Timeout : Maximum time to wait, in seconds (use 0 for no timeout)
|
||||
///
|
||||
/// \return Public IP address
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIPAddress sfIPAddress_GetPublicAddress(float Timeout);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the computer's loopback address
|
||||
///
|
||||
/// \return Local host IP address (127.0.0.1, or "localhost")
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfIPAddress sfIPAddress_LocalHost();
|
||||
|
||||
|
||||
#endif // SFML_IPADDRESS_H
|
153
CSFML/include/SFML/Network/Packet.h
Normal file
153
CSFML/include/SFML/Network/Packet.h
Normal file
@ -0,0 +1,153 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_PACKET_H
|
||||
#define SFML_PACKET_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfPacket wraps data to send / to receive through the network
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfPacket sfPacket;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new empty packet
|
||||
///
|
||||
/// \return A new sfPacket object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfPacket* sfPacket_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing packet
|
||||
///
|
||||
/// \param Packet : Packet to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPacket_Destroy(sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Append data to the end of a packet
|
||||
///
|
||||
/// \param Packet : Packet to fill
|
||||
/// \param Data : Pointer to the bytes to append
|
||||
/// \param SizeInBytes : Number of bytes to append
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPacket_Append(sfPacket* Packet, void* Data, size_t SizeInBytes);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Clear all the data of a packet
|
||||
///
|
||||
/// \param Packet : Packet to clear
|
||||
///
|
||||
///////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPacket_Clear(sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a pointer to the data contained in a packet
|
||||
/// Warning : the returned pointer may be invalid after you
|
||||
/// append data to the packet
|
||||
///
|
||||
/// \param Packet : Packet to get data from
|
||||
///
|
||||
/// \return Pointer to the data
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API const char* sfPacket_GetData(sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the size of the data contained in a packet
|
||||
///
|
||||
/// \param Packet : Packet to get data size from
|
||||
///
|
||||
/// \return Data size, in bytes
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API size_t sfPacket_GetDataSize(sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell if the reading position has reached the end of the packet
|
||||
///
|
||||
/// \param Packet : Packet to check
|
||||
///
|
||||
/// \return sfTrue if all data have been read into the packet
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfPacket_EndOfPacket(sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the validity of packet
|
||||
///
|
||||
/// \param Packet : Packet to check
|
||||
///
|
||||
/// \return sfTrue if last data extraction from packet was successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfPacket_CanRead(sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Functions to extract data from a packet
|
||||
///
|
||||
/// \param Packet : Packet to read
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfPacket_ReadBool(sfPacket* Packet);
|
||||
CSFML_API sfInt8 sfPacket_ReadInt8(sfPacket* Packet);
|
||||
CSFML_API sfUint8 sfPacket_ReadUint8(sfPacket* Packet);
|
||||
CSFML_API sfInt16 sfPacket_ReadInt16(sfPacket* Packet);
|
||||
CSFML_API sfUint16 sfPacket_ReadUint16(sfPacket* Packet);
|
||||
CSFML_API sfInt32 sfPacket_ReadInt32(sfPacket* Packet);
|
||||
CSFML_API sfUint32 sfPacket_ReadUint32(sfPacket* Packet);
|
||||
CSFML_API float sfPacket_ReadFloat(sfPacket* Packet);
|
||||
CSFML_API double sfPacket_ReadDouble(sfPacket* Packet);
|
||||
CSFML_API void sfPacket_ReadString(sfPacket* Packet, char* String);
|
||||
CSFML_API void sfPacket_ReadWideString(sfPacket* Packet, wchar_t* String);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Functions to insert data into a packet
|
||||
///
|
||||
/// \param Packet : Packet to write
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfPacket_WriteBool(sfPacket* Packet, sfBool);
|
||||
CSFML_API void sfPacket_WriteInt8(sfPacket* Packet, sfInt8);
|
||||
CSFML_API void sfPacket_WriteUint8(sfPacket* Packet, sfUint8);
|
||||
CSFML_API void sfPacket_WriteInt16(sfPacket* Packet, sfInt16);
|
||||
CSFML_API void sfPacket_WriteUint16(sfPacket* Packet, sfUint16);
|
||||
CSFML_API void sfPacket_WriteInt32(sfPacket* Packet, sfInt32);
|
||||
CSFML_API void sfPacket_WriteUint32(sfPacket* Packet, sfUint32);
|
||||
CSFML_API void sfPacket_WriteFloat(sfPacket* Packet, float);
|
||||
CSFML_API void sfPacket_WriteDouble(sfPacket* Packet, double);
|
||||
CSFML_API void sfPacket_WriteString(sfPacket* Packet, const char* String);
|
||||
CSFML_API void sfPacket_WriteWideString(sfPacket* Packet, const wchar_t* String);
|
||||
|
||||
|
||||
#endif // SFML_PACKET_H
|
120
CSFML/include/SFML/Network/Selector.h
Normal file
120
CSFML/include/SFML/Network/Selector.h
Normal file
@ -0,0 +1,120 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SELECTOR_H
|
||||
#define SFML_SELECTOR_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Network/SocketTCP.h>
|
||||
#include <SFML/Network/SocketUDP.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSelectorTCP and sfSelectorUDP allow reading from multiple sockets
|
||||
/// without blocking. It's a kind of multiplexer
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSelectorTCP sfSelectorTCP;
|
||||
typedef struct sfSelectorUDP sfSelectorUDP;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new selector
|
||||
///
|
||||
/// \return A new sfSelector object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSelectorTCP* sfSelectorTCP_Create();
|
||||
CSFML_API sfSelectorUDP* sfSelectorUDP_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing selector
|
||||
///
|
||||
/// \param Selector : Selector to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSelectorTCP_Destroy(sfSelectorTCP* Selector);
|
||||
CSFML_API void sfSelectorUDP_Destroy(sfSelectorUDP* Selector);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Add a socket to watch to a selector
|
||||
///
|
||||
/// \param Selector : Selector to add the socket to
|
||||
/// \param Socket : Socket to add
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSelectorTCP_Add(sfSelectorTCP* Selector, sfSocketTCP* Socket);
|
||||
CSFML_API void sfSelectorUDP_Add(sfSelectorUDP* Selector, sfSocketUDP* Socket);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Remove a socket from a selector
|
||||
///
|
||||
/// \param Selector : Selector to remove the socket from
|
||||
/// \param Socket : Socket to remove
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSelectorTCP_Remove(sfSelectorTCP* Selector, sfSocketTCP* Socket);
|
||||
CSFML_API void sfSelectorUDP_Remove(sfSelectorUDP* Selector, sfSocketUDP* Socket);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Remove all sockets from a selector
|
||||
///
|
||||
/// \param Selector : Selector to remove the socket from
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSelectorTCP_Clear(sfSelectorTCP* Selector);
|
||||
CSFML_API void sfSelectorUDP_Clear(sfSelectorUDP* Selector);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Wait and collect sockets which are ready for reading.
|
||||
/// This functions will return either when at least one socket
|
||||
/// is ready, or when the given time is out
|
||||
///
|
||||
/// \param Selector : Selector to check
|
||||
/// \param Timeout : Maximum time to wait, in seconds (0 to disable timeout)
|
||||
///
|
||||
/// \return Number of sockets ready
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfSelectorTCP_Wait(sfSelectorTCP* Selector, float Timeout);
|
||||
CSFML_API unsigned int sfSelectorUDP_Wait(sfSelectorUDP* Selector, float Timeout);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// After a call to Wait(), get the Index-th socket which is
|
||||
/// ready for reading. The total number of sockets ready
|
||||
/// is the integer returned by the previous call to Wait()
|
||||
///
|
||||
/// \param Selector : Selector to check
|
||||
/// \param Index : Index of the socket to get
|
||||
///
|
||||
/// \return The Index-th socket
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketTCP* sfSelectorTCP_GetSocketReady(sfSelectorTCP* Selector, unsigned int Index);
|
||||
CSFML_API sfSocketUDP* sfSelectorUDP_GetSocketReady(sfSelectorUDP* Selector, unsigned int Index);
|
||||
|
||||
|
||||
#endif // SFML_SELECTOR_H
|
43
CSFML/include/SFML/Network/SocketStatus.h
Normal file
43
CSFML/include/SFML/Network/SocketStatus.h
Normal file
@ -0,0 +1,43 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOCKETSTATUS_H
|
||||
#define SFML_SOCKETSTATUS_H
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Define the status that can be returned by the socket
|
||||
/// functions
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfSocketDone,
|
||||
sfSocketNotReady,
|
||||
sfSocketDisconnected,
|
||||
sfSocketError
|
||||
|
||||
} sfSocketStatus;
|
||||
|
||||
|
||||
#endif // SFML_SOCKETSTATUS_H
|
167
CSFML/include/SFML/Network/SocketTCP.h
Normal file
167
CSFML/include/SFML/Network/SocketTCP.h
Normal file
@ -0,0 +1,167 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOCKETTCP_H
|
||||
#define SFML_SOCKETTCP_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Network/IPAddress.h>
|
||||
#include <SFML/Network/Packet.h>
|
||||
#include <SFML/Network/SocketStatus.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// SocketTCP wraps a socket using TCP protocol to
|
||||
/// send data safely (but a bit slower)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSocketTCP sfSocketTCP;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new TCP socket
|
||||
///
|
||||
/// \return Pointer to the new socket
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketTCP* sfSocketTCP_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing TCP socket
|
||||
///
|
||||
/// \param Socket : Socket to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSocketTCP_Destroy(sfSocketTCP* Socket);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the blocking state of a TCP socket.
|
||||
/// The default behaviour of a socket is blocking
|
||||
///
|
||||
/// \param Socket : Socket to modify
|
||||
/// \param Blocking : Pass sfTrue to set the socket as blocking, or false for non-blocking
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSocketTCP_SetBlocking(sfSocketTCP* Socket, sfBool Blocking);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Connect a TCP socket to another computer on a specified port
|
||||
///
|
||||
/// \param Socket : Socket to use for connecting
|
||||
/// \param Port : Port to use for transfers (warning : ports < 1024 are reserved)
|
||||
/// \param HostAddress : IP Address of the host to connect to
|
||||
/// \param Timeout : Maximum time to wait (0 to use no timeout)
|
||||
///
|
||||
/// \return sfTrue if operation has been successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketTCP_Connect(sfSocketTCP* Socket, unsigned short Port, sfIPAddress HostAddress, float Timeout);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Listen to a specified port for incoming data or connections
|
||||
///
|
||||
/// \param Socket : Socket to use for listening
|
||||
/// \param Port : Port to listen to
|
||||
///
|
||||
/// \return sfTrue if operation has been successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSocketTCP_Listen(sfSocketTCP* Socket, unsigned short Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Wait for a connection (must be listening to a port).
|
||||
/// This function is blocking, ie. it won't return before
|
||||
/// a connection has been accepted
|
||||
///
|
||||
/// \param Socket : Socket to use for accepting
|
||||
/// \param Connected : Pointer to a socket pointer that will be filled with the connected client
|
||||
/// \param Address : Pointer to an address to fill with client infos
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketTCP_Accept(sfSocketTCP* Socket, sfSocketTCP** Connected, sfIPAddress* Address);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Send an array of bytes to the host (must be connected first)
|
||||
///
|
||||
/// \param Socket : Socket to use for sending
|
||||
/// \param Data : Pointer to the bytes to send
|
||||
/// \param Size : Number of bytes to send
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketTCP_Send(sfSocketTCP* Socket, const char* Data, size_t Size);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Receive an array of bytes from the host (must be connected first)
|
||||
///
|
||||
/// \param Socket : Socket to use for receiving
|
||||
/// \param Data : Pointer to a byte array to fill (make sure it is big enough)
|
||||
/// \param MaxSize : Maximum number of bytes to read
|
||||
/// \param SizeReceived : Number of bytes received
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketTCP_Receive(sfSocketTCP* Socket, char* Data, size_t MaxSize, size_t* SizeReceived);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Send a packet of data to the host (must be connected first)
|
||||
///
|
||||
/// \param Socket : Socket to use for sending
|
||||
/// \param Packet : Packet to send
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketTCP_SendPacket(sfSocketTCP* Socket, sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Receive a packet from the host (must be connected first)
|
||||
///
|
||||
/// \param Socket : Socket to use for receiving
|
||||
/// \param Packet : Packet to fill with received data
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketTCP_ReceivePacket(sfSocketTCP* Socket, sfPacket* Packet);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Check if a socket is in a valid state ; this function
|
||||
/// can be called any time to check if the socket is OK
|
||||
///
|
||||
/// \param Socket : Socket to check
|
||||
///
|
||||
/// \return True if the socket is valid
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSocketTCP_IsValid(sfSocketTCP* Socket);
|
||||
|
||||
|
||||
#endif // SFML_SOCKETTCP_H
|
162
CSFML/include/SFML/Network/SocketUDP.h
Normal file
162
CSFML/include/SFML/Network/SocketUDP.h
Normal file
@ -0,0 +1,162 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SOCKETUDP_H
|
||||
#define SFML_SOCKETUDP_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Network/IPAddress.h>
|
||||
#include <SFML/Network/Packet.h>
|
||||
#include <SFML/Network/SocketStatus.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfSocketUDP wraps a socket using UDP protocol to
|
||||
/// send data fastly (but with less safety)
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfSocketUDP sfSocketUDP;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new UDP socket
|
||||
///
|
||||
/// \return Pointer to the new socket
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketUDP* sfSocketUDP_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing UDP socket
|
||||
///
|
||||
/// \param Socket : Socket to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSocketUDP_Destroy(sfSocketUDP* Socket);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the blocking state of a UDP socket.
|
||||
/// The default behaviour of a socket is blocking
|
||||
///
|
||||
/// \param Socket : Socket to modify
|
||||
/// \param Blocking : Pass sfTrue to set the socket as blocking, or false for non-blocking
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSocketUDP_SetBlocking(sfSocketUDP* Socket, sfBool Blocking);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Bind a socket to a specific port
|
||||
///
|
||||
/// \param Socket : Socket to bind
|
||||
/// \param Port : Port to bind the socket to
|
||||
///
|
||||
/// \return True if operation has been successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSocketUDP_Bind(sfSocketUDP* Socket, unsigned short Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Unbind a socket from its previous port, if any
|
||||
///
|
||||
/// \param Socket : Socket to unbind
|
||||
///
|
||||
/// \return sfTrue if operation has been successful
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSocketUDP_Unbind(sfSocketUDP* Socket);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Send an array of bytes
|
||||
///
|
||||
/// \param Socket : Socket to use for sending
|
||||
/// \param Data : Pointer to the bytes to send
|
||||
/// \param Size : Number of bytes to send
|
||||
/// \param Address : Address of the computer to send the packet to
|
||||
/// \param Port : Port to use for communication
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketUDP_Send(sfSocketUDP* Socket, const char* Data, size_t Size, sfIPAddress Address, unsigned short Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Receive an array of bytes.
|
||||
/// This function is blocking, ie. it won't return before some
|
||||
/// bytes have been received
|
||||
///
|
||||
/// \param Socket : Socket to use for receiving
|
||||
/// \param Data : Pointer to a byte array to fill (make sure it is big enough)
|
||||
/// \param MaxSize : Maximum number of bytes to read
|
||||
/// \param SizeReceived : Number of bytes received
|
||||
/// \param Address : Address of the computer which sent the data
|
||||
/// \param Port : Port on which the remote computer sent the data
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketUDP_Receive(sfSocketUDP* Socket, char* Data, size_t MaxSize, size_t* SizeReceived, sfIPAddress* Address, unsigned short* Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Send a packet of data
|
||||
///
|
||||
/// \param Socket : Socket to use for sending
|
||||
/// \param Packet : Packet to send
|
||||
/// \param Address : Address of the computer to send the packet to
|
||||
/// \param Port : Port to use for communication
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketUDP_SendPacket(sfSocketUDP* Socket, sfPacket* Packet, sfIPAddress Address, unsigned short Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Receive a packet.
|
||||
/// This function is blocking, ie. it won't return before a
|
||||
/// packet is received
|
||||
///
|
||||
/// \param Socket : Socket to use for receiving
|
||||
/// \param Packet : Packet to fill with received data
|
||||
/// \param Address : Address of the computer which sent the packet
|
||||
/// \param Port : Port on which the remote computer sent the data
|
||||
///
|
||||
/// \return Socket status
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfSocketStatus sfSocketUDP_ReceivePacket(sfSocketUDP* Socket, sfPacket* Packet, sfIPAddress* Address, unsigned short* Port);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Check if a socket is in a valid state ; this function
|
||||
/// can be called any time to check if the socket is OK
|
||||
///
|
||||
/// \param Socket : Socket to check
|
||||
///
|
||||
/// \return sfTrue if the socket is valid
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfSocketUDP_IsValid(sfSocketUDP* Socket);
|
||||
|
||||
|
||||
#endif // SFML_SOCKETUDP_H
|
40
CSFML/include/SFML/System.h
Normal file
40
CSFML/include/SFML/System.h
Normal file
@ -0,0 +1,40 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SYSTEM_H
|
||||
#define SFML_SYSTEM_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/System/Clock.h>
|
||||
#include <SFML/System/Mutex.h>
|
||||
#include <SFML/System/Randomizer.h>
|
||||
#include <SFML/System/Sleep.h>
|
||||
#include <SFML/System/Thread.h>
|
||||
|
||||
|
||||
#endif // SFML_SYSTEM_H
|
72
CSFML/include/SFML/System/Clock.h
Normal file
72
CSFML/include/SFML/System/Clock.h
Normal file
@ -0,0 +1,72 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_CLOCK_H
|
||||
#define SFML_CLOCK_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfClock is an utility structure for manipulating time
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfClock sfClock;
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new clock and start it
|
||||
///
|
||||
/// \return A new sfClock object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfClock* sfClock_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing clock
|
||||
///
|
||||
/// \param Clock : Clock to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfClock_Destroy(sfClock* Clock);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the time elapsed for a clock
|
||||
///
|
||||
/// \param Clock : Clock to get time from
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfClock_GetTime(sfClock* Clock);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Restart a clock
|
||||
///
|
||||
/// \param Clock : Clock to restart
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfClock_Reset(sfClock* Clock);
|
||||
|
||||
|
||||
#endif // SFML_CLOCK_H
|
74
CSFML/include/SFML/System/Mutex.h
Normal file
74
CSFML/include/SFML/System/Mutex.h
Normal file
@ -0,0 +1,74 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_MUTEX_H
|
||||
#define SFML_MUTEX_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfMutex defines a mutex (MUTual EXclusion) object,
|
||||
/// that allows a thread to lock critical instructions
|
||||
/// to avoid simultaneous access with other threads.
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfMutex sfMutex;
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new mutex
|
||||
///
|
||||
/// \return A new sfMutex object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfMutex* sfMutex_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing mutex
|
||||
///
|
||||
/// \param Mutex : Mutex to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMutex_Destroy(sfMutex* Mutex);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Lock a mutex
|
||||
///
|
||||
/// \param Mutex : Mutex to lock
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMutex_Lock(sfMutex* Mutex);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Unlock a mutex
|
||||
///
|
||||
/// \param Mutex : Mutex to unlock
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfMutex_Unlock(sfMutex* Mutex);
|
||||
|
||||
|
||||
#endif // SFML_MUTEX_H
|
74
CSFML/include/SFML/System/Randomizer.h
Normal file
74
CSFML/include/SFML/System/Randomizer.h
Normal file
@ -0,0 +1,74 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_RANDOMIZER_H
|
||||
#define SFML_RANDOMIZER_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the seed for the random numbers generator. Using a known seed
|
||||
/// allows you to reproduce the same sequence of random numbers
|
||||
///
|
||||
/// \param Seed : Number to use as the seed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfRandom_SetSeed(unsigned int Seed);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the seed used to generate random numbers the generator
|
||||
///
|
||||
/// \return Current seed
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfRandom_GetSeed();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a random float number in a given range
|
||||
///
|
||||
/// \return Start : Start of the range
|
||||
/// \return End : End of the range
|
||||
///
|
||||
/// \return Random number in [Begin, End]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfRandom_Float(float Begin, float End);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a random integer number in a given range
|
||||
///
|
||||
/// \return Start : Start of the range
|
||||
/// \return End : End of the range
|
||||
///
|
||||
/// \return Random number in [Begin, End]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API int sfRandom_Int(int Begin, int End);
|
||||
|
||||
|
||||
#endif // SFML_RANDOMIZER_H
|
43
CSFML/include/SFML/System/Sleep.h
Normal file
43
CSFML/include/SFML/System/Sleep.h
Normal file
@ -0,0 +1,43 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SLEEP_H
|
||||
#define SFML_SLEEP_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Make the current thread sleep for a given time
|
||||
///
|
||||
/// \param Duration : Time to sleep, in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfSleep(float Duration);
|
||||
|
||||
|
||||
#endif // SFML_SLEEP_H
|
85
CSFML/include/SFML/System/Thread.h
Normal file
85
CSFML/include/SFML/System/Thread.h
Normal file
@ -0,0 +1,85 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_THREAD_H
|
||||
#define SFML_THREAD_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfThread defines an easy way to manipulate a thread
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfThread sfThread;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new thread from a function pointer
|
||||
///
|
||||
/// \param Function : Entry point of the thread
|
||||
/// \param UserData : Data to pass to the thread function
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfThread* sfThread_Create(void (*Function)(void*), void* UserData);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing thread
|
||||
///
|
||||
/// \param Thread : Thread to delete
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfThread_Destroy(sfThread* Thread);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Run a thread
|
||||
///
|
||||
/// \param Thread : Thread to launch
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfThread_Launch(sfThread* Thread);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Wait until a thread finishes
|
||||
///
|
||||
/// \param Thread : Thread to wait for
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfThread_Wait(sfThread* Thread);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Terminate a thread
|
||||
/// Terminating a thread with this function is not safe,
|
||||
/// you should rather try to make the thread function
|
||||
/// terminate by itself
|
||||
///
|
||||
/// \param Thread : Thread to terminate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfThread_Terminate(sfThread* Thread);
|
||||
|
||||
|
||||
#endif // SFML_THREAD_H
|
40
CSFML/include/SFML/Window.h
Normal file
40
CSFML/include/SFML/Window.h
Normal file
@ -0,0 +1,40 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_SFML_WINDOW_H
|
||||
#define SFML_SFML_WINDOW_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#include <SFML/System.h>
|
||||
#include <SFML/Window/Context.h>
|
||||
#include <SFML/Window/Event.h>
|
||||
#include <SFML/Window/Input.h>
|
||||
#include <SFML/Window/VideoMode.h>
|
||||
#include <SFML/Window/Window.h>
|
||||
|
||||
|
||||
#endif // SFML_SFML_WINDOW_H
|
68
CSFML/include/SFML/Window/Context.h
Normal file
68
CSFML/include/SFML/Window/Context.h
Normal file
@ -0,0 +1,68 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_CONTEXT_H
|
||||
#define SFML_CONTEXT_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Class wrapping an OpenGL context with no window.
|
||||
/// This class is for internal use mainly, it is required
|
||||
/// to solve tricky problems involving multi-threading
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfContext sfContext;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new context
|
||||
///
|
||||
/// \return New context
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfContext* sfContext_Create();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing context
|
||||
///
|
||||
/// \param Context : Context to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfContext_Destroy(sfContext* Context);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Activate or deactivate a context
|
||||
///
|
||||
/// \param Context : Context to activate or deactivate
|
||||
/// \param Active : sfTrue to activate, sfFalse to deactivate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfContext_SetActive(sfContext* Context, sfBool Active);
|
||||
|
||||
|
||||
#endif // SFML_CONTEXT_H
|
300
CSFML/include/SFML/Window/Event.h
Normal file
300
CSFML/include/SFML/Window/Event.h
Normal file
@ -0,0 +1,300 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_EVENT_H
|
||||
#define SFML_EVENT_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Definition of key codes for keyboard events
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfKeyA = 'a',
|
||||
sfKeyB = 'b',
|
||||
sfKeyC = 'c',
|
||||
sfKeyD = 'd',
|
||||
sfKeyE = 'e',
|
||||
sfKeyF = 'f',
|
||||
sfKeyG = 'g',
|
||||
sfKeyH = 'h',
|
||||
sfKeyI = 'i',
|
||||
sfKeyJ = 'j',
|
||||
sfKeyK = 'k',
|
||||
sfKeyL = 'l',
|
||||
sfKeyM = 'm',
|
||||
sfKeyN = 'n',
|
||||
sfKeyO = 'o',
|
||||
sfKeyP = 'p',
|
||||
sfKeyQ = 'q',
|
||||
sfKeyR = 'r',
|
||||
sfKeyS = 's',
|
||||
sfKeyT = 't',
|
||||
sfKeyU = 'u',
|
||||
sfKeyV = 'v',
|
||||
sfKeyW = 'w',
|
||||
sfKeyX = 'x',
|
||||
sfKeyY = 'y',
|
||||
sfKeyZ = 'z',
|
||||
sfKeyNum0 = '0',
|
||||
sfKeyNum1 = '1',
|
||||
sfKeyNum2 = '2',
|
||||
sfKeyNum3 = '3',
|
||||
sfKeyNum4 = '4',
|
||||
sfKeyNum5 = '5',
|
||||
sfKeyNum6 = '6',
|
||||
sfKeyNum7 = '7',
|
||||
sfKeyNum8 = '8',
|
||||
sfKeyNum9 = '9',
|
||||
sfKeyEscape = 256,
|
||||
sfKeyLControl,
|
||||
sfKeyLShift,
|
||||
sfKeyLAlt,
|
||||
sfKeyLSystem, ///< OS specific key (left side) : windows (Win and Linux), apple (MacOS), ...
|
||||
sfKeyRControl,
|
||||
sfKeyRShift,
|
||||
sfKeyRAlt,
|
||||
sfKeyRSystem, ///< OS specific key (right side) : windows (Win and Linux), apple (MacOS), ...
|
||||
sfKeyMenu,
|
||||
sfKeyLBracket, ///< [
|
||||
sfKeyRBracket, ///< ]
|
||||
sfKeySemiColon, ///< ;
|
||||
sfKeyComma, ///< ,
|
||||
sfKeyPeriod, ///< .
|
||||
sfKeyQuote, ///< '
|
||||
sfKeySlash, ///< /
|
||||
sfKeyBackSlash,
|
||||
sfKeyTilde, ///< ~
|
||||
sfKeyEqual, ///< =
|
||||
sfKeyDash, ///< -
|
||||
sfKeySpace,
|
||||
sfKeyReturn,
|
||||
sfKeyBack,
|
||||
sfKeyTab,
|
||||
sfKeyPageUp,
|
||||
sfKeyPageDown,
|
||||
sfKeyEnd,
|
||||
sfKeyHome,
|
||||
sfKeyInsert,
|
||||
sfKeyDelete,
|
||||
sfKeyAdd, ///< +
|
||||
sfKeySubtract, ///< -
|
||||
sfKeyMultiply, ///< *
|
||||
sfKeyDivide, ///< /
|
||||
sfKeyLeft, ///< Left arrow
|
||||
sfKeyRight, ///< Right arrow
|
||||
sfKeyUp, ///< Up arrow
|
||||
sfKeyDown, ///< Down arrow
|
||||
sfKeyNumpad0,
|
||||
sfKeyNumpad1,
|
||||
sfKeyNumpad2,
|
||||
sfKeyNumpad3,
|
||||
sfKeyNumpad4,
|
||||
sfKeyNumpad5,
|
||||
sfKeyNumpad6,
|
||||
sfKeyNumpad7,
|
||||
sfKeyNumpad8,
|
||||
sfKeyNumpad9,
|
||||
sfKeyF1,
|
||||
sfKeyF2,
|
||||
sfKeyF3,
|
||||
sfKeyF4,
|
||||
sfKeyF5,
|
||||
sfKeyF6,
|
||||
sfKeyF7,
|
||||
sfKeyF8,
|
||||
sfKeyF9,
|
||||
sfKeyF10,
|
||||
sfKeyF11,
|
||||
sfKeyF12,
|
||||
sfKeyF13,
|
||||
sfKeyF14,
|
||||
sfKeyF15,
|
||||
sfKeyPause,
|
||||
|
||||
sfKeyCount // For internal use
|
||||
} sfKeyCode;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Definition of button codes for mouse events
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfButtonLeft,
|
||||
sfButtonRight,
|
||||
sfButtonMiddle,
|
||||
sfButtonX1,
|
||||
sfButtonX2
|
||||
} sfMouseButton;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Definition of joystick axis for joystick events
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfJoyAxisX,
|
||||
sfJoyAxisY,
|
||||
sfJoyAxisZ,
|
||||
sfJoyAxisR,
|
||||
sfJoyAxisU,
|
||||
sfJoyAxisV,
|
||||
sfJoyAxisPOV
|
||||
} sfJoyAxis;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Definition of all the event types
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef enum
|
||||
{
|
||||
sfEvtClosed,
|
||||
sfEvtResized,
|
||||
sfEvtLostFocus,
|
||||
sfEvtGainedFocus,
|
||||
sfEvtTextEntered,
|
||||
sfEvtKeyPressed,
|
||||
sfEvtKeyReleased,
|
||||
sfEvtMouseWheelMoved,
|
||||
sfEvtMouseButtonPressed,
|
||||
sfEvtMouseButtonReleased,
|
||||
sfEvtMouseMoved,
|
||||
sfEvtMouseEntered,
|
||||
sfEvtMouseLeft,
|
||||
sfEvtJoyButtonPressed,
|
||||
sfEvtJoyButtonReleased,
|
||||
sfEvtJoyMoved
|
||||
} sfEventType;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Keyboard event parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfKeyEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
sfKeyCode Code;
|
||||
sfBool Alt;
|
||||
sfBool Control;
|
||||
sfBool Shift;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Text event parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfTextEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
sfUint32 Unicode;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Mouse move event parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfMouseMoveEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
int X;
|
||||
int Y;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Mouse buttons events parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfMouseButtonEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
sfMouseButton Button;
|
||||
int X;
|
||||
int Y;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Mouse wheel events parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfMouseWheelEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
int Delta;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Joystick axis move event parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfJoyMoveEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
unsigned int JoystickId;
|
||||
sfJoyAxis Axis;
|
||||
float Position;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Joystick buttons events parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfJoyButtonEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
unsigned int JoystickId;
|
||||
unsigned int Button;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Size events parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
struct sfSizeEvent
|
||||
{
|
||||
sfEventType Type;
|
||||
unsigned int Width;
|
||||
unsigned int Height;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfEvent defines a system event and its parameters
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef union
|
||||
{
|
||||
////////////////////////////////////////////////////////////
|
||||
// Member data
|
||||
////////////////////////////////////////////////////////////
|
||||
sfEventType Type; ///< Type of the event
|
||||
struct sfKeyEvent Key;
|
||||
struct sfTextEvent Text;
|
||||
struct sfMouseMoveEvent MouseMove;
|
||||
struct sfMouseButtonEvent MouseButton;
|
||||
struct sfMouseWheelEvent MouseWheel;
|
||||
struct sfJoyMoveEvent JoyMove;
|
||||
struct sfJoyButtonEvent JoyButton;
|
||||
struct sfSizeEvent Size;
|
||||
} sfEvent;
|
||||
|
||||
|
||||
#endif // SFML_EVENT_H
|
110
CSFML/include/SFML/Window/Input.h
Normal file
110
CSFML/include/SFML/Window/Input.h
Normal file
@ -0,0 +1,110 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_INPUT_H
|
||||
#define SFML_INPUT_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Window/Event.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfInput handles real-time input from keyboard and mouse.
|
||||
/// Use it instead of events to handle continuous moves and more
|
||||
/// game-friendly inputs
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfInput sfInput;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the state of a key
|
||||
///
|
||||
/// \param Input : Input object
|
||||
/// \param KeyCode : Key to check
|
||||
///
|
||||
/// \return sfTrue if key is down, sfFalse if key is up
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfInput_IsKeyDown(sfInput* Input, sfKeyCode KeyCode);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the state of a mouse button
|
||||
///
|
||||
/// \param Input : Input object
|
||||
/// \param Button : Button to check
|
||||
///
|
||||
/// \return sfTrue if button is down, sfFalse if button is up
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfInput_IsMouseButtonDown(sfInput* Input, sfMouseButton Button);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the state of a joystick button
|
||||
///
|
||||
/// \param Input : Input object
|
||||
/// \param JoyId : Identifier of the joystick to check (0 or 1)
|
||||
/// \param Button : Button to check
|
||||
///
|
||||
/// \return sfTrue if button is down, sfFalse if button is up
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfInput_IsJoystickButtonDown(sfInput* Input, unsigned int JoyId, unsigned int Button);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the mouse X position
|
||||
///
|
||||
/// \param Input : Input object
|
||||
///
|
||||
/// \return Current mouse left position, relative to owner window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API int sfInput_GetMouseX(sfInput* Input);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the mouse Y position
|
||||
///
|
||||
/// \param Input : Input object
|
||||
///
|
||||
/// \return Current mouse top position, relative to owner window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API int sfInput_GetMouseY(sfInput* Input);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the joystick position on a given axis
|
||||
///
|
||||
/// \param Input : Input object
|
||||
/// \param JoyId : Identifier of the joystick to check (0 or 1)
|
||||
/// \param Axis : Identifier of the axis to read
|
||||
///
|
||||
/// \return Current joystick position, in the range [-100, 100]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfInput_GetJoystickAxis(sfInput* Input, unsigned int JoyId, sfJoyAxis Axis);
|
||||
|
||||
|
||||
#endif // SFML_INPUT_H
|
87
CSFML/include/SFML/Window/VideoMode.h
Normal file
87
CSFML/include/SFML/Window/VideoMode.h
Normal file
@ -0,0 +1,87 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_VIDEOMODE_H
|
||||
#define SFML_VIDEOMODE_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfVideoMode defines a video mode (width, height, bpp, frequency)
|
||||
/// and provides functions for getting modes supported
|
||||
/// by the display device
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
unsigned int Width; ///< Video mode width, in pixels
|
||||
unsigned int Height; ///< Video mode height, in pixels
|
||||
unsigned int BitsPerPixel; ///< Video mode pixel depth, in bits per pixels
|
||||
} sfVideoMode;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current desktop video mode
|
||||
///
|
||||
/// \return Current desktop video mode
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfVideoMode sfVideoMode_GetDesktopMode();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a valid video mode
|
||||
/// Index must be in range [0, GetModesCount()[
|
||||
/// Modes are sorted from best to worst
|
||||
///
|
||||
/// \param Index : Index of video mode to get
|
||||
///
|
||||
/// \return Corresponding video mode (invalid mode if index is out of range)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfVideoMode sfVideoMode_GetMode(size_t Index);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get valid video modes count
|
||||
///
|
||||
/// \return Number of valid video modes available
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API size_t sfVideoMode_GetModesCount();
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a video mode is supported
|
||||
///
|
||||
/// \param Mode : Video mode to check
|
||||
///
|
||||
///
|
||||
/// \return True if video mode is supported, false otherwise
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfVideoMode_IsValid(sfVideoMode Mode);
|
||||
|
||||
|
||||
#endif // SFML_VIDEOMODE_H
|
294
CSFML/include/SFML/Window/Window.h
Normal file
294
CSFML/include/SFML/Window/Window.h
Normal file
@ -0,0 +1,294 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_WINDOW_H
|
||||
#define SFML_WINDOW_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
#include <SFML/Window/Event.h>
|
||||
#include <SFML/Window/Input.h>
|
||||
#include <SFML/Window/VideoMode.h>
|
||||
#include <SFML/Window/WindowHandle.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// sfWindow is a rendering window ; it can create a new window
|
||||
/// or connect to an existing one
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct sfWindow sfWindow;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enumeration of window creation styles
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
enum
|
||||
{
|
||||
sfNone = 0, ///< No border / title bar (this flag and all others are mutually exclusive)
|
||||
sfTitlebar = 1 << 0, ///< Title bar + fixed border
|
||||
sfResize = 1 << 1, ///< Titlebar + resizable border + maximize button
|
||||
sfClose = 1 << 2, ///< Titlebar + close button
|
||||
sfFullscreen = 1 << 3 ///< Fullscreen mode (this flag and all others are mutually exclusive)
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Structure defining the window's creation settings
|
||||
////////////////////////////////////////////////////////////
|
||||
typedef struct
|
||||
{
|
||||
unsigned int DepthBits; ///< Bits of the depth buffer
|
||||
unsigned int StencilBits; ///< Bits of the stencil buffer
|
||||
unsigned int AntialiasingLevel; ///< Level of antialiasing
|
||||
} sfWindowSettings;
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new window
|
||||
///
|
||||
/// \param Mode : Video mode to use
|
||||
/// \param Title : Title of the window
|
||||
/// \param Style : Window style
|
||||
/// \param Params : Creation settings
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfWindow* sfWindow_Create(sfVideoMode Mode, const char* Title, unsigned long Style, sfWindowSettings Params);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a window from an existing control
|
||||
///
|
||||
/// \param Handle : Platform-specific handle of the control
|
||||
/// \param Params : Creation settings
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfWindow* sfWindow_CreateFromHandle(sfWindowHandle Handle, sfWindowSettings Params);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing window
|
||||
///
|
||||
/// \param Window : Window to destroy
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_Destroy(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Close a window (but doesn't destroy the internal data)
|
||||
///
|
||||
/// \param Window : Window to close
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_Close(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a window is opened
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfWindow_IsOpened(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the width of the rendering region of a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
/// \return Width in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfWindow_GetWidth(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the height of the rendering region of a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
/// \return Height in pixels
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API unsigned int sfWindow_GetHeight(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the creation settings of a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
/// \return Settings used to create the window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfWindowSettings sfWindow_GetSettings(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the event on top of events stack of a window, if any, and pop it
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Event : Event to fill, if any
|
||||
///
|
||||
/// \return sfTrue if an event was returned, sfFalse if events stack was empty
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfWindow_GetEvent(sfWindow* Window, sfEvent* Event);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable / disable vertical synchronization on a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Enabled : sfTrue to enable v-sync, sfFalse to deactivate
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_UseVerticalSync(sfWindow* Window, sfBool Enabled);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Show or hide the mouse cursor on a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Show : sfTrue to show, sfFalse to hide
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_ShowMouseCursor(sfWindow* Window, sfBool Show);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the position of the mouse cursor on a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Left : Left coordinate of the cursor, relative to the window
|
||||
/// \param Top : Top coordinate of the cursor, relative to the window
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_SetCursorPosition(sfWindow* Window, unsigned int Left, unsigned int Top);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the position of a window on screen.
|
||||
/// Only works for top-level windows
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Left : Left position
|
||||
/// \param Top : Top position
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_SetPosition(sfWindow* Window, int Left, int Top);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the size of the rendering region of a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Width : New Width
|
||||
/// \param Height : New Height
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_SetSize(sfWindow* Window, unsigned int Width, unsigned int Height);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Show or hide a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param State : sfTrue to show, sfFalse to hide
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_Show(sfWindow* Window, sfBool State);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable or disable automatic key-repeat for keydown events.
|
||||
/// Automatic key-repeat is enabled by default
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Enabled : sfTrue to enable, sfFalse to disable
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_EnableKeyRepeat(sfWindow* Window, sfBool Enabled);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the window's icon
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Width : Icon's width, in pixels
|
||||
/// \param Height : Icon's height, in pixels
|
||||
/// \param Pixels : Pointer to the pixels in memory, format must be RGBA 32 bits
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_SetIcon(sfWindow* Window, unsigned int Width, unsigned int Height, sfUint8* Pixels);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Activate or deactivate a window as the current target for rendering
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Active : sfTrue to activate, sfFalse to deactivate
|
||||
///
|
||||
/// \return True if operation was successful, false otherwise
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfWindow_SetActive(sfWindow* Window, sfBool Active);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Display a window on screen
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_Display(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the input manager of a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
/// \return Reference to the input
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfInput* sfWindow_GetInput(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Limit the framerate to a maximum fixed frequency for a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
/// \param Limit : Framerate limit, in frames per seconds (use 0 to disable limit)
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_SetFramerateLimit(sfWindow* Window, unsigned int Limit);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get time elapsed since last frame of a window
|
||||
///
|
||||
/// \param Window : Window object
|
||||
///
|
||||
/// \return Time elapsed, in seconds
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API float sfWindow_GetFrameTime(sfWindow* Window);
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the joystick threshold, ie. the value below which
|
||||
/// no move event will be generated
|
||||
///
|
||||
/// \param Window : Window object
|
||||
/// \param Threshold : New threshold, in range [0, 100]
|
||||
///
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API void sfWindow_SetJoystickThreshold(sfWindow* Window, float Threshold);
|
||||
|
||||
|
||||
#endif // SFML_WINDOW_H
|
56
CSFML/include/SFML/Window/WindowHandle.h
Normal file
56
CSFML/include/SFML/Window/WindowHandle.h
Normal file
@ -0,0 +1,56 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef SFML_WINDOWHANDLE_H
|
||||
#define SFML_WINDOWHANDLE_H
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Config.h>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Define a low-level window handle type, specific to
|
||||
/// each platform
|
||||
////////////////////////////////////////////////////////////
|
||||
#if defined(CSFML_SYSTEM_WINDOWS)
|
||||
|
||||
// Windows defines a void* handle (HWND)
|
||||
typedef void* sfWindowHandle;
|
||||
|
||||
#elif defined(CSFML_SYSTEM_LINUX)
|
||||
|
||||
// Unix - X11 defines an unsigned integer handle (Window)
|
||||
typedef unsigned long sfWindowHandle;
|
||||
|
||||
#elif defined(CSFML_SYSTEM_MACOS)
|
||||
|
||||
// Mac OS X defines a void* handle (NSWindow)
|
||||
typedef void * sfWindowHandle;
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
#endif // SFML_WINDOWHANDLE_H
|
98
CSFML/src/SFML/Audio/Listener.cpp
Normal file
98
CSFML/src/SFML/Audio/Listener.cpp
Normal file
@ -0,0 +1,98 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/Listener.h>
|
||||
#include <SFML/Audio/Listener.hpp>
|
||||
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the global volume of all the sounds
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfListener_SetGlobalVolume(float Volume)
|
||||
{
|
||||
sf::Listener::SetGlobalVolume(Volume);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current value of the global volume of all the sounds
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfListener_GetGlobalVolume()
|
||||
{
|
||||
return sf::Listener::GetGlobalVolume();
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the position of the listener
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfListener_SetPosition(float PosX, float PosY, float PosZ)
|
||||
{
|
||||
sf::Listener::SetPosition(sf::Vector3f(PosX, PosY, PosZ));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current position of the listener
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfListener_GetPosition(float* PosX, float* PosY, float* PosZ)
|
||||
{
|
||||
if (PosX && PosY && PosZ)
|
||||
{
|
||||
sf::Vector3f Position = sf::Listener::GetPosition();
|
||||
*PosX = Position.x;
|
||||
*PosY = Position.y;
|
||||
*PosZ = Position.z;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the orientation of the listener (the point
|
||||
/// he must look at)
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfListener_SetTarget(float TargetX, float TargetY, float TargetZ)
|
||||
{
|
||||
sf::Listener::SetTarget(sf::Vector3f(TargetX, TargetY, TargetZ));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current orientation of the listener (the point
|
||||
/// he's looking at)
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfListener_GetTarget(float* TargetX, float* TargetY, float* TargetZ)
|
||||
{
|
||||
if (TargetX && TargetY && TargetZ)
|
||||
{
|
||||
sf::Vector3f Target = sf::Listener::GetTarget();
|
||||
*TargetX = Target.x;
|
||||
*TargetY = Target.y;
|
||||
*TargetZ = Target.z;
|
||||
}
|
||||
}
|
23
CSFML/src/SFML/Audio/Makefile
Normal file
23
CSFML/src/SFML/Audio/Makefile
Normal file
@ -0,0 +1,23 @@
|
||||
LIB = libcsfml-audio.so
|
||||
SRC = $(wildcard *.cpp)
|
||||
OBJ = $(SRC:.cpp=.o)
|
||||
LIBNAME = $(LIBPATH)/$(LIB).$(VERSION)
|
||||
|
||||
all: $(LIB)
|
||||
|
||||
libcsfml-audio.so: $(OBJ)
|
||||
$(CPP) $(LDFLAGS) -Wl,-soname,$(LIB).$(VERSION) -o $(LIBNAME) $(OBJ) -lsfml-audio
|
||||
|
||||
$(OBJ): %.o: %.cpp
|
||||
$(CPP) -o $@ -c $< $(CFLAGS)
|
||||
|
||||
.PHONY: clean mrproper
|
||||
|
||||
clean:
|
||||
@rm -rf $(OBJ)
|
||||
|
||||
mrproper: clean
|
||||
@rm -rf $(LIBNAME)
|
||||
|
||||
install:
|
||||
@($(CP) $(LIBNAME) $(DESTLIBDIR) && $(LN) $(LNFLAGS) $(DESTLIBDIR)/$(LIB).$(VERSION) $(DESTLIBDIR)/$(LIB))
|
273
CSFML/src/SFML/Audio/Music.cpp
Normal file
273
CSFML/src/SFML/Audio/Music.cpp
Normal file
@ -0,0 +1,273 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/Music.h>
|
||||
#include <SFML/Audio/Music.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
struct sfMusic
|
||||
{
|
||||
sf::Music This;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new music and load it from a file
|
||||
////////////////////////////////////////////////////////////
|
||||
sfMusic* sfMusic_CreateFromFile(const char* Filename)
|
||||
{
|
||||
sfMusic* Music = new sfMusic;
|
||||
|
||||
if (!Music->This.OpenFromFile(Filename))
|
||||
{
|
||||
delete Music;
|
||||
Music = NULL;
|
||||
}
|
||||
|
||||
return Music;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new music and load it from a file in memory
|
||||
////////////////////////////////////////////////////////////
|
||||
sfMusic* sfMusic_CreateFromMemory(const char* Data, size_t SizeInBytes)
|
||||
{
|
||||
sfMusic* Music = new sfMusic;
|
||||
|
||||
if (!Music->This.OpenFromMemory(Data, SizeInBytes))
|
||||
{
|
||||
delete Music;
|
||||
Music = NULL;
|
||||
}
|
||||
|
||||
return Music;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_Destroy(sfMusic* Music)
|
||||
{
|
||||
delete Music;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a music loop state
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_SetLoop(sfMusic* Music, sfBool Loop)
|
||||
{
|
||||
CSFML_CALL(Music, SetLoop(Loop != 0));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a music is looping
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfMusic_GetLoop(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetLoop(), sfFalse);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a music duration
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfMusic_GetDuration(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetDuration(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start playing a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_Play(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL(Music, Play());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Pause a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_Pause(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL(Music, Pause());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop playing a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_Stop(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL(Music, Stop());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of channels of a music (1 = mono, 2 = stereo)
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfMusic_GetChannelsCount(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetChannelsCount(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the stream sample rate of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfMusic_GetSampleRate(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetSampleRate(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a music (stopped, paused, playing)
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundStatus sfMusic_GetStatus(sfMusic* Music)
|
||||
{
|
||||
CSFML_CHECK_RETURN(Music, sfStopped);
|
||||
|
||||
return static_cast<sfSoundStatus>(Music->This.GetStatus());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current playing position of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfMusic_GetPlayingOffset(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetPlayingOffset(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the pitch of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_SetPitch(sfMusic* Music, float Pitch)
|
||||
{
|
||||
CSFML_CALL(Music, SetPitch(Pitch));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the volume of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_SetVolume(sfMusic* Music, float Volume)
|
||||
{
|
||||
CSFML_CALL(Music, SetVolume(Volume));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_SetPosition(sfMusic* Music, float X, float Y, float Z)
|
||||
{
|
||||
CSFML_CALL(Music, SetPosition(sf::Vector3f(X, Y, Z)));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the minimum distance - closer than this distance,
|
||||
/// the listener will hear the music at its maximum volume.
|
||||
/// The default minimum distance is 1.0
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_SetMinDistance(sfMusic* Music, float MinDistance)
|
||||
{
|
||||
CSFML_CALL(Music, SetMinDistance(MinDistance));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the attenuation factor - the higher the attenuation, the
|
||||
/// more the sound will be attenuated with distance from listener.
|
||||
/// The default attenuation factor 1.0
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_SetAttenuation(sfMusic* Music, float Attenuation)
|
||||
{
|
||||
CSFML_CALL(Music, SetAttenuation(Attenuation));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the pitch of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfMusic_GetPitch(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetPitch(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the volume of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfMusic_GetVolume(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetVolume(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the position of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfMusic_GetPosition(sfMusic* Music, float* X, float* Y, float* Z)
|
||||
{
|
||||
CSFML_CHECK(Music);
|
||||
|
||||
if (X && Y && Z)
|
||||
{
|
||||
sf::Vector3f Position = Music->This.GetPosition();
|
||||
*X = Position.x;
|
||||
*Y = Position.y;
|
||||
*Z = Position.z;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minimum distance of a music
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfMusic_GetMinDistance(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetMinDistance(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the attenuation factor of a a
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfMusic_GetAttenuation(sfMusic* Music)
|
||||
{
|
||||
CSFML_CALL_RETURN(Music, GetAttenuation(), 0.f);
|
||||
}
|
258
CSFML/src/SFML/Audio/Sound.cpp
Normal file
258
CSFML/src/SFML/Audio/Sound.cpp
Normal file
@ -0,0 +1,258 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/Sound.h>
|
||||
#include <SFML/Audio/Sound.hpp>
|
||||
#include <SFML/Audio/SoundBuffer.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
// WARNING : this structure must always be the SAME as in Audio/SoundBuffer.h
|
||||
struct sfSoundBuffer
|
||||
{
|
||||
sf::SoundBuffer This;
|
||||
};
|
||||
struct sfSound
|
||||
{
|
||||
sf::Sound This;
|
||||
sfSoundBuffer* Buffer;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSound* sfSound_Create()
|
||||
{
|
||||
return new sfSound;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_Destroy(sfSound* Sound)
|
||||
{
|
||||
delete Sound;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start playing a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_Play(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL(Sound, Play())
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Pause a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_Pause(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL(Sound, Pause())
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop playing a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_Stop(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL(Sound, Stop())
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Bind a sound buffer to a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetBuffer(sfSound* Sound, sfSoundBuffer* Buffer)
|
||||
{
|
||||
if (Buffer)
|
||||
{
|
||||
CSFML_CALL(Sound, SetBuffer(Buffer->This))
|
||||
Sound->Buffer = Buffer;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sound buffer bound to a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundBuffer* sfSound_GetBuffer(sfSound* Sound)
|
||||
{
|
||||
CSFML_CHECK_RETURN(Sound, NULL)
|
||||
|
||||
return Sound->Buffer;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a sound loop state
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetLoop(sfSound* Sound, sfBool Loop)
|
||||
{
|
||||
CSFML_CALL(Sound, SetLoop(Loop == sfTrue))
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a sound is looping
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfSound_GetLoop(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL_RETURN(Sound, GetLoop(), sfFalse)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a sound (stopped, paused, playing)
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundStatus sfSound_GetStatus(sfSound* Sound)
|
||||
{
|
||||
CSFML_CHECK_RETURN(Sound, sfStopped);
|
||||
|
||||
return static_cast<sfSoundStatus>(Sound->This.GetStatus());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the pitch of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetPitch(sfSound* Sound, float Pitch)
|
||||
{
|
||||
CSFML_CALL(Sound, SetPitch(Pitch))
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the volume of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetVolume(sfSound* Sound, float Volume)
|
||||
{
|
||||
CSFML_CALL(Sound, SetVolume(Volume))
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetPosition(sfSound* Sound, float X, float Y, float Z)
|
||||
{
|
||||
CSFML_CALL(Sound, SetPosition(sf::Vector3f(X, Y, Z)))
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the minimum distance - closer than this distance,
|
||||
/// the listener will hear the sound at its maximum volume.
|
||||
/// The default minimum distance is 1.0
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetMinDistance(sfSound* Sound, float MinDistance)
|
||||
{
|
||||
CSFML_CALL(Sound, SetMinDistance(MinDistance));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the attenuation factor - the higher the attenuation, the
|
||||
/// more the sound will be attenuated with distance from listener.
|
||||
/// The default attenuation factor is 1.0
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetAttenuation(sfSound* Sound, float Attenuation)
|
||||
{
|
||||
CSFML_CALL(Sound, SetAttenuation(Attenuation));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the current playing position of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_SetPlayingOffset(sfSound* Sound, float TimeOffset)
|
||||
{
|
||||
CSFML_CALL(Sound, SetPlayingOffset(TimeOffset));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the pitch of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSound_GetPitch(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL_RETURN(Sound, GetPitch(), 0.f)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the volume of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSound_GetVolume(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL_RETURN(Sound, GetVolume(), 0.f)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the position of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSound_GetPosition(sfSound* Sound, float* X, float* Y, float* Z)
|
||||
{
|
||||
CSFML_CHECK(Sound);
|
||||
|
||||
sf::Vector3f Position = Sound->This.GetPosition();
|
||||
if (X) *X = Position.x;
|
||||
if (Y) *Y = Position.y;
|
||||
if (Z) *Z = Position.z;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minimum distance of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSound_GetMinDistance(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL_RETURN(Sound, GetMinDistance(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the attenuation factor of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSound_GetAttenuation(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL_RETURN(Sound, GetAttenuation(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current playing position of a sound
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSound_GetPlayingOffset(sfSound* Sound)
|
||||
{
|
||||
CSFML_CALL_RETURN(Sound, GetPlayingOffset(), 0.f)
|
||||
}
|
152
CSFML/src/SFML/Audio/SoundBuffer.cpp
Normal file
152
CSFML/src/SFML/Audio/SoundBuffer.cpp
Normal file
@ -0,0 +1,152 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/SoundBuffer.h>
|
||||
#include <SFML/Audio/SoundBuffer.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
struct sfSoundBuffer
|
||||
{
|
||||
sf::SoundBuffer This;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sound buffer and load it from a file
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundBuffer* sfSoundBuffer_CreateFromFile(const char* Filename)
|
||||
{
|
||||
sfSoundBuffer* Buffer = new sfSoundBuffer;
|
||||
|
||||
if (!Buffer->This.LoadFromFile(Filename))
|
||||
{
|
||||
delete Buffer;
|
||||
Buffer = NULL;
|
||||
}
|
||||
|
||||
return Buffer;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sound buffer and load it from a file in memory
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundBuffer* sfSoundBuffer_CreateFromMemory(const char* Data, size_t SizeInBytes)
|
||||
{
|
||||
sfSoundBuffer* Buffer = new sfSoundBuffer;
|
||||
|
||||
if (!Buffer->This.LoadFromMemory(Data, SizeInBytes))
|
||||
{
|
||||
delete Buffer;
|
||||
Buffer = NULL;
|
||||
}
|
||||
|
||||
return Buffer;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new sound buffer and load it from an array of
|
||||
/// samples in memory - assumed format for samples is
|
||||
/// 16 bits signed integer
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundBuffer* sfSoundBuffer_CreateFromSamples(const sfInt16* Samples, size_t SamplesCount, unsigned int ChannelsCount, unsigned int SampleRate)
|
||||
{
|
||||
sfSoundBuffer* Buffer = new sfSoundBuffer;
|
||||
|
||||
if (!Buffer->This.LoadFromSamples(Samples, SamplesCount, ChannelsCount, SampleRate))
|
||||
{
|
||||
delete Buffer;
|
||||
Buffer = NULL;
|
||||
}
|
||||
|
||||
return Buffer;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound buffer
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundBuffer_Destroy(sfSoundBuffer* SoundBuffer)
|
||||
{
|
||||
delete SoundBuffer;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Save a sound buffer to a file
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfSoundBuffer_SaveToFile(sfSoundBuffer* SoundBuffer, const char* Filename)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBuffer, SaveToFile(Filename), sfFalse)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the samples contained in a sound buffer
|
||||
////////////////////////////////////////////////////////////
|
||||
const sfInt16* sfSoundBuffer_GetSamples(sfSoundBuffer* SoundBuffer)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBuffer, GetSamples(), NULL)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of samples contained in a sound buffer
|
||||
////////////////////////////////////////////////////////////
|
||||
size_t sfSoundBuffer_GetSamplesCount(sfSoundBuffer* SoundBuffer)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBuffer, GetSamplesCount(), 0)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound buffer
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfSoundBuffer_GetSampleRate(sfSoundBuffer* SoundBuffer)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBuffer, GetSampleRate(), 0)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of channels of a sound buffer (1 = mono, 2 = stereo, ...)
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfSoundBuffer_GetChannelsCount(sfSoundBuffer* SoundBuffer)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBuffer, GetChannelsCount(), 0)
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the duration of a sound buffer
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSoundBuffer_GetDuration(sfSoundBuffer* SoundBuffer)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBuffer, GetDuration(), 0.f)
|
||||
}
|
104
CSFML/src/SFML/Audio/SoundBufferRecorder.cpp
Normal file
104
CSFML/src/SFML/Audio/SoundBufferRecorder.cpp
Normal file
@ -0,0 +1,104 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/SoundBufferRecorder.h>
|
||||
#include <SFML/Audio/SoundBufferRecorder.hpp>
|
||||
#include <SFML/Audio/SoundBuffer.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
// WARNING : this structure must always be the SAME as in Audio/SoundBuffer.h
|
||||
struct sfSoundBuffer
|
||||
{
|
||||
sf::SoundBuffer This;
|
||||
};
|
||||
|
||||
struct sfSoundBufferRecorder
|
||||
{
|
||||
sf::SoundBufferRecorder This;
|
||||
sfSoundBuffer SoundBuffer;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound buffer recorder
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundBufferRecorder* sfSoundBufferRecorder_Create()
|
||||
{
|
||||
return new sfSoundBufferRecorder;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound buffer recorder
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundBufferRecorder_Destroy(sfSoundBufferRecorder* SoundBufferRecorder)
|
||||
{
|
||||
delete SoundBufferRecorder;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start the capture.
|
||||
/// Warning : only one capture can happen at the same time
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundBufferRecorder_Start(sfSoundBufferRecorder* SoundBufferRecorder, unsigned int SampleRate)
|
||||
{
|
||||
CSFML_CALL(SoundBufferRecorder, Start(SampleRate));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop the capture
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundBufferRecorder_Stop(sfSoundBufferRecorder* SoundBufferRecorder)
|
||||
{
|
||||
CSFML_CALL(SoundBufferRecorder, Stop());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound buffer recorder
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfSoundBufferRecorder_GetSampleRate(sfSoundBufferRecorder* SoundBufferRecorder)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundBufferRecorder, GetSampleRate(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sound buffer containing the captured audio data
|
||||
/// of a sound buffer recorder
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundBuffer* sfSoundBufferRecorder_GetBuffer(sfSoundBufferRecorder* SoundBufferRecorder)
|
||||
{
|
||||
CSFML_CHECK_RETURN(SoundBufferRecorder, NULL);
|
||||
|
||||
SoundBufferRecorder->SoundBuffer.This = SoundBufferRecorder->This.GetBuffer();
|
||||
|
||||
return &SoundBufferRecorder->SoundBuffer;
|
||||
}
|
150
CSFML/src/SFML/Audio/SoundRecorder.cpp
Normal file
150
CSFML/src/SFML/Audio/SoundRecorder.cpp
Normal file
@ -0,0 +1,150 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/SoundRecorder.h>
|
||||
#include <SFML/Audio/SoundRecorder.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
class sfSoundRecorderImpl : public sf::SoundRecorder
|
||||
{
|
||||
public :
|
||||
|
||||
sfSoundRecorderImpl(sfSoundRecorderStartCallback OnStart,
|
||||
sfSoundRecorderProcessCallback OnProcess,
|
||||
sfSoundRecorderStopCallback OnStop,
|
||||
void* UserData) :
|
||||
myStartCallback (OnStart),
|
||||
myProcessCallback(OnProcess),
|
||||
myStopCallback (OnStop),
|
||||
myUserData (UserData)
|
||||
{
|
||||
}
|
||||
|
||||
private :
|
||||
|
||||
virtual bool OnStart()
|
||||
{
|
||||
if (myStartCallback)
|
||||
return myStartCallback(myUserData) == sfTrue;
|
||||
else
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual bool OnProcessSamples(const sf::Int16* Samples, std::size_t SamplesCount)
|
||||
{
|
||||
if (myProcessCallback)
|
||||
return myProcessCallback(Samples, SamplesCount, myUserData) == sfTrue;
|
||||
else
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual void OnStop()
|
||||
{
|
||||
if (myStopCallback)
|
||||
myStopCallback(myUserData);
|
||||
}
|
||||
|
||||
sfSoundRecorderStartCallback myStartCallback;
|
||||
sfSoundRecorderProcessCallback myProcessCallback;
|
||||
sfSoundRecorderStopCallback myStopCallback;
|
||||
void* myUserData;
|
||||
};
|
||||
|
||||
|
||||
struct sfSoundRecorder
|
||||
{
|
||||
sfSoundRecorder(sfSoundRecorderStartCallback OnStart,
|
||||
sfSoundRecorderProcessCallback OnProcess,
|
||||
sfSoundRecorderStopCallback OnStop,
|
||||
void* UserData) :
|
||||
This(OnStart, OnProcess, OnStop, UserData)
|
||||
{
|
||||
}
|
||||
|
||||
sfSoundRecorderImpl This;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound recorder with callback functions
|
||||
/// for processing captured samples
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundRecorder* sfSoundRecorder_Create(sfSoundRecorderStartCallback OnStart,
|
||||
sfSoundRecorderProcessCallback OnProcess,
|
||||
sfSoundRecorderStopCallback OnStop,
|
||||
void* UserData)
|
||||
{
|
||||
return new sfSoundRecorder(OnStart, OnProcess, OnStop, UserData);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound recorder
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundRecorder_Destroy(sfSoundRecorder* SoundRecorder)
|
||||
{
|
||||
delete SoundRecorder;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start the capture.
|
||||
/// Warning : only one capture can happen at the same time
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundRecorder_Start(sfSoundRecorder* SoundRecorder, unsigned int SampleRate)
|
||||
{
|
||||
CSFML_CALL(SoundRecorder, Start(SampleRate));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop the capture
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundRecorder_Stop(sfSoundRecorder* SoundRecorder)
|
||||
{
|
||||
CSFML_CALL(SoundRecorder, Stop());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound recorder
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfSoundRecorder_GetSampleRate(sfSoundRecorder* SoundRecorder)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundRecorder, GetSampleRate(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell if the system supports sound capture.
|
||||
/// If not, this class won't be usable
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfSoundRecorder_CanCapture()
|
||||
{
|
||||
return sf::SoundRecorder::CanCapture() ? sfTrue : sfFalse;
|
||||
}
|
294
CSFML/src/SFML/Audio/SoundStream.cpp
Normal file
294
CSFML/src/SFML/Audio/SoundStream.cpp
Normal file
@ -0,0 +1,294 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Audio/SoundStream.h>
|
||||
#include <SFML/Audio/SoundStream.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
class sfSoundStreamImpl : public sf::SoundStream
|
||||
{
|
||||
public :
|
||||
|
||||
sfSoundStreamImpl(sfSoundStreamStartCallback OnStart,
|
||||
sfSoundStreamGetDataCallback OnGetData,
|
||||
unsigned int ChannelsCount,
|
||||
unsigned int SampleRate,
|
||||
void* UserData) :
|
||||
myStartCallback (OnStart),
|
||||
myGetDataCallback(OnGetData),
|
||||
myUserData (UserData)
|
||||
{
|
||||
Initialize(ChannelsCount, SampleRate);
|
||||
}
|
||||
|
||||
private :
|
||||
|
||||
virtual bool OnStart()
|
||||
{
|
||||
if (myStartCallback)
|
||||
return myStartCallback(myUserData) == sfTrue;
|
||||
else
|
||||
return true;
|
||||
}
|
||||
|
||||
virtual bool OnGetData(Chunk& Data)
|
||||
{
|
||||
sfSoundStreamChunk Chunk = {NULL, 0};
|
||||
bool Continue = (myGetDataCallback(&Chunk, myUserData) == sfTrue);
|
||||
|
||||
Data.Samples = Chunk.Samples;
|
||||
Data.NbSamples = Chunk.NbSamples;
|
||||
|
||||
return Continue;
|
||||
}
|
||||
|
||||
sfSoundStreamStartCallback myStartCallback;
|
||||
sfSoundStreamGetDataCallback myGetDataCallback;
|
||||
void* myUserData;
|
||||
};
|
||||
|
||||
|
||||
struct sfSoundStream
|
||||
{
|
||||
|
||||
sfSoundStream(sfSoundStreamStartCallback OnStart,
|
||||
sfSoundStreamGetDataCallback OnGetData,
|
||||
unsigned int ChannelsCount,
|
||||
unsigned int SampleRate,
|
||||
void* UserData) :
|
||||
This(OnStart, OnGetData, ChannelsCount, SampleRate, UserData)
|
||||
{
|
||||
}
|
||||
|
||||
sfSoundStreamImpl This;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a new sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundStream* sfSoundStream_Create(sfSoundStreamStartCallback OnStart,
|
||||
sfSoundStreamGetDataCallback OnGetData,
|
||||
unsigned int ChannelsCount,
|
||||
unsigned int SampleRate,
|
||||
void* UserData)
|
||||
{
|
||||
return new sfSoundStream(OnStart, OnGetData, ChannelsCount, SampleRate, UserData);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_Destroy(sfSoundStream* SoundStream)
|
||||
{
|
||||
delete SoundStream;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Start playing a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_Play(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL(SoundStream, Play());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Pause a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_Pause(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL(SoundStream, Pause());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Stop playing a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_Stop(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL(SoundStream, Stop());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the status of a sound stream (stopped, paused, playing)
|
||||
////////////////////////////////////////////////////////////
|
||||
sfSoundStatus sfSoundStream_GetStatus(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CHECK_RETURN(SoundStream, sfStopped);
|
||||
|
||||
return static_cast<sfSoundStatus>(SoundStream->This.GetStatus());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the number of channels of a sound stream
|
||||
/// (1 = mono, 2 = stereo)
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfSoundStream_GetChannelsCount(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetChannelsCount(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the sample rate of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfSoundStream_GetSampleRate(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetSampleRate(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the pitch of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_SetPitch(sfSoundStream* SoundStream, float Pitch)
|
||||
{
|
||||
CSFML_CALL(SoundStream, SetPitch(Pitch));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the volume of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_SetVolume(sfSoundStream* SoundStream, float Volume)
|
||||
{
|
||||
CSFML_CALL(SoundStream, SetVolume(Volume));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the position of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_SetPosition(sfSoundStream* SoundStream, float X, float Y, float Z)
|
||||
{
|
||||
CSFML_CALL(SoundStream, SetPosition(X, Y, Z));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the minimum distance - closer than this distance,
|
||||
/// the listener will hear the sound stream at its maximum volume.
|
||||
/// The default minimum distance is 1.0
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_SetMinDistance(sfSoundStream* SoundStream, float MinDistance)
|
||||
{
|
||||
CSFML_CALL(SoundStream, SetMinDistance(MinDistance));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set the attenuation factor - the higher the attenuation, the
|
||||
/// more the sound stream will be attenuated with distance from listener.
|
||||
/// The default attenuation factor 1.0
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_SetAttenuation(sfSoundStream* SoundStream, float Attenuation)
|
||||
{
|
||||
CSFML_CALL(SoundStream, SetAttenuation(Attenuation));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Set a stream loop state
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_SetLoop(sfSoundStream* SoundStream, sfBool Loop)
|
||||
{
|
||||
CSFML_CALL(SoundStream, SetLoop(Loop == sfTrue));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the pitch of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSoundStream_GetPitch(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetPitch(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the volume of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSoundStream_GetVolume(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetVolume(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the position of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfSoundStream_GetPosition(sfSoundStream* SoundStream, float* X, float* Y, float* Z)
|
||||
{
|
||||
CSFML_CHECK(SoundStream);
|
||||
|
||||
sf::Vector3f Position = SoundStream->This.GetPosition();
|
||||
if (X) *X = Position.x;
|
||||
if (Y) *Y = Position.y;
|
||||
if (Z) *Z = Position.z;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the minimum distance of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSoundStream_GetMinDistance(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetMinDistance(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the attenuation factor of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSoundStream_GetAttenuation(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetAttenuation(), 0.f);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tell whether or not a stream is looping
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfSoundStream_GetLoop(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetLoop(), sfFalse);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the current playing position of a sound stream
|
||||
////////////////////////////////////////////////////////////
|
||||
float sfSoundStream_GetPlayingOffset(sfSoundStream* SoundStream)
|
||||
{
|
||||
CSFML_CALL_RETURN(SoundStream, GetPlayingOffset(), 0.f);
|
||||
}
|
96
CSFML/src/SFML/Graphics/Color.cpp
Normal file
96
CSFML/src/SFML/Graphics/Color.cpp
Normal file
@ -0,0 +1,96 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Graphics/Color.h>
|
||||
#include <SFML/Internal.h>
|
||||
#include <algorithm>
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Define some common colors
|
||||
////////////////////////////////////////////////////////////
|
||||
sfColor sfBlack = { 0, 0, 0, 255};
|
||||
sfColor sfWhite = {255, 255, 255, 255};
|
||||
sfColor sfRed = {255, 0, 0, 255};
|
||||
sfColor sfGreen = { 0, 255, 0, 255};
|
||||
sfColor sfBlue = { 0, 0, 255, 255};
|
||||
sfColor sfYellow = {255, 255, 0, 255};
|
||||
sfColor sfMagenta = {255, 0, 255, 255};
|
||||
sfColor sfCyan = { 0, 255, 255, 255};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a color from its 3 RGB components
|
||||
////////////////////////////////////////////////////////////
|
||||
sfColor sfColor_FromRGB(sfUint8 R, sfUint8 G, sfUint8 B)
|
||||
{
|
||||
return sfColor_FromRGBA(R, G, B, 255);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Construct a color from its 4 RGBA components
|
||||
////////////////////////////////////////////////////////////
|
||||
sfColor sfColor_FromRGBA(sfUint8 R, sfUint8 G, sfUint8 B, sfUint8 A)
|
||||
{
|
||||
sfColor Color;
|
||||
|
||||
Color.r = R;
|
||||
Color.g = G;
|
||||
Color.b = B;
|
||||
Color.a = A;
|
||||
|
||||
return Color;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Add two colors
|
||||
////////////////////////////////////////////////////////////
|
||||
sfColor sfColor_Add(sfColor Color1, sfColor Color2)
|
||||
{
|
||||
int R = std::min(Color1.r + Color2.r, 255);
|
||||
int G = std::min(Color1.g + Color2.g, 255);
|
||||
int B = std::min(Color1.b + Color2.b, 255);
|
||||
int A = std::min(Color1.a + Color2.a, 255);
|
||||
|
||||
return sfColor_FromRGBA(static_cast<sfUint8>(R), static_cast<sfUint8>(G), static_cast<sfUint8>(B), static_cast<sfUint8>(A));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Modulate two colors
|
||||
////////////////////////////////////////////////////////////
|
||||
sfColor sfColor_Modulate(sfColor Color1, sfColor Color2)
|
||||
{
|
||||
int R = Color1.r * Color2.r / 255;
|
||||
int G = Color1.g * Color2.g / 255;
|
||||
int B = Color1.b * Color2.b / 255;
|
||||
int A = Color1.a * Color2.a / 255;
|
||||
|
||||
return sfColor_FromRGBA(static_cast<sfUint8>(R), static_cast<sfUint8>(G), static_cast<sfUint8>(B), static_cast<sfUint8>(A));
|
||||
}
|
121
CSFML/src/SFML/Graphics/Font.cpp
Normal file
121
CSFML/src/SFML/Graphics/Font.cpp
Normal file
@ -0,0 +1,121 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Graphics/Font.h>
|
||||
#include <SFML/Graphics/Font.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
struct sfFont
|
||||
{
|
||||
sf::Font This;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new empty font
|
||||
////////////////////////////////////////////////////////////
|
||||
sfFont* sfFont_Create()
|
||||
{
|
||||
return new sfFont;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new font from a file
|
||||
////////////////////////////////////////////////////////////
|
||||
sfFont* sfFont_CreateFromFile(const char* Filename, unsigned int CharSize, const sfUint32* Charset)
|
||||
{
|
||||
sfFont* Font = new sfFont;
|
||||
|
||||
bool bSucceeded = false;
|
||||
if (Charset)
|
||||
bSucceeded = Font->This.LoadFromFile(Filename, CharSize, Charset);
|
||||
else
|
||||
bSucceeded = Font->This.LoadFromFile(Filename, CharSize);
|
||||
|
||||
if (!bSucceeded)
|
||||
{
|
||||
delete Font;
|
||||
Font = NULL;
|
||||
}
|
||||
|
||||
return Font;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new font from a file in memory
|
||||
////////////////////////////////////////////////////////////
|
||||
sfFont* sfFont_CreateFromMemory(const char* Data, size_t SizeInBytes, unsigned int CharSize, const sfUint32* Charset)
|
||||
{
|
||||
sfFont* Font = new sfFont;
|
||||
|
||||
bool bSucceeded = false;
|
||||
if (Charset)
|
||||
bSucceeded = Font->This.LoadFromMemory(Data, SizeInBytes, CharSize, Charset);
|
||||
else
|
||||
bSucceeded = Font->This.LoadFromMemory(Data, SizeInBytes, CharSize);
|
||||
|
||||
if (!bSucceeded)
|
||||
{
|
||||
delete Font;
|
||||
Font = NULL;
|
||||
}
|
||||
|
||||
return Font;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing font
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfFont_Destroy(sfFont* Font)
|
||||
{
|
||||
delete Font;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the base size of characters in a font;
|
||||
/// All glyphs dimensions are based on this value
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfFont_GetCharacterSize(sfFont* Font)
|
||||
{
|
||||
CSFML_CALL_RETURN(Font, GetCharacterSize(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get the built-in default font (Arial)
|
||||
////////////////////////////////////////////////////////////
|
||||
sfFont* sfFont_GetDefaultFont()
|
||||
{
|
||||
static sfFont DefaultFont = {sf::Font::GetDefaultFont()};
|
||||
|
||||
return &DefaultFont;
|
||||
}
|
268
CSFML/src/SFML/Graphics/Image.cpp
Normal file
268
CSFML/src/SFML/Graphics/Image.cpp
Normal file
@ -0,0 +1,268 @@
|
||||
////////////////////////////////////////////////////////////
|
||||
//
|
||||
// SFML - Simple and Fast Multimedia Library
|
||||
// Copyright (C) 2007-2008 Laurent Gomila (laurent.gom@gmail.com)
|
||||
//
|
||||
// This software is provided 'as-is', without any express or implied warranty.
|
||||
// In no event will the authors be held liable for any damages arising from the use of this software.
|
||||
//
|
||||
// Permission is granted to anyone to use this software for any purpose,
|
||||
// including commercial applications, and to alter it and redistribute it freely,
|
||||
// subject to the following restrictions:
|
||||
//
|
||||
// 1. The origin of this software must not be misrepresented;
|
||||
// you must not claim that you wrote the original software.
|
||||
// If you use this software in a product, an acknowledgment
|
||||
// in the product documentation would be appreciated but is not required.
|
||||
//
|
||||
// 2. Altered source versions must be plainly marked as such,
|
||||
// and must not be misrepresented as being the original software.
|
||||
//
|
||||
// 3. This notice may not be removed or altered from any source distribution.
|
||||
//
|
||||
////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
// Headers
|
||||
////////////////////////////////////////////////////////////
|
||||
#include <SFML/Graphics/Image.h>
|
||||
#include <SFML/Graphics/Image.hpp>
|
||||
#include <SFML/Graphics/RenderWindow.hpp>
|
||||
#include <SFML/Window/Input.hpp>
|
||||
#include <SFML/Internal.h>
|
||||
|
||||
|
||||
// WARNING : this structure must always be the SAME as in Window/Input.h
|
||||
struct sfInput
|
||||
{
|
||||
const sf::Input* This;
|
||||
};
|
||||
// WARNING : this structure must always be the SAME as in Graphics/View.h
|
||||
struct sfView
|
||||
{
|
||||
sf::View* This;
|
||||
};
|
||||
// WARNING : this structure must always be the SAME as in Graphics/RenderWindow.h
|
||||
struct sfRenderWindow
|
||||
{
|
||||
sf::RenderWindow This;
|
||||
sfInput Input;
|
||||
sfView DefaultView;
|
||||
sfView* CurrentView;
|
||||
};
|
||||
|
||||
struct sfImage
|
||||
{
|
||||
sf::Image This;
|
||||
};
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new empty image
|
||||
////////////////////////////////////////////////////////////
|
||||
sfImage* sfImage_Create()
|
||||
{
|
||||
return new sfImage;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image filled with a color
|
||||
////////////////////////////////////////////////////////////
|
||||
sfImage* sfImage_CreateFromColor(unsigned int Width, unsigned int Height, sfColor Color)
|
||||
{
|
||||
sfImage* Image = new sfImage;
|
||||
|
||||
if (!Image->This.Create(Width, Height, sf::Color(Color.r, Color.g, Color.b, Color.a)))
|
||||
{
|
||||
delete Image;
|
||||
Image = NULL;
|
||||
}
|
||||
|
||||
return Image;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image from an array of pixels in memory
|
||||
////////////////////////////////////////////////////////////
|
||||
sfImage* sfImage_CreateFromPixels(unsigned int Width, unsigned int Height, const sfUint8* Data)
|
||||
{
|
||||
sfImage* Image = new sfImage;
|
||||
|
||||
if (!Image->This.LoadFromPixels(Width, Height, Data))
|
||||
{
|
||||
delete Image;
|
||||
Image = NULL;
|
||||
}
|
||||
|
||||
return Image;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image from a file
|
||||
////////////////////////////////////////////////////////////
|
||||
sfImage* sfImage_CreateFromFile(const char* Filename)
|
||||
{
|
||||
sfImage* Image = new sfImage;
|
||||
|
||||
if (!Image->This.LoadFromFile(Filename))
|
||||
{
|
||||
delete Image;
|
||||
Image = NULL;
|
||||
}
|
||||
|
||||
return Image;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a new image from a file in memory
|
||||
////////////////////////////////////////////////////////////
|
||||
sfImage* sfImage_CreateFromMemory(const char* Data, size_t SizeInBytes)
|
||||
{
|
||||
sfImage* Image = new sfImage;
|
||||
|
||||
if (!Image->This.LoadFromMemory(Data, SizeInBytes))
|
||||
{
|
||||
delete Image;
|
||||
Image = NULL;
|
||||
}
|
||||
|
||||
return Image;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Destroy an existing image
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfImage_Destroy(sfImage* Image)
|
||||
{
|
||||
delete Image;
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Save the content of an image to a file
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfImage_SaveToFile(sfImage* Image, const char* Filename)
|
||||
{
|
||||
CSFML_CALL_RETURN(Image, SaveToFile(Filename), sfFalse);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create a transparency mask for an image from a specified colorkey
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfImage_CreateMaskFromColor(sfImage* Image, sfColor ColorKey, sfUint8 Alpha)
|
||||
{
|
||||
sf::Color SFMLColor(ColorKey.r, ColorKey.g, ColorKey.b, ColorKey.a);
|
||||
CSFML_CALL(Image, CreateMaskFromColor(SFMLColor, Alpha));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Copy pixels from another image onto this one.
|
||||
/// This function does a slow pixel copy and should only
|
||||
/// be used at initialization time
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfImage_Copy(sfImage* Image, sfImage* Source, unsigned int DestX, unsigned int DestY, sfIntRect SourceRect)
|
||||
{
|
||||
CSFML_CHECK(Source);
|
||||
sf::IntRect SFMLRect(SourceRect.Left, SourceRect.Top, SourceRect.Right, SourceRect.Bottom);
|
||||
CSFML_CALL(Image, Copy(Source->This, DestX, DestY, SFMLRect));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Create the image from the current contents of the
|
||||
/// given window
|
||||
////////////////////////////////////////////////////////////
|
||||
CSFML_API sfBool sfImage_CopyScreen(sfImage* Image, sfRenderWindow* Window, sfIntRect SourceRect)
|
||||
{
|
||||
CSFML_CHECK_RETURN(Window, sfFalse);
|
||||
sf::IntRect SFMLRect(SourceRect.Left, SourceRect.Top, SourceRect.Right, SourceRect.Bottom);
|
||||
CSFML_CALL_RETURN(Image, CopyScreen(Window->This, SFMLRect), sfFalse);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Change the color of a pixel of an image
|
||||
/// Don't forget to call Update when you end modifying pixels
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfImage_SetPixel(sfImage* Image, unsigned int X, unsigned int Y, sfColor Color)
|
||||
{
|
||||
sf::Color SFMLColor(Color.r, Color.g, Color.b, Color.a);
|
||||
CSFML_CALL(Image, SetPixel(X, Y, SFMLColor));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a pixel from an image
|
||||
////////////////////////////////////////////////////////////
|
||||
sfColor sfImage_GetPixel(sfImage* Image, unsigned int X, unsigned int Y)
|
||||
{
|
||||
sfColor Color = {0, 0, 0, 0};
|
||||
CSFML_CHECK_RETURN(Image, Color);
|
||||
|
||||
sf::Color SFMLColor = Image->This.GetPixel(X, Y);
|
||||
|
||||
return sfColor_FromRGBA(SFMLColor.r, SFMLColor.g, SFMLColor.b, SFMLColor.a);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Get a read-only pointer to the array of pixels of an image (8 bits integers RGBA)
|
||||
/// Array size is sfImage_GetWidth() x sfImage_GetHeight() x 4
|
||||
/// This pointer becomes invalid if you reload or resize the image
|
||||
////////////////////////////////////////////////////////////
|
||||
const sfUint8* sfImage_GetPixelsPtr(sfImage* Image)
|
||||
{
|
||||
CSFML_CALL_RETURN(Image, GetPixelsPtr(), NULL);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Bind the image for rendering
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfImage_Bind(sfImage* Image)
|
||||
{
|
||||
CSFML_CALL(Image, Bind());
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Enable or disable image smooth filter
|
||||
////////////////////////////////////////////////////////////
|
||||
void sfImage_SetSmooth(sfImage* Image, sfBool Smooth)
|
||||
{
|
||||
CSFML_CALL(Image, SetSmooth(Smooth == sfTrue));
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the width of the image
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfImage_GetWidth(sfImage* Image)
|
||||
{
|
||||
CSFML_CALL_RETURN(Image, GetWidth(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Return the height of the image
|
||||
////////////////////////////////////////////////////////////
|
||||
unsigned int sfImage_GetHeight(sfImage* Image)
|
||||
{
|
||||
CSFML_CALL_RETURN(Image, GetHeight(), 0);
|
||||
}
|
||||
|
||||
|
||||
////////////////////////////////////////////////////////////
|
||||
/// Tells whether the smoothing filter is enabled or not on an image
|
||||
////////////////////////////////////////////////////////////
|
||||
sfBool sfImage_IsSmooth(sfImage* Image)
|
||||
{
|
||||
CSFML_CALL_RETURN(Image, IsSmooth(), sfFalse);
|
||||
}
|
23
CSFML/src/SFML/Graphics/Makefile
Normal file
23
CSFML/src/SFML/Graphics/Makefile
Normal file
@ -0,0 +1,23 @@
|
||||
LIB = libcsfml-graphics.so
|
||||
SRC = $(wildcard *.cpp)
|
||||
OBJ = $(SRC:.cpp=.o)
|
||||
LIBNAME = $(LIBPATH)/$(LIB).$(VERSION)
|
||||
|
||||
all: $(LIB)
|
||||
|
||||
libcsfml-graphics.so: $(OBJ)
|
||||
$(CPP) $(LDFLAGS) -Wl,-soname,$(LIB).$(VERSION) -o $(LIBNAME) $(OBJ) -lsfml-graphics -lsfml-window -lsfml-system
|
||||
|
||||
$(OBJ): %.o: %.cpp
|
||||
$(CPP) -o $@ -c $< $(CFLAGS)
|
||||
|
||||
.PHONY: clean mrproper
|
||||
|
||||
clean:
|
||||
@rm -rf $(OBJ)
|
||||
|
||||
mrproper: clean
|
||||
@rm -rf $(LIBNAME)
|
||||
|
||||
install:
|
||||
@($(CP) $(LIBNAME) $(DESTLIBDIR) && $(LN) $(LNFLAGS) $(DESTLIBDIR)/$(LIB).$(VERSION) $(DESTLIBDIR)/$(LIB))
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user