Преглед изворни кода

Removed the model build step from CMakeLists.txt. Instead added binary models directly to the repository.

Lasse Öörni пре 13 година
родитељ
комит
3f2e63b952
46 измењених фајлова са 16 додато и 47 уклоњено
  1. 7 0
      Bin/ConvertModels.bat
  2. BIN
      Bin/Data/Models/Jack.mdl
  3. BIN
      Bin/Data/Models/Jack_Walk.ani
  4. BIN
      Bin/Data/Models/Level.mdl
  5. BIN
      Bin/Data/Models/Mushroom.mdl
  6. BIN
      Bin/Data/Models/Ninja.mdl
  7. BIN
      Bin/Data/Models/Ninja_Attack1.ani
  8. BIN
      Bin/Data/Models/Ninja_Attack2.ani
  9. BIN
      Bin/Data/Models/Ninja_Attack3.ani
  10. BIN
      Bin/Data/Models/Ninja_Backflip.ani
  11. BIN
      Bin/Data/Models/Ninja_Block.ani
  12. BIN
      Bin/Data/Models/Ninja_Climb.ani
  13. BIN
      Bin/Data/Models/Ninja_Crouch.ani
  14. BIN
      Bin/Data/Models/Ninja_Death1.ani
  15. BIN
      Bin/Data/Models/Ninja_Death2.ani
  16. BIN
      Bin/Data/Models/Ninja_HighJump.ani
  17. BIN
      Bin/Data/Models/Ninja_Idle1.ani
  18. BIN
      Bin/Data/Models/Ninja_Idle2.ani
  19. BIN
      Bin/Data/Models/Ninja_Idle3.ani
  20. BIN
      Bin/Data/Models/Ninja_Jump.ani
  21. BIN
      Bin/Data/Models/Ninja_JumpNoHeight.ani
  22. BIN
      Bin/Data/Models/Ninja_Kick.ani
  23. BIN
      Bin/Data/Models/Ninja_SideKick.ani
  24. BIN
      Bin/Data/Models/Ninja_Spin.ani
  25. BIN
      Bin/Data/Models/Ninja_Stealth.ani
  26. BIN
      Bin/Data/Models/Ninja_Walk.ani
  27. BIN
      Bin/Data/Models/Potion.mdl
  28. BIN
      Bin/Data/Models/SnowBall.mdl
  29. BIN
      Bin/Data/Models/SnowCrate.mdl
  30. 0 20
      CMakeLists.txt
  31. 4 4
      Docs/GettingStarted.dox
  32. 5 12
      Readme.txt
  33. 0 0
      SourceAssets/Axes.blend
  34. 0 0
      SourceAssets/Jack.mesh.xml
  35. 0 0
      SourceAssets/Jack.skeleton.xml
  36. 0 0
      SourceAssets/Level.mesh.xml
  37. 0 11
      SourceAssets/Models/CMakeLists.txt
  38. 0 0
      SourceAssets/Mushroom.mesh.xml
  39. 0 0
      SourceAssets/Mushroom.skeleton.xml
  40. 0 0
      SourceAssets/Ninja.mesh.xml
  41. 0 0
      SourceAssets/Ninja.skeleton.xml
  42. 0 0
      SourceAssets/Potion.mesh.xml
  43. 0 0
      SourceAssets/RotateAxes.blend
  44. 0 0
      SourceAssets/ScaleAxes.blend
  45. 0 0
      SourceAssets/SnowBall.mesh.xml
  46. 0 0
      SourceAssets/SnowCrate.mesh.xml

+ 7 - 0
Bin/ConvertModels.bat

@@ -0,0 +1,7 @@
+OgreImporter ../SourceAssets/Jack.mesh.xml Data/Models/Jack.mdl -a
+OgreImporter ../SourceAssets/Level.mesh.xml Data/Models/Level.mdl
+OgreImporter ../SourceAssets/Mushroom.mesh.xml Data/Models/Mushroom.mdl
+OgreImporter ../SourceAssets/Ninja.mesh.xml Data/Models/Ninja.mdl -a
+OgreImporter ../SourceAssets/Potion.mesh.xml Data/Models/Potion.mdl
+OgreImporter ../SourceAssets/SnowBall.mesh.xml Data/Models/SnowBall.mdl
+OgreImporter ../SourceAssets/SnowCrate.mesh.xml Data/Models/SnowCrate.mdl

BIN
Bin/Data/Models/Jack.mdl


BIN
Bin/Data/Models/Jack_Walk.ani


BIN
Bin/Data/Models/Level.mdl


BIN
Bin/Data/Models/Mushroom.mdl


BIN
Bin/Data/Models/Ninja.mdl


BIN
Bin/Data/Models/Ninja_Attack1.ani


BIN
Bin/Data/Models/Ninja_Attack2.ani


BIN
Bin/Data/Models/Ninja_Attack3.ani


BIN
Bin/Data/Models/Ninja_Backflip.ani


BIN
Bin/Data/Models/Ninja_Block.ani


BIN
Bin/Data/Models/Ninja_Climb.ani


BIN
Bin/Data/Models/Ninja_Crouch.ani


BIN
Bin/Data/Models/Ninja_Death1.ani


BIN
Bin/Data/Models/Ninja_Death2.ani


BIN
Bin/Data/Models/Ninja_HighJump.ani


BIN
Bin/Data/Models/Ninja_Idle1.ani


BIN
Bin/Data/Models/Ninja_Idle2.ani


BIN
Bin/Data/Models/Ninja_Idle3.ani


BIN
Bin/Data/Models/Ninja_Jump.ani


BIN
Bin/Data/Models/Ninja_JumpNoHeight.ani


BIN
Bin/Data/Models/Ninja_Kick.ani


BIN
Bin/Data/Models/Ninja_SideKick.ani


BIN
Bin/Data/Models/Ninja_Spin.ani


BIN
Bin/Data/Models/Ninja_Stealth.ani


BIN
Bin/Data/Models/Ninja_Walk.ani


BIN
Bin/Data/Models/Potion.mdl


BIN
Bin/Data/Models/SnowBall.mdl


BIN
Bin/Data/Models/SnowCrate.mdl


+ 0 - 20
CMakeLists.txt

@@ -101,25 +101,6 @@ endmacro ()
 macro (finalize_lib)
 endmacro ()
 
-# Macro for model asset compilation
-macro (add_model NAME PARAMETERS)
-    if (IOS)
-        add_custom_command (
-            OUTPUT ../../Bin/Data/Models/${NAME}.mdl
-            COMMAND ../../Bin/OgreImporter ${NAME}.mesh.xml ../../Bin/Data/Models/${NAME}.mdl ${PARAMETERS}
-            DEPENDS ${NAME}.mesh.xml
-        )
-    else ()
-        add_custom_command (
-            OUTPUT ../../Bin/Data/Models/${NAME}.mdl
-            COMMAND ../../Bin/OgreImporter ${NAME}.mesh.xml ../../Bin/Data/Models/${NAME}.mdl ${PARAMETERS}
-            DEPENDS OgreImporter ${NAME}.mesh.xml
-        )
-    endif ()
-
-    set (ALL_MODELS ${ALL_MODELS} ../../Bin/Data/Models/${NAME}.mdl)
-endmacro ()
-
 # Add SDL as a global include directory
 include_directories (ThirdParty/SDL/include)
 
@@ -138,7 +119,6 @@ add_subdirectory (Engine/Resource)
 add_subdirectory (Engine/Scene)
 add_subdirectory (Engine/Script)
 add_subdirectory (Engine/UI)
-add_subdirectory (SourceAssets/Models)
 add_subdirectory (ThirdParty/AngelScript)
 add_subdirectory (ThirdParty/Bullet)
 add_subdirectory (ThirdParty/FreeType)

+ 4 - 4
Docs/GettingStarted.dox

@@ -34,10 +34,10 @@ Urho3D uses CMake (http://www.cmake.org) to build. The process has two steps:
 
 2) For Visual Studio, open Urho3D.sln and build the configuration(s) you like. For gcc, execute make (by default, cmake_gcc.sh specifies to make a RelWithDebInfo build.)
 
-The build process will also convert models from the SourceAssets directory into Bin/Data/Models. After the build is complete, the programs can be run from the Bin directory.
-
 When using Xcode on Mac OS X, select the i386 architecture before building. Compiling Urho3D as 64-bit is not supported.
 
+After the build is complete, the programs can be run from the Bin directory.
+
 To run from the Visual Studio debugger, set the Urho3D project as the startup project and enter its relative path and filename into Properties -> Debugging -> Command: ..\\Bin\\Urho3D.exe. Additionally, entering -w into Debugging -> Command Arguments is highly recommended. This enables startup in windowed mode: without it running into an exception or breakpoint will be obnoxious as the mouse cursor will likely be hidden.
 
 To actually make Urho3D.exe do something useful, it must be supplied with the name of the script file it should load and run. You can try for example the following arguments: Scripts/TestScene.as -w
@@ -46,7 +46,7 @@ To make the Urho3D examples start faster on Windows & Direct3D9 mode, run Compil
 
 \section Building_Android Android build process
 
-First build desktop Urho3D to make sure the models from the SourceAssets directory are converted. Then copy Bin/Data and Bin/CoreData directories to the Android/assets directory. Finally execute the following commands in the Android directory:
+First copy Bin/Data and Bin/CoreData directories to the Android/assets directory (you can use the provided batch file CopyData.bat.) Next, execute the following commands in the Android directory:
 
 - android update project -p . (only needed on the first time)
 - ndk-build
@@ -64,7 +64,7 @@ By default the Android package for Urho3D is com.googlecode.urho3d. For a real a
 
 \section Building_Ios iOS build process
 
-First build desktop Urho3D to generate the OgreImporter utility into the Bin directory. Then run cmake_ios.sh. This generates an Xcode project named Urho3D.xcodeproj.
+Run cmake_ios.sh. This generates an Xcode project named Urho3D.xcodeproj.
 
 Open the Xcode project and check the properties for the Urho3D project (topmost in the Project Navigator.) In Architectures -> Base SDK, choose your iOS SDK. In Code Signing, enter your developer identity as necessary.
 

+ 5 - 12
Readme.txt

@@ -125,11 +125,7 @@ Mac OS X.
 For gcc, execute make (by default, cmake_gcc.sh specifies to make a
 RelWithDebInfo build.)
 
-The build process will also convert models from the SourceAssets directory into
-Bin/Data/Models. After the build is complete, the programs can be run from the 
-Bin directory.
-
-When using Xcode on Mac OS X, select the i386 architecture before building. 
+When using Xcode on Mac OS X, select the i386 architecture before building.
 Compiling Urho3D as 64-bit is not supported.
 
 After the build is complete, the programs can be run from the Bin directory.
@@ -152,10 +148,9 @@ CompileAllShaders.bat from the Bin directory first.
 Android build process
 ---------------------
 
-First build desktop Urho3D to make sure the models from the SourceAssets 
-directory are converted. Then copy Bin/Data and Bin/CoreData directories to the
-Android/assets directory. Finally execute the following commands in the Android
-directory:
+First copy Bin/Data and Bin/CoreData directories to the Android/assets directory
+(you can use the provided batch file CopyData.bat.) Next, execute the following
+commands in the Android directory:
 
 - android update project -p . (only needed on the first time)
 - ndk-build
@@ -182,9 +177,7 @@ name has to be replaced in several files:
 iOS build process
 -----------------
 
-First build desktop Urho3D to generate the OgreImporter utility into the Bin 
-directory. Then run cmake_ios.sh. This generates an Xcode project named
-Urho3D.xcodeproj.
+Run cmake_ios.sh. This generates an Xcode project named Urho3D.xcodeproj.
 
 Open the Xcode project and check the properties for the Urho3D project (topmost
 in the Project Navigator.) In Architectures -> Base SDK, choose your iOS SDK.

+ 0 - 0
SourceAssets/Models/Axes.blend → SourceAssets/Axes.blend


+ 0 - 0
SourceAssets/Models/Jack.mesh.xml → SourceAssets/Jack.mesh.xml


+ 0 - 0
SourceAssets/Models/Jack.skeleton.xml → SourceAssets/Jack.skeleton.xml


+ 0 - 0
SourceAssets/Models/Level.mesh.xml → SourceAssets/Level.mesh.xml


+ 0 - 11
SourceAssets/Models/CMakeLists.txt

@@ -1,11 +0,0 @@
-SET (ALL_MODELS)
-
-add_model (Jack "-a")
-add_model (Level "")
-add_model (Mushroom "-a")
-add_model (Ninja "-a")
-add_model (Potion "")
-add_model (SnowBall "")
-add_model (SnowCrate "")
-
-add_custom_target (Models ALL DEPENDS ${ALL_MODELS})

+ 0 - 0
SourceAssets/Models/Mushroom.mesh.xml → SourceAssets/Mushroom.mesh.xml


+ 0 - 0
SourceAssets/Models/Mushroom.skeleton.xml → SourceAssets/Mushroom.skeleton.xml


+ 0 - 0
SourceAssets/Models/Ninja.mesh.xml → SourceAssets/Ninja.mesh.xml


+ 0 - 0
SourceAssets/Models/Ninja.skeleton.xml → SourceAssets/Ninja.skeleton.xml


+ 0 - 0
SourceAssets/Models/Potion.mesh.xml → SourceAssets/Potion.mesh.xml


+ 0 - 0
SourceAssets/Models/RotateAxes.blend → SourceAssets/RotateAxes.blend


+ 0 - 0
SourceAssets/Models/ScaleAxes.blend → SourceAssets/ScaleAxes.blend


+ 0 - 0
SourceAssets/Models/SnowBall.mesh.xml → SourceAssets/SnowBall.mesh.xml


+ 0 - 0
SourceAssets/Models/SnowCrate.mesh.xml → SourceAssets/SnowCrate.mesh.xml