Permalink
Browse files

Merge branch 'gl3core' of https://github.com/enigma-dev/enigma-dev in…

…to android
  • Loading branch information...
RobertBColton committed Oct 10, 2018
2 parents 9b004cb + c68058f commit b41438144d270e632e30711c3bf3059ddef2c254
Showing with 6,296 additions and 9,399 deletions.
  1. +1 −0 .gitignore
  2. +67 −62 .travis.yml
  3. +1 −1 CommandLine/emake/OptionsParser.cpp
  4. +2 −2 CommandLine/emake/Proto2ES.cpp
  5. +53 −0 CommandLine/gm2egm/main.cpp
  6. +81 −0 CommandLine/libEGM-test/connected-components-test.cpp
  7. +5 −0 CommandLine/libEGM/Building.md
  8. +49 −0 CommandLine/libEGM/CMakeLists.txt
  9. +22 −2 CommandLine/libEGM/Makefile
  10. +749 −0 CommandLine/libEGM/egm-rooms.cpp
  11. +42 −0 CommandLine/libEGM/egm-rooms.h
  12. +204 −168 CommandLine/libEGM/egm.cpp
  13. +72 −0 CommandLine/libEGM/filesystem.cpp
  14. +26 −0 CommandLine/libEGM/filesystem.h
  15. +26 −15 CommandLine/libEGM/gmk.cpp
  16. +30 −30 CommandLine/protos/{resources → }/Background.proto
  17. +5 −0 CommandLine/protos/Building.md
  18. +78 −0 CommandLine/protos/CMakeLists.txt
  19. 0 CommandLine/protos/{resources → }/Event.proto
  20. +39 −39 CommandLine/protos/{resources → }/Font.proto
  21. +22 −22 CommandLine/protos/{resources → }/GameInformation.proto
  22. +22 −22 CommandLine/protos/{resources → }/Include.proto
  23. +44 −44 CommandLine/protos/{resources → }/Object.proto
  24. +24 −24 CommandLine/protos/{resources → }/Path.proto
  25. +119 −106 CommandLine/protos/{resources → }/Room.proto
  26. +10 −10 CommandLine/protos/{resources → }/Script.proto
  27. +14 −14 CommandLine/protos/{resources → }/Shader.proto
  28. +33 −33 CommandLine/protos/{resources → }/Sound.proto
  29. +40 −40 CommandLine/protos/{resources → }/Sprite.proto
  30. +16 −16 CommandLine/protos/{resources → }/Timeline.proto
  31. +11 −11 CommandLine/protos/treenode.proto
  32. +2 −6 CommandLine/testing/GitHub-ImageDiff.sh
  33. +5 −3 CommandLine/testing/Makefile
  34. +4 −3 CommandLine/testing/TestHarness.hpp
  35. +23 −0 CommandLine/testing/Tests/draw_3d_shapes_test.cpp
  36. +16 −0 CommandLine/testing/Tests/draw_3d_shapes_test.gmx/background/bkg_test.background.gmx
  37. BIN CommandLine/testing/Tests/draw_3d_shapes_test.gmx/background/images/bkg_test.png
  38. +24 −0 CommandLine/testing/Tests/draw_3d_shapes_test.gmx/draw_3d_shapes_test.project.gmx
  39. +89 −0 CommandLine/testing/Tests/draw_3d_shapes_test.gmx/objects/obj_0.object.gmx
  40. +64 −0 CommandLine/testing/Tests/draw_3d_shapes_test.gmx/rooms/rm_0.room.gmx
  41. +59 −0 CommandLine/testing/Tests/draw_3d_shapes_test.gmx/scripts/d3d_draw_shape.gml
  42. +32 −0 CommandLine/testing/Tests/draw_test.sog/draw.edl
  43. +25 −0 CommandLine/testing/Tests/room_transition_test.cpp
  44. +16 −0 CommandLine/testing/Tests/room_transition_test.gmx/background/bkg_0.background.gmx
  45. BIN CommandLine/testing/Tests/room_transition_test.gmx/background/images/bkg_0.png
  46. +59 −0 CommandLine/testing/Tests/room_transition_test.gmx/objects/obj_0.object.gmx
  47. +23 −0 CommandLine/testing/Tests/room_transition_test.gmx/room_transition_test.project.gmx
  48. +64 −0 CommandLine/testing/Tests/room_transition_test.gmx/rooms/rm_0.room.gmx
  49. +83 −0 CommandLine/testing/Tests/room_transition_test.gmx/rooms/rm_1.room.gmx
  50. +0 −29 ENIGMAsystem/SHELL/Bridges/General/DX11Context.h
  51. +11 −60 ENIGMAsystem/SHELL/Bridges/General/DX9Context.h
  52. +3 −66 ENIGMAsystem/SHELL/Bridges/General/GLmanager.h
  53. +91 −66 ENIGMAsystem/SHELL/Bridges/General/Win32-Direct3D11.cpp
  54. +0 −1 ENIGMAsystem/SHELL/Bridges/Win32-Direct3D11/Makefile
  55. +0 −668 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11ModelStruct.h
  56. +2 −1 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11TextureStruct.h
  57. +11 −7 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11colors.cpp
  58. +20 −22 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11d3d.cpp
  59. +20 −16 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11draw.cpp
  60. +0 −163 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11matrix.cpp
  61. +0 −415 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11model.cpp
  62. +0 −169 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11primitives.cpp
  63. +5 −3 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11screen.cpp
  64. +15 −19 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11surface.cpp
  65. +49 −31 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11textures.cpp
  66. +170 −51 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/DX11vertex.cpp
  67. +1 −1 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D11/Makefile
  68. +0 −621 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9ModelStruct.h
  69. +4 −0 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9blend.cpp
  70. +6 −1 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9colors.cpp
  71. +87 −69 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9d3d.cpp
  72. +20 −13 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9draw.cpp
  73. +0 −348 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9matrix.cpp
  74. +0 −414 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9model.cpp
  75. +0 −169 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9primitives.cpp
  76. +7 −3 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9screen.cpp
  77. +25 −28 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9surface.cpp
  78. +20 −7 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9textures.cpp
  79. +26 −31 ENIGMAsystem/SHELL/Graphics_Systems/Direct3D9/DX9vertex.cpp
  80. +5 −0 ENIGMAsystem/SHELL/Graphics_Systems/General/GScolor_macros.h
  81. +1 −1 ENIGMAsystem/SHELL/Graphics_Systems/General/GSd3d.h
  82. +0 −772 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmath.h
  83. +438 −0 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmatrix.cpp
  84. +45 −43 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmatrix.h
  85. +46 −0 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmatrix_impl.h
  86. +694 −15 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmodel.cpp
  87. +54 −26 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmodel.h
  88. +81 −0 ENIGMAsystem/SHELL/Graphics_Systems/General/GSmodel_impl.h
  89. +253 −17 ENIGMAsystem/SHELL/Graphics_Systems/General/GSprimitives.cpp
  90. +10 −1 ENIGMAsystem/SHELL/Graphics_Systems/General/GSprimitives.h
  91. +19 −3 ENIGMAsystem/SHELL/Graphics_Systems/General/GSscreen.cpp
  92. +24 −13 ENIGMAsystem/SHELL/Graphics_Systems/General/GStiles.cpp
  93. +0 −7 ENIGMAsystem/SHELL/Graphics_Systems/General/GStilestruct.h
  94. +131 −42 ENIGMAsystem/SHELL/Graphics_Systems/General/GSvertex.cpp
  95. +22 −12 ENIGMAsystem/SHELL/Graphics_Systems/General/GSvertex.h
  96. +93 −19 ENIGMAsystem/SHELL/Graphics_Systems/General/GSvertex_impl.h
  97. +0 −463 ENIGMAsystem/SHELL/Graphics_Systems/None/NONEModelStruct.h
  98. +2 −0 ENIGMAsystem/SHELL/Graphics_Systems/None/NONEd3d.cpp
  99. +0 −317 ENIGMAsystem/SHELL/Graphics_Systems/None/NONEmatrix.cpp
  100. +0 −411 ENIGMAsystem/SHELL/Graphics_Systems/None/NONEmodel.cpp
  101. +5 −50 ENIGMAsystem/SHELL/Graphics_Systems/None/fillin.cpp
  102. +0 −79 ENIGMAsystem/SHELL/Graphics_Systems/None/fillin.h
  103. +0 −876 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLModelStruct.h
  104. +4 −3 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLblend.cpp
  105. +7 −8 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLcolors.cpp
  106. +99 −45 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLd3d.cpp
  107. +32 −19 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLdraw.cpp
  108. +0 −472 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLmatrix.cpp
  109. +0 −457 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLmodel.cpp
  110. +0 −170 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLprimitives.cpp
  111. +9 −4 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLscreen.cpp
  112. +33 −37 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLshader.cpp
  113. +9 −2 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLshader.h
  114. +24 −51 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL-OpenGLES/GLvertex.cpp
  115. +5 −4 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL2-OpenGLES2/GL2screen.cpp
  116. +27 −9 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL2-OpenGLES2/GL2surface.cpp
  117. +21 −7 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL2-OpenGLES2/GL2textures.cpp
  118. +8 −3 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL3-OpenGLES3/GL3background.cpp
  119. +4 −3 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL3-OpenGLES3/GL3screen.cpp
  120. +9 −9 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL3-OpenGLES3/GL3shader.cpp
  121. +28 −8 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL3-OpenGLES3/GL3surface.cpp
  122. +26 −13 ENIGMAsystem/SHELL/Graphics_Systems/OpenGL3-OpenGLES3/GL3textures.cpp
  123. +8 −1 ENIGMAsystem/SHELL/Platforms/General/PFmain.cpp
  124. +2 −1 ENIGMAsystem/SHELL/Platforms/SDL/Makefile
  125. +1 −3 ENIGMAsystem/SHELL/Platforms/Win32/WINDOWSmain.cpp
  126. +5 −0 ENIGMAsystem/SHELL/Platforms/platforms_mandatory.h
  127. +11 −11 ENIGMAsystem/SHELL/Platforms/xlib/XLIBmain.cpp
  128. +90 −71 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/ASYNCdialog.cpp
  129. +1 −15 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/ASYNCdialog.h
  130. +0 −8 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/Makefile
  131. +0 −33 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/POSIXcreateThread.cpp
  132. +0 −51 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/SDLcreateThread.cpp
  133. +0 −41 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/WIN32createThread.cpp
  134. +1 −1 ENIGMAsystem/SHELL/Universal_System/Extensions/Asynchronous/implement.h
  135. +6 −2 ENIGMAsystem/SHELL/Universal_System/roomsystem.cpp
  136. +1 −1 ENIGMAsystem/SHELL/Universal_System/var_array.cpp
  137. +1 −1 ENIGMAsystem/SHELL/Universal_System/var_array.h
  138. +112 −69 ENIGMAsystem/SHELL/Widget_Systems/{TinyFileDialogs → General/tinyfiledialogs}/dialogs.cpp
  139. +30 −0 ENIGMAsystem/SHELL/Widget_Systems/General/tinyfiledialogs/dialogs.h
  140. +9 −0 ENIGMAsystem/SHELL/Widget_Systems/KDialog/Info/About.ey
  141. +1 −1 ENIGMAsystem/SHELL/Widget_Systems/{TinyFileDialogs → KDialog}/Info/widget_info.h
  142. +4 −0 ENIGMAsystem/SHELL/Widget_Systems/KDialog/Makefile
  143. +7 −0 ENIGMAsystem/SHELL/Widget_Systems/KDialog/dialogs.cpp
  144. +1 −0 ENIGMAsystem/SHELL/Widget_Systems/KDialog/include.h
  145. +9 −0 ENIGMAsystem/SHELL/Widget_Systems/OsaScript/Info/About.ey
  146. +5 −0 ENIGMAsystem/SHELL/Widget_Systems/OsaScript/Info/widget_info.h
  147. +4 −0 ENIGMAsystem/SHELL/Widget_Systems/OsaScript/Makefile
  148. +7 −0 ENIGMAsystem/SHELL/Widget_Systems/OsaScript/dialogs.cpp
  149. +1 −0 ENIGMAsystem/SHELL/Widget_Systems/OsaScript/include.h
  150. +0 −9 ENIGMAsystem/SHELL/Widget_Systems/TinyFileDialogs/Info/About.ey
  151. +0 −2 ENIGMAsystem/SHELL/Widget_Systems/TinyFileDialogs/Makefile
  152. +0 −21 ENIGMAsystem/SHELL/Widget_Systems/TinyFileDialogs/dialogs.h
  153. +0 −1 ENIGMAsystem/SHELL/Widget_Systems/TinyFileDialogs/include.h
  154. +9 −0 ENIGMAsystem/SHELL/Widget_Systems/Zenity/Info/About.ey
  155. +5 −0 ENIGMAsystem/SHELL/Widget_Systems/Zenity/Info/widget_info.h
  156. +4 −0 ENIGMAsystem/SHELL/Widget_Systems/Zenity/Makefile
  157. +7 −0 ENIGMAsystem/SHELL/Widget_Systems/Zenity/dialogs.cpp
  158. +1 −0 ENIGMAsystem/SHELL/Widget_Systems/Zenity/include.h
  159. +7 −3 Makefile
  160. +61 −40 appveyor.yml
  161. +8 −2 ci-regression.sh
  162. +2 −2 shared/lodepng/Makefile
  163. +503 −344 shared/tinyfiledialogs/tinyfiledialogs.cpp
  164. +16 −9 shared/tinyfiledialogs/tinyfiledialogs.h
View
@@ -1,6 +1,7 @@
/ENIGMA/
/emake
/test-runner
/gm2egm
/LinuxExtra/
/MacOS/build/Release/EnigmaXcode.app/Contents/Info.plist
/MacOS/build/Release/EnigmaXcode.app/Contents/Resources/*
View
@@ -16,32 +16,29 @@ before_install:
if [ "$TRAVIS_OS_NAME" == "linux" ]; then
sudo add-apt-repository -y ppa:maarten-fonville/protobuf;
sudo add-apt-repository -y ppa:mhier/libboost-latest;
sudo apt-get update --option Acquire::Retries=100 --option Acquire::http::Timeout="60";
sudo apt-get -y install build-essential zlib1g-dev libboost-dev libboost-iostreams-dev \
libboost-filesystem-dev libboost-program-options-dev libboost-system-dev libglew-dev \
libprotobuf-dev protobuf-compiler;
sudo apt-get -y install build-essential zlib1g-dev libboost1.67-dev \
libprotobuf-dev protobuf-compiler libglm-dev;
if [ "$COMPILER" == "gcc32" ] || [ "$COMPILER" == "clang32" ]; then
sudo dpkg --add-architecture i386;
sudo apt-get -y install libc++-dev:i386 libglu1-mesa:i386\
libc6:i386 libncurses5:i386 libstdc++6:i386 lib32z1-dev libx11-6:i386 libglew1.10:i386;
sudo apt-get -y install libc6:i386 libc++-dev:i386 libstdc++6:i386\
libncurses5:i386 lib32z1-dev libx11-6:i386 libglew-dev:i386\
libglu1-mesa-dev:i386 libgl1-mesa-dev:i386;
if [ "$COMPILER" == "gcc32" ]; then
sudo apt-get -y install gcc-multilib g++-multilib;
fi
sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so;
sudo ln -s /usr/lib/i386-linux-gnu/libX11.so.6 /usr/lib/i386-linux-gnu/libX11.so;
sudo ln -s /usr/lib/i386-linux-gnu/libGLU.so.1 /usr/lib/i386-linux-gnu/libGLU.so;
sudo ln -s /usr/include/x86_64-linux-gnu/zconf.h /usr/include;
sudo ln -s /usr/lib/i386-linux-gnu/libGLEW.so.1.10 /usr/lib/i386-linux-gnu/libGLEW.so;
elif [ "$COMPILER" == "MinGW64" ] || [ "$COMPILER" == "MinGW32" ]; then
sudo apt-get -y install mingw-w64 wine;
curl -L https://github.com/fundies/enigma-libs/files/1620148/enigma-libs.zip > enigma-libs.zip;
curl -L https://github.com/enigma-dev/enigma-dev/files/2431000/enigma-libs.zip > enigma-libs.zip;
unzip enigma-libs.zip -d ENIGMAsystem/;
mv ENIGMAsystem/Install ENIGMAsystem/Additional;
else
sudo apt-get -y install libc++-dev libglu1-mesa-dev;
sudo apt-get -y install libc++-dev libglew-dev libglu1-mesa-dev;
fi
if [ "$AUDIO" == "OpenAL" ]; then
@@ -52,7 +49,7 @@ before_install:
if [ "$TEST_HARNESS" == true ]; then
sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test;
sudo apt-get update;
sudo apt-get update --option Acquire::Retries=100 --option Acquire::http::Timeout="60";
sudo apt-get -y install cmake libgtest-dev xvfb wmctrl xdotool xfwm4 lcov gcc-7\
g++-7 cpp-7 pulseaudio libpugixml-dev libyaml-cpp-dev;
@@ -84,11 +81,9 @@ before_install:
# build JDI and the CLI
install:
- make -j4
- |
if [ "$TEST_HARNESS" == true ]; then
make -j4 emake
else
if [ "$TEST_HARNESS" != true ]; then
make -j4
CLI_ENABLE_EGM=FALSE make -j4 emake
fi
@@ -101,93 +96,103 @@ language: cpp
env:
global:
- OUTPUT=/tmp/test
# this is the default config each job in the matrix overrides a subset of
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
matrix:
# The big ol' None test.
- COMPILER=gcc PLATFORM=None MODE=Debug GRAPHICS=None AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
# Cross Compile
- COMPILER=MinGW32 PLATFORM=Win32 MODE=Run GRAPHICS=OpenGL1
- COMPILER=MinGW64 PLATFORM=Win32 MODE=Run GRAPHICS=OpenGL1
# Test Harness
- TEST_HARNESS=true AUDIO=OpenAL
# Game Modes
- COMPILER=gcc PLATFORM=xlib MODE=Run GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=gcc PLATFORM=xlib MODE=Compile GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- MODE=Run
- MODE=Debug
- MODE=Compile
# Compilers
- COMPILER=gcc32 PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=clang PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=clang32 PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=gcc32
- COMPILER=clang
- COMPILER=clang32
# Graphics
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL3 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- GRAPHICS=OpenGL3
# Audio
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=OpenAL COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=SFML COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- AUDIO=OpenAL
- AUDIO=SFML
# Collision
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=BBox NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=Precise NETWORK=None WIDGETS=None EXTENSIONS="None"
- COLLISION=BBox NETWORK=None
- COLLISION=Precise NETWORK=None
# Networking
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=Asynchronous WIDGETS=None EXTENSIONS="None"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=BerkeleySockets WIDGETS=None EXTENSIONS="None"
- NETWORK=Asynchronous
- NETWORK=BerkeleySockets
# Extensions
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="Alarms"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="DataStructures,Asynchronous"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="BasicGUI"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="DataStructures"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="DateTime"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="GM5Compat"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="IniFilesystem"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="DataStructures,Json"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="MatrixMath"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=BBox NETWORK=None WIDGETS=None EXTENSIONS="Paths"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=BBox NETWORK=None WIDGETS=None EXTENSIONS="Paths,MotionPlanning"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=Precise NETWORK=None WIDGETS=None EXTENSIONS="Paths,MotionPlanning"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="ParticleSystems"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL3 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="ParticleSystems"
- COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="Timelines"
# Cross Compile
- COMPILER=MinGW32 PLATFORM=Win32 MODE=Run GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- COMPILER=MinGW64 PLATFORM=Win32 MODE=Run GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
# The big ol' None test.
- COMPILER=gcc PLATFORM=None MODE=Debug GRAPHICS=None AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- EXTENSIONS="Alarms"
- EXTENSIONS="DataStructures,Asynchronous"
- EXTENSIONS="BasicGUI"
- EXTENSIONS="DataStructures"
- EXTENSIONS="DateTime"
- EXTENSIONS="GM5Compat"
- EXTENSIONS="IniFilesystem"
- EXTENSIONS="DataStructures,Json"
- EXTENSIONS="MatrixMath"
- COLLISION=BBox EXTENSIONS="Paths"
- COLLISION=BBox EXTENSIONS="Paths,MotionPlanning"
- COLLISION=Precise EXTENSIONS="Paths,MotionPlanning"
- GRAPHICS=OpenGL1 EXTENSIONS="ParticleSystems"
- GRAPHICS=OpenGL3 EXTENSIONS="ParticleSystems"
- EXTENSIONS="Timelines"
matrix:
include:
# SDL
- env: COMPILER=gcc PLATFORM=SDL MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None"
- env: PLATFORM=SDL
before_script: sudo apt-get -y install libsdl2-dev libegl1-mesa-dev libgles2-mesa-dev
# Widgets
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=GTK+ EXTENSIONS="None"
- env: WIDGETS=GTK+
before_script: sudo apt-get -y install libgtk2.0-dev
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=TinyFileDialogs EXTENSIONS="None"
- env: WIDGETS=Zenity
before_script: sudo apt-get -y install zenity
- env: WIDGETS=KDialog
before_script: sudo apt-get -y install kdebase-bin
# GME (Note: requires an Audio system)
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=OpenAL COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="GME"
- env: AUDIO=OpenAL EXTENSIONS="GME"
before_script: sudo apt-get -y install libgme-dev
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=SFML COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="GME"
- env: AUDIO=SFML EXTENSIONS="GME"
before_script: sudo apt-get -y install libgme-dev
# Box2D
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="Box2DPhysics"
- env: EXTENSIONS="Box2DPhysics"
before_script: sudo apt-get -y install libbox2d-dev
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="StudioPhysics"
- env: EXTENSIONS="StudioPhysics"
before_script: sudo apt-get -y install libbox2d-dev
# Bullet Physics
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="BulletDynamics"
- env: EXTENSIONS="BulletDynamics"
before_script: sudo apt-get -y install libbullet-dev
#FreeType
- env: COMPILER=gcc PLATFORM=xlib MODE=Debug GRAPHICS=OpenGL1 AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="ttf"
- env: EXTENSIONS="ttf"
before_script: sudo apt-get -y install libfreetype6-dev
# OSX
- { os: osx, osx_image: xcode9.2,
env: COMPILER=clang PLATFORM=None MODE=Debug GRAPHICS=None AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None" }
env: COMPILER=clang PLATFORM=None }
- { os: osx, osx_image: xcode9.2,
env: COMPILER=gcc PLATFORM=None MODE=Debug GRAPHICS=None AUDIO=None COLLISION=None NETWORK=None WIDGETS=None EXTENSIONS="None" }
env: COMPILER=gcc PLATFORM=None }
# don't wait for OSX
fast_finish: true
allow_failures:
- os: osx
script:
before_script:
- |
if [ "$TEST_HARNESS" == true ]; then
# Start xvfb before the script phase
export DISPLAY=:1
Xvfb :1 -screen 0 1024x768x24 &
xfwm4 &
fi
script:
- |
if [ "$TEST_HARNESS" == true ]; then
export ASAN_OPTIONS=detect_leaks=0;
./ci-regression.sh "/tmp/enigma-master"
./ci-regression.sh "/tmp/enigma-master" 4
else
./ci-build.sh
fi
@@ -79,7 +79,7 @@ OptionsParser::OptionsParser() : _desc("Options")
std::string def_platform, def_workdir, def_compiler;
#if CURRENT_PLATFORM_ID == OS_WINDOWS
def_platform = "Win32";
def_workdir = "%LOCALAPPDATA%/ENIGMA/";
def_workdir = std::string(getenv("LOCALAPPDATA")) + "/ENIGMA/";
def_compiler = "gcc";
#elif CURRENT_PLATFORM_ID == OS_MACOSX
def_platform = "Cocoa";
@@ -670,7 +670,7 @@ Instance AddInstance(const buffers::resources::Room::Instance& inst) {
i.objectId = Name2Id(inst.object_type());
i.x = inst.x();
i.y = inst.y();
i.locked = inst.locked();
i.locked = inst.editor_settings().locked();
i.creationCode = inst.code().c_str();
i.preCreationCode = "";
@@ -684,7 +684,7 @@ Tile AddTile(const buffers::resources::Room::Tile& tile) {
t.backgroundId = Name2Id(tile.background_name());
t.roomX = tile.x();
t.roomY = tile.y();
t.locked = tile.locked();
t.locked = tile.editor_settings().locked();
t.bgX = tile.xoffset();
t.bgY = tile.yoffset();
t.width = tile.width();
@@ -0,0 +1,53 @@
#include "gmx.h"
#include "gmk.h"
#include "yyp.h"
#include "egm.h"
#include <iostream>
#include <string>
static std::string tolower(const std::string &str) {
std::string res = str;
for (size_t i = 0; i < res.length(); ++i) {
if (res[i] >= 'A' && res[i] <= 'Z') res[i] += 'a' - 'A';
}
return res;
}
int main(int argc, char *argv[])
{
if (argc != 3) {
std::cerr << "Usage: gm2egm <input> <output>" << std::endl;
return -1;
}
std::string input_file = argv[1];
std::string ext;
size_t dot = input_file.find_last_of('.');
if (dot != std::string::npos) ext = tolower(input_file.substr(dot + 1));
buffers::Project* project = nullptr;
if (ext == "gm81" || ext == "gmk" || ext == "gm6" || ext == "gmd") {
project = gmk::LoadGMK(input_file);
} else if (ext == "gmx") {
project = gmx::LoadGMX(input_file);
} else if (ext == "yyp") {
project = yyp::LoadYYP(input_file);
} else {
std::cerr << "Error: Unkown extenstion \"" << ext << "\"." << std::endl;
return -2;
}
if (project == nullptr) {
std::cerr << "Error: Failure opening file \"" << input_file << "\"" << std::endl;
return -3;
}
if (!egm::WriteEGM(argv[2], project)) {
std::cerr << "Error: Failure writting \"" << argv[2] << std::endl;
return -4;
}
return 0;
}
@@ -0,0 +1,81 @@
#include "egm-rooms.cpp"
#include <gtest/gtest.h>
using namespace egm::util;
Coords A { 0, 0, 0 };
Coords B { 0, 0, 1 };
Coords C { 0, 1, 0 };
Coords D { 0, 1, 1 };
Coords E { 1, 0, 0 };
Coords F { 1, 0, 1 };
Coords G { 1, 1, 0 };
Coords H { 1, 1, 1 };
#include <iostream>
using namespace std;
TEST(ConnectedComponentsTest, OneComponentConnection) {
ConnectedComponents comp;
comp.Connect(A, B);
ASSERT_EQ(comp.components.size(), 1);
ASSERT_EQ(comp.components.begin()->second.size(), 2);
}
TEST(ConnectedComponentsTest, BasicComponentConnections) {
ConnectedComponents comp;
comp.Connect(A, B);
comp.Connect(B, C);
comp.Connect(C, D);
ASSERT_EQ(comp.components.size(), 1);
ASSERT_EQ(comp.components.begin()->second.size(), 4);
ASSERT_EQ(comp.components.begin()->second, (std::set<Coords> {A, B, C, D}));
}
TEST(ConnectedComponentsTest, BridgingComponentConnections) {
ConnectedComponents comp;
comp.Connect(A, B);
comp.Connect(B, C);
comp.Connect(D, E);
comp.Connect(E, F);
comp.Connect(C, D);
cout << "Components (" << comp.components.size() << "):" << endl;
for (const auto &s : comp.components) {
cout << " - Component " << s.first << " (" << s.second.size() << " items)\n";
for (const Coords &c : s.second) {
cout << " • (" << c.x << ", " << c.y << ", " << c.z << ")" << endl;
}
}
ASSERT_EQ(comp.components.size(), 1);
ASSERT_EQ(comp.components.begin()->second.size(), 6);
ASSERT_EQ(comp.components.begin()->second, (std::set<Coords> {A, B, C, D, E, F}));
}
TEST(ConnectedComponentsTest, DoubleConnectComponentsAA) {
ConnectedComponents comp;
comp.Connect(A, B);
comp.Connect(A, B);
ASSERT_EQ(comp.components.size(), 1);
ASSERT_EQ(comp.components.begin()->second.size(), 2);
}
TEST(ConnectedComponentsTest, DoubleConnectComponentsAB) {
ConnectedComponents comp;
comp.Connect(A, B);
comp.Connect(B, A);
ASSERT_EQ(comp.components.size(), 1);
ASSERT_EQ(comp.components.begin()->second.size(), 2);
}
TEST(ConnectedComponentsTest, TripleConnectComponents) {
ConnectedComponents comp;
comp.Connect(A, B);
comp.Connect(B, A);
comp.Connect(A, B);
ASSERT_EQ(comp.components.size(), 1);
ASSERT_EQ(comp.components.begin()->second.size(), 2);
}
@@ -0,0 +1,5 @@
vcpkg install pugixml:x64-windows rapidjson:x64-windows yaml-cpp:x64-windows
cmake -G "Visual Studio 15 2017 Win64" -DVCPKG_TARGET_TRIPLET=x64-windows-static -DCMAKE_TOOLCHAIN_FILE="C:\vcpkg\scripts\buildsystems\vcpkg.cmake" ..
mkdir build
cd build/
cmake --build . --target install --config MinSizeRel
Oops, something went wrong.

0 comments on commit b414381

Please sign in to comment.