Explorar el Código

Added support of CrossVCL for Linux and MacOS thnx Eugene Kryukov

GLScene hace 4 años
padre
commit
1736180f36
Se han modificado 81 ficheros con 658 adiciones y 480 borrados
  1. 3 3
      AdvDemos/CPP/Archipelago/Unit1.cpp
  2. 3 3
      AdvDemos/Delphi/Archipelago/Unit1.pas
  3. 9 9
      AdvDemos/Delphi/Earth/Unit1.pas
  4. 3 3
      AdvDemos/Delphi/Forest/Unit1.pas
  5. 250 123
      Demos/CPP/bench/megacube/MegaCube.cbproj
  6. 7 9
      Demos/CPP/bench/megaglasscube/Unit1.cpp
  7. 0 1
      Demos/CPP/bench/megaglasscube/Unit1.dfm
  8. 0 1
      Demos/CPP/bench/megaglasscube/Unit1.h
  9. 1 1
      Demos/CPP/cgshaders/simple/Unit1.cpp
  10. 2 2
      Demos/CPP/cgshaders/texturing/Unit1.cpp
  11. 2 2
      Demos/CPP/collisions/Raycast/Unit1.cpp
  12. 4 4
      Demos/CPP/collisions/boxedin/Unit1.cpp
  13. 1 1
      Demos/CPP/collisions/boxedin/Unit1.h
  14. 1 1
      Demos/CPP/collisions/facevsface/Unit1.cpp
  15. 2 2
      Demos/CPP/collisions/meshhit/Unit1.cpp
  16. 1 1
      Demos/CPP/collisions/octree/Unit1.cpp
  17. 2 2
      Demos/CPP/graph/projection/Unit1.cpp
  18. 5 5
      Demos/CPP/interface/CameraController/Unit1.cpp
  19. 1 1
      Demos/CPP/interface/CameraController/Unit1.h
  20. 2 2
      Demos/CPP/interface/GizmoEx/Unit1.h
  21. 1 1
      Demos/CPP/interface/camera/Unit1.cpp
  22. 4 4
      Demos/CPP/meshes/actorproxy/Unit1.cpp
  23. 1 1
      Demos/CPP/meshes/actortwocam/Unit1.cpp
  24. 1 1
      Demos/CPP/meshes/mushroom/Unit1.cpp
  25. 1 1
      Demos/CPP/meshes/shadedterrain/Unit1.cpp
  26. 1 1
      Demos/CPP/meshes/terrain/Unit1.cpp
  27. 1 1
      Demos/CPP/movements/objmove/Objmove.cpp
  28. 6 4
      Demos/CPP/movements/objmove/Unit1.cpp
  29. 30 31
      Demos/CPP/movements/objmove/Unit1.dfm
  30. 7 4
      Demos/CPP/movements/objmove/Unit1.h
  31. 1 1
      Demos/CPP/movements/pong/Unit1.cpp
  32. 2 2
      Demos/CPP/physics/NewtonDensity/Unit1.cpp
  33. 2 2
      Demos/CPP/physics/OdeConveyor/Unit1.h
  34. 1 1
      Demos/CPP/specialsFX/waterplane/Unit1.cpp
  35. 2 2
      Demos/CPP/sprites/imposter/Unit1.cpp
  36. 1 1
      Demos/CleanDemos.bat
  37. 1 1
      Demos/Delphi/bench/CanvasFm.dfm
  38. 1 1
      Demos/Delphi/cgshaders/CgSimpleFm.pas
  39. 2 2
      Demos/Delphi/cgshaders/CgTextureFm.pas
  40. 1 1
      Demos/Delphi/glslshaders/OceanFm.pas
  41. 2 2
      Demos/Delphi/graph/ProjectionFm.pas
  42. 8 8
      Demos/Delphi/interface/CameraControllerFm.pas
  43. 1 1
      Demos/Delphi/interface/CameraFm.pas
  44. 6 6
      Demos/Delphi/interface/GizmoexFm.pas
  45. 1 1
      Demos/Delphi/meshes/ActorProxyFm.pas
  46. 1 1
      Demos/Delphi/meshes/ActorTwocamFm.pas
  47. 1 1
      Demos/Delphi/meshes/MushroomFm.pas
  48. 1 1
      Demos/Delphi/meshes/ShadedTerrainFm.pas
  49. 1 1
      Demos/Delphi/meshes/TerrainFm.pas
  50. 2 2
      Demos/Delphi/meshes/TilesFm.pas
  51. 5 4
      Demos/Delphi/movements/Objmove.dpr
  52. 44 55
      Demos/Delphi/movements/ObjmoveFm.dfm
  53. 40 29
      Demos/Delphi/movements/ObjmoveFm.pas
  54. 1 1
      Demos/Delphi/movements/PongFm.pas
  55. 1 1
      Demos/Delphi/movements/TweeningFm.pas
  56. 2 2
      Demos/Delphi/physics/NewtonDensityFm.pas
  57. 2 2
      Demos/Delphi/physics/NewtonJointsFm.pas
  58. 2 2
      Demos/Delphi/physics/NewtonMousePickFm.pas
  59. 2 2
      Demos/Delphi/physics/NewtonWalkCarryFm.pas
  60. 6 6
      Demos/Delphi/physics/NewtonWalkShootFm.pas
  61. 2 2
      Demos/Delphi/physics/OdeConveyorFm.pas
  62. 33 22
      Demos/Delphi/rendering/FogFm.pas
  63. 4 4
      Demos/Delphi/specialsFX/CandlesFm.dfm
  64. 1 1
      Demos/Delphi/specialsFX/WaterPlaneFm.pas
  65. 1 3
      Demos/Delphi/sprites/ImposterFm.pas
  66. 2 2
      Demos/Delphi/utilities/ArchiveEdit/Main.dfm
  67. 23 17
      Demos/Delphi/utilities/ArchiveEdit/Main.pas
  68. 1 0
      Source/GLS.BaseClasses.pas
  69. 8 8
      Source/GLS.Canvas.pas
  70. 10 11
      Source/GLS.Imposter.pas
  71. 2 6
      Source/GLS.Isosurface.pas
  72. 2 2
      Source/GLS.Logger.pas
  73. 2 1
      Source/GLS.Mesh.pas
  74. 6 6
      Source/GLS.Objects.pas
  75. 23 0
      Source/GLS.OpenGLAdapter.pas
  76. 6 18
      Source/GLS.Selection.pas
  77. 2 0
      Source/GLS.Sound.pas
  78. 4 0
      Source/GLS.VectorGeometry.pas
  79. 19 2
      Source/GLS.VectorTypes.pas
  80. 8 6
      Source/GLScene.inc
  81. 4 2
      Source/Physics.NGDRagdoll.pas

+ 3 - 3
AdvDemos/CPP/Archipelago/Unit1.cpp

@@ -140,7 +140,7 @@ void __fastcall TForm1::GLCadencerProgress(TObject *Sender,
 	const double deltaTime, const double newTime) {
 	const double deltaTime, const double newTime) {
 	float Speed, Alpha, f;
 	float Speed, Alpha, f;
 	float TerrainHeight, SurfaceHeight;
 	float TerrainHeight, SurfaceHeight;
-	Gls::Vectorgeometry::TVector Sbp;
+	TGLVector Sbp;
 	POINT NewMousePos;
 	POINT NewMousePos;
 
 
 	// Handle keypresses
 	// Handle keypresses
@@ -477,7 +477,7 @@ void __fastcall TForm1::TerrainRendererHeightDataPostRender
 void __fastcall TForm1::DOWakeProgress(TObject *Sender, const double deltaTime,
 void __fastcall TForm1::DOWakeProgress(TObject *Sender, const double deltaTime,
 	const double newTime) {
 	const double newTime) {
 	int i;
 	int i;
-	Gls::Vectorgeometry::TVector sbp, sbr;
+	TGLVector sbp, sbr;
 
 
 	if (WakeVertices == NULL) {
 	if (WakeVertices == NULL) {
 		WakeVertices = new TAffineVectorList();
 		WakeVertices = new TAffineVectorList();
@@ -523,7 +523,7 @@ void __fastcall TForm1::DOWakeProgress(TObject *Sender, const double deltaTime,
 void __fastcall TForm1::DOWakeRender(TObject *Sender, TGLRenderContextInfo &rci) {
 void __fastcall TForm1::DOWakeRender(TObject *Sender, TGLRenderContextInfo &rci) {
 	int i, n;
 	int i, n;
 	Gls::Vectortypes::TVector3f p;
 	Gls::Vectortypes::TVector3f p;
-	Gls::Vectorgeometry::TVector sbp;
+	TGLVector sbp;
 	float c;
 	float c;
 
 
 	if (!(WakeVertices) && (!((FFSailBoat->Visible) || (WaterPlane)))) {
 	if (!(WakeVertices) && (!((FFSailBoat->Visible) || (WaterPlane)))) {

+ 3 - 3
AdvDemos/Delphi/Archipelago/Unit1.pas

@@ -204,7 +204,7 @@ procedure TForm1.GLCadencerProgress(Sender: TObject; const deltaTime,
 var
 var
   speed, alpha, f: Single;
   speed, alpha, f: Single;
   terrainHeight, surfaceHeight: Single;
   terrainHeight, surfaceHeight: Single;
-  sbp: TVector;
+  sbp: TGLVector;
   newMousePos: TPoint;
   newMousePos: TPoint;
 begin
 begin
   // handle keypresses
   // handle keypresses
@@ -532,7 +532,7 @@ procedure TForm1.DOWakeProgress(Sender: TObject; const deltaTime,
   newTime: Double);
   newTime: Double);
 var
 var
   i: Integer;
   i: Integer;
-  sbp, sbr: TVector;
+  sbp, sbr: TGLVector;
 begin
 begin
   if WakeVertices = nil then
   if WakeVertices = nil then
   begin
   begin
@@ -583,7 +583,7 @@ procedure TForm1.DOWakeRender(Sender: TObject; var rci: TGLRenderContextInfo);
 var
 var
   i, n: Integer;
   i, n: Integer;
   p: PAffineVector;
   p: PAffineVector;
-  sbp: TVector;
+  sbp: TGLVector;
   c: Single;
   c: Single;
 begin
 begin
   if not Assigned(WakeVertices) then
   if not Assigned(WakeVertices) then

+ 9 - 9
AdvDemos/Delphi/Earth/Unit1.pas

@@ -127,13 +127,13 @@ const
     1 / 11, 1 / 12, 1 / 13, 1 / 14, 1 / 15, 1 / 16, 1 / 17, 1 / 18, 1 / 19, 1 / 20);
     1 / 11, 1 / 12, 1 / 13, 1 / 14, 1 / 15, 1 / 16, 1 / 17, 1 / 18, 1 / 19, 1 / 20);
 var
 var
   radius, invAtmosphereHeight: Single;
   radius, invAtmosphereHeight: Single;
-  sunPos, eyePos, lightingVector: TVector;
-  diskNormal, diskRight, diskUp: TVector;
+  sunPos, eyePos, lightingVector: TGLVector;
+  diskNormal, diskRight, diskUp: TGLVector;
 
 
-  function AtmosphereColor(const rayStart, rayEnd: TVector): TColorVector;
+  function AtmosphereColor(const rayStart, rayEnd: TGLVector): TColorVector;
   var
   var
     i, n: Integer;
     i, n: Integer;
-    atmPoint, normal: TVector;
+    atmPoint, normal: TGLVector;
     altColor: TColorVector;
     altColor: TColorVector;
     alt, rayLength, contrib, decay, intensity, invN: Single;
     alt, rayLength, contrib, decay, intensity, invN: Single;
   begin
   begin
@@ -174,10 +174,10 @@ var
     Result.W := n * contrib * cOpacity * 0.1;
     Result.W := n * contrib * cOpacity * 0.1;
   end;
   end;
 
 
-  function ComputeColor(var rayDest: TVector; mayHitGround: Boolean): TColorVector;
+  function ComputeColor(var rayDest: TGLVector; mayHitGround: Boolean): TColorVector;
   var
   var
-    ai1, ai2, pi1, pi2: TVector;
-    rayVector: TVector;
+    ai1, ai2, pi1, pi2: TGLVector;
+    rayVector: TGLVector;
   begin
   begin
     rayVector := VectorNormalize(VectorSubtract(rayDest, eyePos));
     rayVector := VectorNormalize(VectorSubtract(rayDest, eyePos));
     if RayCastSphereIntersect(eyePos, rayVector, NullHmgPoint, cAtmosphereRadius, ai1, ai2) > 1 then
     if RayCastSphereIntersect(eyePos, rayVector, NullHmgPoint, cAtmosphereRadius, ai1, ai2) > 1 then
@@ -220,8 +220,8 @@ begin
   lightingVector := VectorNormalize(sunPos); // sun at infinity
   lightingVector := VectorNormalize(sunPos); // sun at infinity
   PrepareSinCosCache(sinCache, cosCache, 0, 360);
   PrepareSinCosCache(sinCache, cosCache, 0, 360);
 
 
-  GetMem(pVertex, 2 * (cSlices + 1) * SizeOf(TVector));
-  GetMem(pColor, 2 * (cSlices + 1) * SizeOf(TVector));
+  GetMem(pVertex, 2 * (cSlices + 1) * SizeOf(TGLVector));
+  GetMem(pColor, 2 * (cSlices + 1) * SizeOf(TGLVector));
 
 
   rci.GLStates.DepthWriteMask := False;
   rci.GLStates.DepthWriteMask := False;
   rci.GLStates.Disable(stLighting);
   rci.GLStates.Disable(stLighting);

+ 3 - 3
AdvDemos/Delphi/Forest/Unit1.pas

@@ -374,7 +374,7 @@ const
   cTreeCenteringOffset: TAffineVector = (X:0; Y:30; Z:0);
   cTreeCenteringOffset: TAffineVector = (X:0; Y:30; Z:0);
 var
 var
   d: Single;
   d: Single;
-  camPos: TVector;
+  camPos: TGLVector;
 begin
 begin
   if not IsVolumeClipped(VectorAdd(aParticle.Position, cTreeCenteringOffset), 30, rci.rcci.frustum)
   if not IsVolumeClipped(VectorAdd(aParticle.Position, cTreeCenteringOffset), 30, rci.rcci.frustum)
   then
   then
@@ -398,7 +398,7 @@ procedure TForm1.PFXTreesEndParticles(Sender: TObject;
   var rci: TGLRenderContextInfo);
   var rci: TGLRenderContextInfo);
 var
 var
   aParticle: TGLParticle;
   aParticle: TGLParticle;
-  camPos: TVector;
+  camPos: TGLVector;
 begin
 begin
   // Only 20 trees max rendered at full res, force imposter'ing the others
   // Only 20 trees max rendered at full res, force imposter'ing the others
   while nearTrees.Count > 20 do
   while nearTrees.Count > 20 do
@@ -505,7 +505,7 @@ procedure TForm1.DOInitializeReflectionRender(Sender: TObject;
 var
 var
   w, h: Integer;
   w, h: Integer;
   refMat: TMatrix;
   refMat: TMatrix;
-  cameraPosBackup, cameraDirectionBackup: TVector;
+  cameraPosBackup, cameraDirectionBackup: TGLVector;
   frustumBackup: TFrustum;
   frustumBackup: TFrustum;
   clipPlane: TDoubleHmgPlane;
   clipPlane: TDoubleHmgPlane;
   glTarget: GLEnum;
   glTarget: GLEnum;

+ 250 - 123
Demos/CPP/bench/megacube/MegaCube.cbproj

@@ -8,7 +8,7 @@
         <Base>True</Base>
         <Base>True</Base>
         <Config Condition="'$(Config)'==''">Debug</Config>
         <Config Condition="'$(Config)'==''">Debug</Config>
         <Platform Condition="'$(Platform)'==''">Win32</Platform>
         <Platform Condition="'$(Platform)'==''">Win32</Platform>
-        <TargetedPlatforms>1</TargetedPlatforms>
+        <TargetedPlatforms>3</TargetedPlatforms>
     </PropertyGroup>
     </PropertyGroup>
     <PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
     <PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
         <Base>true</Base>
         <Base>true</Base>
@@ -93,11 +93,12 @@
         <Manifest_File>$(BDS)\bin\default_app.manifest</Manifest_File>
         <Manifest_File>$(BDS)\bin\default_app.manifest</Manifest_File>
         <VerInfo_Locale>1033</VerInfo_Locale>
         <VerInfo_Locale>1033</VerInfo_Locale>
         <DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace)</DCC_Namespace>
         <DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;$(DCC_Namespace)</DCC_Namespace>
-        <VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
+        <VerInfo_Keys>CompanyName=;FileDescription=$(MSBuildProjectName);FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProgramID=com.embarcadero.$(MSBuildProjectName);ProductName=$(MSBuildProjectName);ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
         <VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
         <VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
         <PackageImports>IndyIPClient;GLScene_Sounds_RT;frx17;fs17;GLScene_Physics_RT;GLScene_Cg_RT;bindcompfmx;GR32_RSXE3;DBXSqliteDriver;vcldbx;GLScene_Physics_RT;fmx;rtl;dbrtl;DbxClientDriver;IndySystem;TeeDB;bindcomp;inetdb;inetdbbde;vclib;DBXInterBaseDriver;DataSnapClient;DataSnapCommon;DBXOdbcDriver;DataSnapServer;Tee;GLScene_RT;DataSnapProviderClient;xmlrtl;DBXSybaseASEDriver;ibxpress;DbxCommonDriver;vclimg;GLScene_Sounds_RT;IndyProtocols;DBXMySQLDriver;dbxcds;MetropolisUILiveTile;bindengine;vclactnband;vcldb;soaprtl;bindcompdbx;vcldsnap;bindcompvcl;FMXTee;TeeUI;vclie;GR32_DSGN_RSXE3;DBXDb2Driver;vcltouch;bcbsmp;websnap;DBXOracleDriver;CustomIPTransport;vclribbon;VclSmp;dsnap;DBXInformixDriver;IndyIPServer;fmxase;vcl;DataSnapConnectors;IndyCore;GLScene_Sounds_RT;DBXMSSQLDriver;CodeSiteExpressPkg;CloudService;DBXFirebirdDriver;dsnapcon;frxDB17;inet;fsDB17;fmxobj;IndyIPCommon;FmxTeeUI;vclx;frxe17;inetdbxpress;webdsnap;DBXSybaseASADriver;fmxdae;bdertl;dbexpress;DataSnapIndy10ServerTransport;adortl;bcbie;$(PackageImports)</PackageImports>
         <PackageImports>IndyIPClient;GLScene_Sounds_RT;frx17;fs17;GLScene_Physics_RT;GLScene_Cg_RT;bindcompfmx;GR32_RSXE3;DBXSqliteDriver;vcldbx;GLScene_Physics_RT;fmx;rtl;dbrtl;DbxClientDriver;IndySystem;TeeDB;bindcomp;inetdb;inetdbbde;vclib;DBXInterBaseDriver;DataSnapClient;DataSnapCommon;DBXOdbcDriver;DataSnapServer;Tee;GLScene_RT;DataSnapProviderClient;xmlrtl;DBXSybaseASEDriver;ibxpress;DbxCommonDriver;vclimg;GLScene_Sounds_RT;IndyProtocols;DBXMySQLDriver;dbxcds;MetropolisUILiveTile;bindengine;vclactnband;vcldb;soaprtl;bindcompdbx;vcldsnap;bindcompvcl;FMXTee;TeeUI;vclie;GR32_DSGN_RSXE3;DBXDb2Driver;vcltouch;bcbsmp;websnap;DBXOracleDriver;CustomIPTransport;vclribbon;VclSmp;dsnap;DBXInformixDriver;IndyIPServer;fmxase;vcl;DataSnapConnectors;IndyCore;GLScene_Sounds_RT;DBXMSSQLDriver;CodeSiteExpressPkg;CloudService;DBXFirebirdDriver;dsnapcon;frxDB17;inet;fsDB17;fmxobj;IndyIPCommon;FmxTeeUI;vclx;frxe17;inetdbxpress;webdsnap;DBXSybaseASADriver;fmxdae;bdertl;dbexpress;DataSnapIndy10ServerTransport;adortl;bcbie;$(PackageImports)</PackageImports>
         <UWP_CppLogo44>$(BDS)\bin\Artwork\Windows\UWP\cppreg_UwpDefault_44.png</UWP_CppLogo44>
         <UWP_CppLogo44>$(BDS)\bin\Artwork\Windows\UWP\cppreg_UwpDefault_44.png</UWP_CppLogo44>
         <UWP_CppLogo150>$(BDS)\bin\Artwork\Windows\UWP\cppreg_UwpDefault_150.png</UWP_CppLogo150>
         <UWP_CppLogo150>$(BDS)\bin\Artwork\Windows\UWP\cppreg_UwpDefault_150.png</UWP_CppLogo150>
+        <BT_BuildType>Debug</BT_BuildType>
     </PropertyGroup>
     </PropertyGroup>
     <PropertyGroup Condition="'$(Cfg_1)'!=''">
     <PropertyGroup Condition="'$(Cfg_1)'!=''">
         <BCC_OptimizeForSpeed>false</BCC_OptimizeForSpeed>
         <BCC_OptimizeForSpeed>false</BCC_OptimizeForSpeed>
@@ -127,6 +128,9 @@
     </PropertyGroup>
     </PropertyGroup>
     <PropertyGroup Condition="'$(Cfg_1_Win64)'!=''">
     <PropertyGroup Condition="'$(Cfg_1_Win64)'!=''">
         <Defines>_DEBUG;$(Defines)</Defines>
         <Defines>_DEBUG;$(Defines)</Defines>
+        <AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
+        <AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
+        <LinkPackageImports>rtl.bpi;vcl.bpi;fmx.bpi;xmlrtl.bpi;vclimg.bpi;GLScene_RT.bpi</LinkPackageImports>
     </PropertyGroup>
     </PropertyGroup>
     <PropertyGroup Condition="'$(Cfg_2)'!=''">
     <PropertyGroup Condition="'$(Cfg_2)'!=''">
         <TASM_Debugging>None</TASM_Debugging>
         <TASM_Debugging>None</TASM_Debugging>
@@ -136,6 +140,8 @@
     </PropertyGroup>
     </PropertyGroup>
     <PropertyGroup Condition="'$(Cfg_2_Win64)'!=''">
     <PropertyGroup Condition="'$(Cfg_2_Win64)'!=''">
         <Defines>NDEBUG;$(Defines)</Defines>
         <Defines>NDEBUG;$(Defines)</Defines>
+        <AppEnableRuntimeThemes>true</AppEnableRuntimeThemes>
+        <AppDPIAwarenessMode>PerMonitorV2</AppDPIAwarenessMode>
     </PropertyGroup>
     </PropertyGroup>
     <ItemGroup>
     <ItemGroup>
         <CppCompile Include="MegaCube.cpp">
         <CppCompile Include="MegaCube.cpp">
@@ -225,13 +231,9 @@
                         <Overwrite>true</Overwrite>
                         <Overwrite>true</Overwrite>
                     </Platform>
                     </Platform>
                 </DeployFile>
                 </DeployFile>
-                <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'=='true'" LocalName="$(BDS)\bin\cc32c270mt.dll" Class="DependencyModule">
-                    <Platform Name="Win32">
-                        <Overwrite>true</Overwrite>
-                    </Platform>
-                </DeployFile>
-                <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'!='true'" LocalName="$(BDS)\bin\cc32c270.dll" Class="DependencyModule">
-                    <Platform Name="Win32">
+                <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'!='true'" LocalName="$(BDS)\bin\cc32230.dll" Class="DependencyModule"/>
+                <DeployFile Condition="'$(DynamicRTL)'=='true'" LocalName="$(BDS)\Redist\osx64\libcgcrtl.dylib" Class="DependencyModule">
+                    <Platform Name="OSX64">
                         <Overwrite>true</Overwrite>
                         <Overwrite>true</Overwrite>
                     </Platform>
                     </Platform>
                 </DeployFile>
                 </DeployFile>
@@ -303,9 +305,13 @@
                     </Platform>
                     </Platform>
                 </DeployFile>
                 </DeployFile>
                 <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'=='true'" LocalName="$(BDS)\bin\cc32230mt.dll" Class="DependencyModule"/>
                 <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'=='true'" LocalName="$(BDS)\bin\cc32230mt.dll" Class="DependencyModule"/>
-                <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'!='true'" LocalName="$(BDS)\bin\cc32230.dll" Class="DependencyModule"/>
-                <DeployFile Condition="'$(DynamicRTL)'=='true'" LocalName="$(BDS)\Redist\osx64\libcgcrtl.dylib" Class="DependencyModule">
-                    <Platform Name="OSX64">
+                <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'=='true'" LocalName="$(BDS)\bin\cc32c270mt.dll" Class="DependencyModule">
+                    <Platform Name="Win32">
+                        <Overwrite>true</Overwrite>
+                    </Platform>
+                </DeployFile>
+                <DeployFile Condition="'$(DynamicRTL)'=='true' And '$(Multithreaded)'!='true'" LocalName="$(BDS)\bin\cc32c270.dll" Class="DependencyModule">
+                    <Platform Name="Win32">
                         <Overwrite>true</Overwrite>
                         <Overwrite>true</Overwrite>
                     </Platform>
                     </Platform>
                 </DeployFile>
                 </DeployFile>
@@ -326,20 +332,12 @@
                         <RemoteDir>classes</RemoteDir>
                         <RemoteDir>classes</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>classes</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidFileProvider">
                 <DeployClass Name="AndroidFileProvider">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\xml</RemoteDir>
                         <RemoteDir>res\xml</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\xml</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidGDBServer">
                 <DeployClass Name="AndroidGDBServer">
                     <Platform Name="Android">
                     <Platform Name="Android">
@@ -352,10 +350,6 @@
                         <RemoteDir>library\lib\armeabi</RemoteDir>
                         <RemoteDir>library\lib\armeabi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>library\lib\armeabi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidLibnativeArmeabiv7aFile">
                 <DeployClass Name="AndroidLibnativeArmeabiv7aFile">
                     <Platform Name="Android64">
                     <Platform Name="Android64">
@@ -368,20 +362,12 @@
                         <RemoteDir>library\lib\mips</RemoteDir>
                         <RemoteDir>library\lib\mips</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>library\lib\mips</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidServiceOutput">
                 <DeployClass Name="AndroidServiceOutput">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>library\lib\armeabi-v7a</RemoteDir>
                         <RemoteDir>library\lib\armeabi-v7a</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>library\lib\arm64-v8a</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidServiceOutput_Android32">
                 <DeployClass Name="AndroidServiceOutput_Android32">
                     <Platform Name="Android64">
                     <Platform Name="Android64">
@@ -394,200 +380,120 @@
                         <RemoteDir>res\drawable</RemoteDir>
                         <RemoteDir>res\drawable</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidSplashStyles">
                 <DeployClass Name="AndroidSplashStyles">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\values</RemoteDir>
                         <RemoteDir>res\values</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\values</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="AndroidSplashStylesV21">
                 <DeployClass Name="AndroidSplashStylesV21">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\values-v21</RemoteDir>
                         <RemoteDir>res\values-v21</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\values-v21</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_Colors">
                 <DeployClass Name="Android_Colors">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\values</RemoteDir>
                         <RemoteDir>res\values</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\values</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_DefaultAppIcon">
                 <DeployClass Name="Android_DefaultAppIcon">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable</RemoteDir>
                         <RemoteDir>res\drawable</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_LauncherIcon144">
                 <DeployClass Name="Android_LauncherIcon144">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-xxhdpi</RemoteDir>
                         <RemoteDir>res\drawable-xxhdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-xxhdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_LauncherIcon36">
                 <DeployClass Name="Android_LauncherIcon36">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-ldpi</RemoteDir>
                         <RemoteDir>res\drawable-ldpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-ldpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_LauncherIcon48">
                 <DeployClass Name="Android_LauncherIcon48">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-mdpi</RemoteDir>
                         <RemoteDir>res\drawable-mdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-mdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_LauncherIcon72">
                 <DeployClass Name="Android_LauncherIcon72">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-hdpi</RemoteDir>
                         <RemoteDir>res\drawable-hdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-hdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_LauncherIcon96">
                 <DeployClass Name="Android_LauncherIcon96">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-xhdpi</RemoteDir>
                         <RemoteDir>res\drawable-xhdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-xhdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_NotificationIcon24">
                 <DeployClass Name="Android_NotificationIcon24">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-mdpi</RemoteDir>
                         <RemoteDir>res\drawable-mdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-mdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_NotificationIcon36">
                 <DeployClass Name="Android_NotificationIcon36">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-hdpi</RemoteDir>
                         <RemoteDir>res\drawable-hdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-hdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_NotificationIcon48">
                 <DeployClass Name="Android_NotificationIcon48">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-xhdpi</RemoteDir>
                         <RemoteDir>res\drawable-xhdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-xhdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_NotificationIcon72">
                 <DeployClass Name="Android_NotificationIcon72">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-xxhdpi</RemoteDir>
                         <RemoteDir>res\drawable-xxhdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-xxhdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_NotificationIcon96">
                 <DeployClass Name="Android_NotificationIcon96">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-xxxhdpi</RemoteDir>
                         <RemoteDir>res\drawable-xxxhdpi</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-xxxhdpi</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_SplashImage426">
                 <DeployClass Name="Android_SplashImage426">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-small</RemoteDir>
                         <RemoteDir>res\drawable-small</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-small</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_SplashImage470">
                 <DeployClass Name="Android_SplashImage470">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-normal</RemoteDir>
                         <RemoteDir>res\drawable-normal</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-normal</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_SplashImage640">
                 <DeployClass Name="Android_SplashImage640">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-large</RemoteDir>
                         <RemoteDir>res\drawable-large</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-large</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_SplashImage960">
                 <DeployClass Name="Android_SplashImage960">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\drawable-xlarge</RemoteDir>
                         <RemoteDir>res\drawable-xlarge</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\drawable-xlarge</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="Android_Strings">
                 <DeployClass Name="Android_Strings">
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <RemoteDir>res\values</RemoteDir>
                         <RemoteDir>res\values</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>res\values</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="DebugSymbols">
                 <DeployClass Name="DebugSymbols">
                     <Platform Name="iOSSimulator">
                     <Platform Name="iOSSimulator">
@@ -676,9 +582,6 @@
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <Operation>0</Operation>
                         <Operation>0</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <Operation>0</Operation>
-                    </Platform>
                     <Platform Name="iOSDevice32">
                     <Platform Name="iOSDevice32">
                         <Operation>0</Operation>
                         <Operation>0</Operation>
                     </Platform>
                     </Platform>
@@ -711,6 +614,17 @@
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
                 </DeployClass>
                 </DeployClass>
+                <DeployClass Name="iPad_Launch1024x768">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
                 <DeployClass Name="iPad_Launch1536">
                 <DeployClass Name="iPad_Launch1536">
                     <Platform Name="iOSDevice32">
                     <Platform Name="iOSDevice32">
                         <Operation>1</Operation>
                         <Operation>1</Operation>
@@ -722,6 +636,39 @@
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
                 </DeployClass>
                 </DeployClass>
+                <DeployClass Name="iPad_Launch1536x2048">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPad_Launch1668">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPad_Launch1668x2388">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
                 <DeployClass Name="iPad_Launch2048">
                 <DeployClass Name="iPad_Launch2048">
                     <Platform Name="iOSDevice32">
                     <Platform Name="iOSDevice32">
                         <Operation>1</Operation>
                         <Operation>1</Operation>
@@ -733,6 +680,61 @@
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
                 </DeployClass>
                 </DeployClass>
+                <DeployClass Name="iPad_Launch2048x1536">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPad_Launch2048x2732">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPad_Launch2224">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPad_Launch2388x1668">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPad_Launch2732x2048">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
                 <DeployClass Name="iPad_Launch2x">
                 <DeployClass Name="iPad_Launch2x">
                     <Platform Name="iOSDevice64">
                     <Platform Name="iOSDevice64">
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
@@ -754,6 +756,17 @@
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
                 </DeployClass>
                 </DeployClass>
+                <DeployClass Name="iPad_Launch768x1024">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
                 <DeployClass Name="iPad_LaunchDark2x">
                 <DeployClass Name="iPad_LaunchDark2x">
                     <Platform Name="iOSDevice64">
                     <Platform Name="iOSDevice64">
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
@@ -764,6 +777,105 @@
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
                 </DeployClass>
                 </DeployClass>
+                <DeployClass Name="iPhone_Launch1125">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch1136x640">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch1242">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch1242x2688">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch1334">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch1792">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch2208">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch2436">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch2688x1242">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
                 <DeployClass Name="iPhone_Launch2x">
                 <DeployClass Name="iPhone_Launch2x">
                     <Platform Name="iOSDevice64">
                     <Platform Name="iOSDevice64">
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
@@ -817,6 +929,28 @@
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
                 </DeployClass>
                 </DeployClass>
+                <DeployClass Name="iPhone_Launch750">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
+                <DeployClass Name="iPhone_Launch828">
+                    <Platform Name="iOSDevice32">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSDevice64">
+                        <Operation>1</Operation>
+                    </Platform>
+                    <Platform Name="iOSSimulator">
+                        <Operation>1</Operation>
+                    </Platform>
+                </DeployClass>
                 <DeployClass Name="iPhone_LaunchDark2x">
                 <DeployClass Name="iPhone_LaunchDark2x">
                     <Platform Name="iOSDevice64">
                     <Platform Name="iOSDevice64">
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
                         <RemoteDir>..\$(PROJECTNAME).launchscreen\Assets\LaunchScreenImage.imageset</RemoteDir>
@@ -841,9 +975,6 @@
                     <Platform Name="Android">
                     <Platform Name="Android">
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <Operation>1</Operation>
-                    </Platform>
                 </DeployClass>
                 </DeployClass>
                 <DeployClass Name="ProjectiOSDeviceDebug">
                 <DeployClass Name="ProjectiOSDeviceDebug">
                     <Platform Name="iOSDevice32">
                     <Platform Name="iOSDevice32">
@@ -946,10 +1077,6 @@
                         <RemoteDir>library\lib\armeabi-v7a</RemoteDir>
                         <RemoteDir>library\lib\armeabi-v7a</RemoteDir>
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
-                    <Platform Name="Android64">
-                        <RemoteDir>library\lib\arm64-v8a</RemoteDir>
-                        <Operation>1</Operation>
-                    </Platform>
                     <Platform Name="iOSDevice32">
                     <Platform Name="iOSDevice32">
                         <Operation>1</Operation>
                         <Operation>1</Operation>
                     </Platform>
                     </Platform>
@@ -1021,7 +1148,7 @@
             </Deployment>
             </Deployment>
             <Platforms>
             <Platforms>
                 <Platform value="Win32">True</Platform>
                 <Platform value="Win32">True</Platform>
-                <Platform value="Win64">False</Platform>
+                <Platform value="Win64">True</Platform>
             </Platforms>
             </Platforms>
         </BorlandProject>
         </BorlandProject>
         <ProjectFileVersion>12</ProjectFileVersion>
         <ProjectFileVersion>12</ProjectFileVersion>

+ 7 - 9
Demos/CPP/bench/megaglasscube/Unit1.cpp

@@ -17,16 +17,13 @@
 #pragma link "GLS.SceneViewer"
 #pragma link "GLS.SceneViewer"
 #pragma resource "*.dfm"
 #pragma resource "*.dfm"
 TForm1 *Form1;
 TForm1 *Form1;
-//---------------------------------------------------------------------------
-__fastcall TForm1::TForm1(TComponent* Owner)
-	: TForm(Owner)
-{
-}
-//---------------------------------------------------------------------------
 
 
 const int
 const int
   cSize = 10;
   cSize = 10;
-void __fastcall TForm1::FormCreate(TObject *Sender)
+
+//---------------------------------------------------------------------------
+__fastcall TForm1::TForm1(TComponent* Owner)
+	: TForm(Owner)
 {
 {
   int x, y, z;
   int x, y, z;
   TGLCube *cube;
   TGLCube *cube;
@@ -51,9 +48,10 @@ void __fastcall TForm1::FormCreate(TObject *Sender)
 	  }
 	  }
 }
 }
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
+
 void __fastcall TForm1::GLCadencer1Progress(TObject *Sender, const double deltaTime,
 void __fastcall TForm1::GLCadencer1Progress(TObject *Sender, const double deltaTime,
-          const double newTime)
+		  const double newTime)
 {
 {
- //DummyCube1->TurnAngle = 90 * newTime; // 90° per second
+  DummyCube1->TurnAngle = 90 * newTime; // 90° per second
 }
 }
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------

+ 0 - 1
Demos/CPP/bench/megaglasscube/Unit1.dfm

@@ -11,7 +11,6 @@ object Form1: TForm1
   Font.Name = 'Tahoma'
   Font.Name = 'Tahoma'
   Font.Style = []
   Font.Style = []
   OldCreateOrder = False
   OldCreateOrder = False
-  OnCreate = FormCreate
   PixelsPerInch = 96
   PixelsPerInch = 96
   TextHeight = 13
   TextHeight = 13
   object GLSceneViewer1: TGLSceneViewer
   object GLSceneViewer1: TGLSceneViewer

+ 0 - 1
Demos/CPP/bench/megaglasscube/Unit1.h

@@ -26,7 +26,6 @@ __published:	// IDE-managed Components
 	TGLCamera *GLCamera1;
 	TGLCamera *GLCamera1;
 	TGLCadencer *GLCadencer1;
 	TGLCadencer *GLCadencer1;
 	TGLSimpleNavigation *GLSimpleNavigation1;
 	TGLSimpleNavigation *GLSimpleNavigation1;
-	void __fastcall FormCreate(TObject *Sender);
 	void __fastcall GLCadencer1Progress(TObject *Sender, const double deltaTime, const double newTime);
 	void __fastcall GLCadencer1Progress(TObject *Sender, const double deltaTime, const double newTime);
 
 
 private:	// User declarations
 private:	// User declarations

+ 1 - 1
Demos/CPP/cgshaders/simple/Unit1.cpp

@@ -60,7 +60,7 @@ void __fastcall TForm1::FormCreate(TObject *Sender)
 
 
 void __fastcall TForm1::CgShader1ApplyVP(TCgProgram *CgProgram, TObject *Sender)
 void __fastcall TForm1::CgShader1ApplyVP(TCgProgram *CgProgram, TObject *Sender)
 {
 {
-  Gls::Vectorgeometry::TVector v;
+  TGLVector v;
   TCgParameter *Param;
   TCgParameter *Param;
   // rotate light vector for the "simple lighting" vertex program
   // rotate light vector for the "simple lighting" vertex program
   v = ZHmgVector;
   v = ZHmgVector;

+ 2 - 2
Demos/CPP/cgshaders/texturing/Unit1.cpp

@@ -72,7 +72,7 @@ void __fastcall TForm1::CgShader1Initialize(TCustomCgShader *CgShader)
 
 
 void __fastcall TForm1::CgShader1ApplyVP(TCgProgram *CgProgram, TObject *Sender)
 void __fastcall TForm1::CgShader1ApplyVP(TCgProgram *CgProgram, TObject *Sender)
 {
 {
-  Gls::Vectorgeometry::TVector v;
+  TGLVector v;
   CgProgram->ParamByName("ModelViewProj")->SetAsStateMatrix(CG_GL_MODELVIEW_PROJECTION_MATRIX, CG_GL_MATRIX_IDENTITY);
   CgProgram->ParamByName("ModelViewProj")->SetAsStateMatrix(CG_GL_MODELVIEW_PROJECTION_MATRIX, CG_GL_MATRIX_IDENTITY);
 // Alternatively, you can set it using:
 // Alternatively, you can set it using:
 // CgProgram->SetStateMatrix("ModelViewProj", CG_GL_MODELVIEW_PROJECTION_MATRIX, CG_GL_MATRIX_IDENTITY);
 // CgProgram->SetStateMatrix("ModelViewProj", CG_GL_MODELVIEW_PROJECTION_MATRIX, CG_GL_MATRIX_IDENTITY);
@@ -91,7 +91,7 @@ void __fastcall TForm1::CgShader1ApplyVP(TCgProgram *CgProgram, TObject *Sender)
 
 
 void __fastcall TForm1::CgShader1ApplyFP(TCgProgram *CgProgram, TObject *Sender)
 void __fastcall TForm1::CgShader1ApplyFP(TCgProgram *CgProgram, TObject *Sender)
 {
 {
-  Gls::Vectorgeometry::TVector v;
+  TGLVector v;
   CgProgram->ParamByName("Map0")->EnableTexture();
   CgProgram->ParamByName("Map0")->EnableTexture();
   CgProgram->ParamByName("Map1")->EnableTexture();
   CgProgram->ParamByName("Map1")->EnableTexture();
   CgProgram->ParamByName("Map2")->EnableTexture();
   CgProgram->ParamByName("Map2")->EnableTexture();

+ 2 - 2
Demos/CPP/collisions/Raycast/Unit1.cpp

@@ -26,8 +26,8 @@ __fastcall TForm1::TForm1(TComponent* Owner)
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
 void __fastcall TForm1::BUCastClick(TObject *Sender)
 void __fastcall TForm1::BUCastClick(TObject *Sender)
 {
 {
-   Gls::Vectorgeometry::TVector o, v, vLight, light, iPoint, iNormal;
-   Gls::Vectorgeometry::TVector up, right, dir;
+   TGLVector o, v, vLight, light, iPoint, iNormal;
+   TGLVector up, right, dir;
    int x, y, dx, dy;
    int x, y, dx, dy;
    float f, d;
    float f, d;
    TColor color;
    TColor color;

+ 4 - 4
Demos/CPP/collisions/boxedin/Unit1.cpp

@@ -59,10 +59,10 @@ void __fastcall TForm1::GLCadencer1Progress(TObject * Sender,
 											const double deltaTime,
 											const double deltaTime,
 											const double newTime)
 											const double newTime)
 {
 {
-  Gls::Vectorgeometry::TVector rayStart, rayVector;
+  TGLVector rayStart, rayVector;
   float velocity;
   float velocity;
-  Gls::Vectorgeometry::TVector pPoint;
-  Gls::Vectorgeometry::TVector pNormal;
+  TGLVector pPoint;
+  TGLVector pNormal;
   __int64 t;
   __int64 t;
 
 
   if(IsKeyDown(VK_ESCAPE))
   if(IsKeyDown(VK_ESCAPE))
@@ -111,7 +111,7 @@ void __fastcall TForm1::GLCadencer1Progress(TObject * Sender,
 
 
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
 
 
-void TForm1::AddToTrail(const Gls::Vectorgeometry::TVector & p)
+void TForm1::AddToTrail(const TGLVector & p)
 {
 {
   int i, k;
   int i, k;
   Lines1->Nodes->Last()->AsVector = p;
   Lines1->Nodes->Last()->AsVector = p;

+ 1 - 1
Demos/CPP/collisions/boxedin/Unit1.h

@@ -57,7 +57,7 @@ __published:                   // IDE-managed Components
 private:                       // User declarations
 private:                       // User declarations
   float colTotalTime;           // for timing collision detection
   float colTotalTime;           // for timing collision detection
   int colCount;
   int colCount;
-  void AddToTrail(const Gls::Vectorgeometry::TVector & p);
+  void AddToTrail(const TGLVector & p);
 public:                        // User declarations
 public:                        // User declarations
     __fastcall TForm1(TComponent * Owner);
     __fastcall TForm1(TComponent * Owner);
   int mousex, mousey;
   int mousex, mousey;

+ 1 - 1
Demos/CPP/collisions/facevsface/Unit1.cpp

@@ -161,7 +161,7 @@ void __fastcall TForm1::GLSceneViewer1MouseMove(TObject *Sender, TShiftState Shi
           int X, int Y)
           int X, int Y)
 {
 {
    int dx, dy;
    int dx, dy;
-   Gls::Vectorgeometry::TVector VX, VY;
+   TGLVector VX, VY;
    TGLCamera *Camera;
    TGLCamera *Camera;
 
 
    Camera = GLSceneViewer1->Camera;
    Camera = GLSceneViewer1->Camera;

+ 2 - 2
Demos/CPP/collisions/meshhit/Unit1.cpp

@@ -36,7 +36,7 @@ void __fastcall TForm1::FormCreate(TObject *Sender)
 void __fastcall TForm1::GLSceneViewer1MouseDown(TObject *Sender, TMouseButton Button,
 void __fastcall TForm1::GLSceneViewer1MouseDown(TObject *Sender, TMouseButton Button,
 		  TShiftState Shift, int X, int Y)
 		  TShiftState Shift, int X, int Y)
 {
 {
-   Gls::Vectorgeometry::TVector rayStart, rayVector, iPoint, iNormal;
+   TGLVector rayStart, rayVector, iPoint, iNormal;
    // retrieve raycasting data:
    // retrieve raycasting data:
    //    rayStart is obtained for camera and screen position
    //    rayStart is obtained for camera and screen position
    //    rayVector is the camera direction (i.e direction to target since our camera is targeted)
    //    rayVector is the camera direction (i.e direction to target since our camera is targeted)
@@ -71,7 +71,7 @@ void __fastcall TForm1::GLSceneViewer1MouseMove(TObject *Sender, TShiftState Shi
 void __fastcall TForm1::GLSceneViewer2MouseDown(TObject *Sender, TMouseButton Button,
 void __fastcall TForm1::GLSceneViewer2MouseDown(TObject *Sender, TMouseButton Button,
 		  TShiftState Shift, int X, int Y)
 		  TShiftState Shift, int X, int Y)
 {
 {
-   Gls::Vectorgeometry::TVector rayStart, rayVector, iPoint, iNormal;
+   TGLVector rayStart, rayVector, iPoint, iNormal;
    // retrieve raycasting data:
    // retrieve raycasting data:
    //    rayStart is the eye (camera) position
    //    rayStart is the eye (camera) position
    //    rayVector is computed from screen position
    //    rayVector is computed from screen position

+ 1 - 1
Demos/CPP/collisions/octree/Unit1.cpp

@@ -50,7 +50,7 @@ void __fastcall TForm1::GLSceneViewer2MouseDown(TObject * Sender,
 												TMouseButton Button,
 												TMouseButton Button,
 												TShiftState Shift, int X, int Y)
 												TShiftState Shift, int X, int Y)
 {
 {
-  Gls::Vectorgeometry::TVector rayStart, rayVector, iPoint, iNormal;
+  TGLVector rayStart, rayVector, iPoint, iNormal;
   __int64 t;
   __int64 t;
 
 
   SetVector(rayStart, GLCamera2->AbsolutePosition);
   SetVector(rayStart, GLCamera2->AbsolutePosition);

+ 2 - 2
Demos/CPP/graph/projection/Unit1.cpp

@@ -40,8 +40,8 @@ void __fastcall TForm1::DirectOpenGLRender(TObject *Sender, TGLRenderContextInfo
 {
 {
    int i;
    int i;
    Gls::Vectorgeometry::TMatrix mat;
    Gls::Vectorgeometry::TMatrix mat;
-   Gls::Vectorgeometry::TVector p, pProj;
-   Gls::Vectorgeometry::TVector planePoint, planeNormal;
+   TGLVector p, pProj;
+   TGLVector planePoint, planeNormal;
    THmgPlane plane;
    THmgPlane plane;
 
 
    // Here we recover our plane point and normal...
    // Here we recover our plane point and normal...

+ 5 - 5
Demos/CPP/interface/CameraController/Unit1.cpp

@@ -63,7 +63,7 @@ void __fastcall TForm1::GetInput(TButton *Sender)
   }
   }
 }
 }
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
-Gls::Vectorgeometry::TVector __fastcall TForm1::OnGetCameraPosition(
+TGLVector __fastcall TForm1::OnGetCameraPosition(
 					   TGLNavigatorSmoothChangeVector* const ASender)
 					   TGLNavigatorSmoothChangeVector* const ASender)
 {
 {
   if (ASender == FCameraSmoothAnimator_AbsPos)
   if (ASender == FCameraSmoothAnimator_AbsPos)
@@ -119,7 +119,7 @@ void __fastcall TForm1::btnZoomToDistanceClick(TObject *Sender)
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
 void __fastcall TForm1::btnOrbitToPosClick(TObject *Sender)
 void __fastcall TForm1::btnOrbitToPosClick(TObject *Sender)
 {
 {
-  Gls::Vectorgeometry::TVector lTargetPosition;
+  TGLVector lTargetPosition;
 
 
   GetInput(btnOrbitToPos);
   GetInput(btnOrbitToPos);
   lTargetPosition = dcSphere->LocalToAbsolute(PointMake(DextX, DextY, DextZ));
   lTargetPosition = dcSphere->LocalToAbsolute(PointMake(DextX, DextY, DextZ));
@@ -147,7 +147,7 @@ void __fastcall TForm1::btSmoothOrbitClick(TObject *Sender)
   float lAngle; // In radians.
   float lAngle; // In radians.
   float lTime;
   float lTime;
   bool lNeedToRecalculateZoom;
   bool lNeedToRecalculateZoom;
-  Gls::Vectorgeometry::TVector lTargetPosition;
+  TGLVector lTargetPosition;
 
 
   GetInput(btSmoothOrbit);
   GetInput(btSmoothOrbit);
   lTargetPosition = dcSphere->LocalToAbsolute(PointMake(DextX, DextY, DextZ));
   lTargetPosition = dcSphere->LocalToAbsolute(PointMake(DextX, DextY, DextZ));
@@ -178,7 +178,7 @@ void __fastcall TForm1::btSmoothOrbitToPosAdvClick(TObject *Sender)
 {
 {
   float lAngle; // In radians.
   float lAngle; // In radians.
   float lTime;
   float lTime;
-  Gls::Vectorgeometry::TVector lTargetPosition;
+  TGLVector lTargetPosition;
 
 
   GetInput(btSmoothOrbitToPosAdv);
   GetInput(btSmoothOrbitToPosAdv);
 
 
@@ -199,7 +199,7 @@ void __fastcall TForm1::btSmoothOrbitToPosAdvClick(TObject *Sender)
 
 
 void __fastcall TForm1::btnOrbitToPosAdvClick(TObject *Sender)
 void __fastcall TForm1::btnOrbitToPosAdvClick(TObject *Sender)
 {
 {
-  Gls::Vectorgeometry::TVector lTargetPosition;
+  TGLVector lTargetPosition;
 
 
   GetInput(btnOrbitToPosAdv);
   GetInput(btnOrbitToPosAdv);
   lTargetPosition = dcSphere->LocalToAbsolute(PointMake(DextX, DextY, DextZ));
   lTargetPosition = dcSphere->LocalToAbsolute(PointMake(DextX, DextY, DextZ));

+ 1 - 1
Demos/CPP/interface/CameraController/Unit1.h

@@ -135,7 +135,7 @@ private:	// User declarations
 	void __fastcall GetInput(TButton *Sender);
 	void __fastcall GetInput(TButton *Sender);
 	TVector4f __fastcall(__closure *TGLNavigatorSmoothChangeVectorGetEvent)
 	TVector4f __fastcall(__closure *TGLNavigatorSmoothChangeVectorGetEvent)
 		(TGLNavigatorSmoothChangeVector* const ASender);
 		(TGLNavigatorSmoothChangeVector* const ASender);
-	Gls::Vectorgeometry::TVector __fastcall OnGetCameraPosition(
+	TGLVector __fastcall OnGetCameraPosition(
 					   TGLNavigatorSmoothChangeVector* const ASender);
 					   TGLNavigatorSmoothChangeVector* const ASender);
 	void __fastcall OnSetCameraPosition(TGLNavigatorSmoothChangeVector* const ASender,
 	void __fastcall OnSetCameraPosition(TGLNavigatorSmoothChangeVector* const ASender,
 					   const TVector4f &AValue);
 					   const TVector4f &AValue);

+ 2 - 2
Demos/CPP/interface/GizmoEx/Unit1.h

@@ -142,9 +142,9 @@ __published:	// IDE-managed Components
 
 
 private:	// User declarations
 private:	// User declarations
 	int mx, my;
 	int mx, my;
-	Gls::Vectorgeometry::TVector MousePos,LostMousePos;
+	TGLVector MousePos,LostMousePos;
 	bool MouseMoving;
 	bool MouseMoving;
-	Gls::Vectorgeometry::TVector pos;
+	TGLVector pos;
 	TGLBaseSceneObject *FObj;
 	TGLBaseSceneObject *FObj;
 	TGLGizmoEx *Gizmo;
 	TGLGizmoEx *Gizmo;
 	float FVectorLength;
 	float FVectorLength;

+ 1 - 1
Demos/CPP/interface/camera/Unit1.cpp

@@ -85,7 +85,7 @@ void __fastcall TForm1::GLSceneViewer1MouseMove(TObject *Sender, TShiftState Shi
           int X, int Y)
           int X, int Y)
 {
 {
 	int dx, dy;
 	int dx, dy;
-	Gls::Vectorgeometry::TVector v;
+	TGLVector v;
 
 
 	// calculate delta since last move or last mousedown
 	// calculate delta since last move or last mousedown
 	dx = mdx-X; dy = mdy-Y;
 	dx = mdx-X; dy = mdy-Y;

+ 4 - 4
Demos/CPP/meshes/actorproxy/Unit1.cpp

@@ -69,10 +69,10 @@ void __fastcall TForm1::GLSceneViewer1MouseMove(TObject *Sender, TShiftState Shi
 
 
 void __fastcall TForm1::DoRaycastStuff()
 void __fastcall TForm1::DoRaycastStuff()
 {
 {
-   Gls::Vectorgeometry::TVector rayStart;
-   Gls::Vectorgeometry::TVector rayVector;
-   Gls::Vectorgeometry::TVector iPoint;
-   Gls::Vectorgeometry::TVector iNormal;
+   TGLVector rayStart;
+   TGLVector rayVector;
+   TGLVector iPoint;
+   TGLVector iNormal;
 
 
    SetVector(rayStart, GLCamera1->AbsolutePosition);
    SetVector(rayStart, GLCamera1->AbsolutePosition);
    SetVector(rayVector, GLSceneViewer1->Buffer->ScreenToVector(
    SetVector(rayVector, GLSceneViewer1->Buffer->ScreenToVector(

+ 1 - 1
Demos/CPP/meshes/actortwocam/Unit1.cpp

@@ -47,7 +47,7 @@ void __fastcall TForm1::AddMushrooms()
 {
 {
    int i;
    int i;
    TGLProxyObject *proxy;
    TGLProxyObject *proxy;
-   Gls::Vectorgeometry::TVector s;
+   TGLVector s;
    float f;
    float f;
 
 
    // spawn some more mushrooms using proxy objects
    // spawn some more mushrooms using proxy objects

+ 1 - 1
Demos/CPP/meshes/mushroom/Unit1.cpp

@@ -49,7 +49,7 @@ void __fastcall TForm1::AddMushRooms()
 {
 {
    int i;
    int i;
    TGLProxyObject *proxy;
    TGLProxyObject *proxy;
-   Gls::Vectorgeometry::TVector s;
+   TGLVector s;
    float f;
    float f;
 
 
    // spawn some more mushrooms using proxy objects
    // spawn some more mushrooms using proxy objects

+ 1 - 1
Demos/CPP/meshes/shadedterrain/Unit1.cpp

@@ -57,7 +57,7 @@ void __fastcall TForm1::GLBumpmapHDS1NewTilePrepared(TGLBumpmapHDS * Sender,
 													 TGLLibMaterial *
 													 TGLLibMaterial *
 													 normalMapMaterial)
 													 normalMapMaterial)
 {
 {
-  Gls::Vectorgeometry::TVector n;
+  TGLVector n;
 
 
   heightData->MaterialName = normalMapMaterial->Name;
   heightData->MaterialName = normalMapMaterial->Name;
   normalMapMaterial->Texture2Name = "contrast";
   normalMapMaterial->Texture2Name = "contrast";

+ 1 - 1
Demos/CPP/meshes/terrain/Unit1.cpp

@@ -267,7 +267,7 @@ void __fastcall TForm1::FormKeyPress(TObject * Sender, char &Key)
 
 
 void __fastcall TForm1::TISoundTimer(TObject * Sender)
 void __fastcall TForm1::TISoundTimer(TObject * Sender)
 {
 {
-  Gls::Vectorgeometry::TVector wolfPos;
+  TGLVector wolfPos;
   float c, s;
   float c, s;
   TGLBSoundEmitter *be;
   TGLBSoundEmitter *be;
 
 

+ 1 - 1
Demos/CPP/movements/objmove/Objmove.cpp

@@ -1,5 +1,5 @@
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
-
+// Based on
 #include <vcl.h>
 #include <vcl.h>
 #pragma hdrstop
 #pragma hdrstop
 #include <tchar.h>
 #include <tchar.h>

+ 6 - 4
Demos/CPP/movements/objmove/Unit1.cpp

@@ -17,6 +17,8 @@
 #pragma link "GLS.SpaceText"
 #pragma link "GLS.SpaceText"
 #pragma link "GLS.SceneViewer"
 #pragma link "GLS.SceneViewer"
 #pragma link "GLS.WindowsFont"
 #pragma link "GLS.WindowsFont"
+#pragma link "GLS.Navigator"
+#pragma link "GLS.SmoothNavigator"
 #pragma resource "*.dfm"
 #pragma resource "*.dfm"
 TForm1 *Form1;
 TForm1 *Form1;
 
 
@@ -35,10 +37,10 @@ void __fastcall TForm1::FormCreate(TObject *Sender)
   UpdateHudText();
   UpdateHudText();
 }
 }
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
-Gls::Vectorgeometry::TVector __fastcall TForm1::MouseWorldPos(int X, int Y)
+TGLVector __fastcall TForm1::MouseWorldPos(int X, int Y)
 {
 {
-  Gls::Vectorgeometry::TVector v;
-  Gls::Vectorgeometry::TVector Result;
+  TGLVector v;
+  TGLVector Result;
 
 
   Y = Scn->Height - Y;
   Y = Scn->Height - Y;
   if (CurrentPick)
   if (CurrentPick)
@@ -131,7 +133,7 @@ void __fastcall TForm1::ScnMouseDown(TObject *Sender, TMouseButton Button, TShif
 void __fastcall TForm1::ScnMouseMove(TObject *Sender, TShiftState Shift, int X, int Y)
 void __fastcall TForm1::ScnMouseMove(TObject *Sender, TShiftState Shift, int X, int Y)
 
 
 {
 {
-  Gls::Vectorgeometry::TVector newPos;
+  TGLVector newPos;
 
 
   ScnMouseMoveCnt++;
   ScnMouseMoveCnt++;
 ////not translated  Assert(ScnMouseMoveCnt < 2);
 ////not translated  Assert(ScnMouseMoveCnt < 2);

+ 30 - 31
Demos/CPP/movements/objmove/Unit1.dfm

@@ -21,73 +21,58 @@ object Form1: TForm1
     Left = 161
     Left = 161
     Top = 0
     Top = 0
     Width = 387
     Width = 387
-    Height = 452
+    Height = 433
     Camera = GLCamera1
     Camera = GLCamera1
     Buffer.BackgroundColor = clBackground
     Buffer.BackgroundColor = clBackground
     FieldOfView = 51.630752563476560000
     FieldOfView = 51.630752563476560000
+    PenAsTouch = False
     Align = alClient
     Align = alClient
     OnMouseDown = ScnMouseDown
     OnMouseDown = ScnMouseDown
     OnMouseMove = ScnMouseMove
     OnMouseMove = ScnMouseMove
     TabOrder = 0
     TabOrder = 0
+    ExplicitHeight = 452
   end
   end
   object Panel1: TPanel
   object Panel1: TPanel
     Left = 0
     Left = 0
     Top = 0
     Top = 0
     Width = 161
     Width = 161
-    Height = 452
+    Height = 433
     Align = alLeft
     Align = alLeft
     BevelOuter = bvNone
     BevelOuter = bvNone
     TabOrder = 1
     TabOrder = 1
-    ExplicitHeight = 407
+    ExplicitHeight = 452
     object Label2: TLabel
     object Label2: TLabel
-      Left = 0
-      Top = 26
-      Width = 158
-      Height = 26
-      Align = alTop
-      Caption = 'Select and move with the mouse any of the two cubes.'
-      ShowAccelChar = False
-      WordWrap = True
-    end
-    object Label1: TLabel
       Left = 0
       Left = 0
       Top = 0
       Top = 0
-      Width = 114
-      Height = 13
+      Width = 161
+      Height = 26
       Align = alTop
       Align = alTop
-      Caption = 'Author: Rado Stoyanov'
+      Caption = 'Select and move with the mouse any of the cubes.'
       ShowAccelChar = False
       ShowAccelChar = False
       WordWrap = True
       WordWrap = True
+      ExplicitWidth = 158
     end
     end
     object Label3: TLabel
     object Label3: TLabel
       Left = 0
       Left = 0
-      Top = 52
-      Width = 150
+      Top = 26
+      Width = 161
       Height = 26
       Height = 26
       Align = alTop
       Align = alTop
       Caption = 'Default movement is on the XY plane.'
       Caption = 'Default movement is on the XY plane.'
       ShowAccelChar = False
       ShowAccelChar = False
       WordWrap = True
       WordWrap = True
+      ExplicitWidth = 150
     end
     end
     object Label4: TLabel
     object Label4: TLabel
       Left = 0
       Left = 0
-      Top = 78
-      Width = 145
+      Top = 52
+      Width = 161
       Height = 26
       Height = 26
       Align = alTop
       Align = alTop
       Caption = 'Shift + Drag moves on the XZ plane.'
       Caption = 'Shift + Drag moves on the XZ plane.'
       ShowAccelChar = False
       ShowAccelChar = False
       WordWrap = True
       WordWrap = True
-    end
-    object Label5: TLabel
-      Left = 0
-      Top = 13
-      Width = 142
-      Height = 13
-      Align = alTop
-      Caption = '[email protected]'
-      ShowAccelChar = False
-      WordWrap = True
+      ExplicitWidth = 145
     end
     end
     object Button1: TButton
     object Button1: TButton
       Left = 618
       Left = 618
@@ -99,7 +84,7 @@ object Form1: TForm1
     end
     end
     object GroupBox1: TGroupBox
     object GroupBox1: TGroupBox
       Left = 0
       Left = 0
-      Top = 104
+      Top = 78
       Width = 161
       Width = 161
       Height = 43
       Height = 43
       Align = alTop
       Align = alTop
@@ -116,6 +101,16 @@ object Form1: TForm1
       end
       end
     end
     end
   end
   end
+  object StatusBar: TStatusBar
+    Left = 0
+    Top = 433
+    Width = 548
+    Height = 19
+    Panels = <>
+    ExplicitLeft = 304
+    ExplicitTop = -16
+    ExplicitWidth = 0
+  end
   object GLScene1: TGLScene
   object GLScene1: TGLScene
     Left = 296
     Left = 296
     Top = 8
     Top = 8
@@ -260,4 +255,8 @@ object Form1: TForm1
     Left = 400
     Left = 400
     Top = 8
     Top = 8
   end
   end
+  object GLSmoothNavigator1: TGLSmoothNavigator
+    Left = 400
+    Top = 64
+  end
 end
 end

+ 7 - 4
Demos/CPP/movements/objmove/Unit1.h

@@ -29,6 +29,9 @@
 #include "GLS.BitmapFont.hpp"
 #include "GLS.BitmapFont.hpp"
 #include "GLS.WindowsFont.hpp"
 #include "GLS.WindowsFont.hpp"
 #include "GLS.HUDObjects.hpp"
 #include "GLS.HUDObjects.hpp"
+#include <Vcl.ComCtrls.hpp>
+#include "GLS.Navigator.hpp"
+#include "GLS.SmoothNavigator.hpp"
 
 
 //---------------------------------------------------------------------------
 //---------------------------------------------------------------------------
 class TForm1 : public TForm
 class TForm1 : public TForm
@@ -37,10 +40,8 @@ __published:	// IDE-managed Components
 	TGLSceneViewer *Scn;
 	TGLSceneViewer *Scn;
 	TPanel *Panel1;
 	TPanel *Panel1;
 	TLabel *Label2;
 	TLabel *Label2;
-	TLabel *Label1;
 	TLabel *Label3;
 	TLabel *Label3;
 	TLabel *Label4;
 	TLabel *Label4;
-	TLabel *Label5;
 	TButton *Button1;
 	TButton *Button1;
 	TGroupBox *GroupBox1;
 	TGroupBox *GroupBox1;
 	TCheckBox *ShowAxes;
 	TCheckBox *ShowAxes;
@@ -60,6 +61,8 @@ __published:	// IDE-managed Components
 	TGLHUDText *TopText;
 	TGLHUDText *TopText;
 	TGLHUDText *ObjText;
 	TGLHUDText *ObjText;
 	TGLWindowsBitmapFont *GLWindowsBitmapFont1;
 	TGLWindowsBitmapFont *GLWindowsBitmapFont1;
+	TStatusBar *StatusBar;
+	TGLSmoothNavigator *GLSmoothNavigator1;
 	void __fastcall FormCreate(TObject *Sender);
 	void __fastcall FormCreate(TObject *Sender);
 	void __fastcall ScnMouseDown(TObject *Sender, TMouseButton Button, TShiftState Shift,
 	void __fastcall ScnMouseDown(TObject *Sender, TMouseButton Button, TShiftState Shift,
           int X, int Y);
           int X, int Y);
@@ -71,11 +74,11 @@ __published:	// IDE-managed Components
 	void __fastcall FormKeyUp(TObject *Sender, WORD &Key, TShiftState Shift);
 	void __fastcall FormKeyUp(TObject *Sender, WORD &Key, TShiftState Shift);
 
 
 private:	// User declarations
 private:	// User declarations
-	Gls::Vectorgeometry::TVector lastMouseWorldPos;
+	TGLVector lastMouseWorldPos;
 	bool movingOnZ;
 	bool movingOnZ;
 	TGLCustomSceneObject *CurrentPick;
 	TGLCustomSceneObject *CurrentPick;
 	int ScnMouseMoveCnt;
 	int ScnMouseMoveCnt;
-	Gls::Vectorgeometry::TVector __fastcall MouseWorldPos(int X, int Y);
+	TGLVector __fastcall MouseWorldPos(int X, int Y);
 	void __fastcall UpdateHudText();
 	void __fastcall UpdateHudText();
 	void __fastcall ProcessPick(TGLBaseSceneObject* pick);
 	void __fastcall ProcessPick(TGLBaseSceneObject* pick);
 public:		// User declarations
 public:		// User declarations

+ 1 - 1
Demos/CPP/movements/pong/Unit1.cpp

@@ -67,7 +67,7 @@ const float
 void __fastcall TForm1::GLCadencer1Progress(TObject *Sender, const double deltaTime,
 void __fastcall TForm1::GLCadencer1Progress(TObject *Sender, const double deltaTime,
 		  const double newTime)
 		  const double newTime)
 {
 {
-	Gls::Vectorgeometry::TVector newBallPos;
+	TGLVector newBallPos;
 	// gameOver is True as soon as the ball is behind the pad, but we don't end
 	// gameOver is True as soon as the ball is behind the pad, but we don't end
 	// the game immediately so the user can realize he has lost
 	// the game immediately so the user can realize he has lost
 	if ((!gameOver) && (deltaTime>0))
 	if ((!gameOver) && (deltaTime>0))

+ 2 - 2
Demos/CPP/physics/NewtonDensity/Unit1.cpp

@@ -30,7 +30,7 @@ int __cdecl BuoyancyPlaneCallback(const int collisionID, void *context,
   const PNGDFloat globalSpaceMatrix, PNGDFloat globalSpacePlane)
   const PNGDFloat globalSpaceMatrix, PNGDFloat globalSpacePlane)
 {
 {
   Gls::Vectorgeometry::TMatrix *BodyMatrix;
   Gls::Vectorgeometry::TMatrix *BodyMatrix;
-  Gls::Vectorgeometry::TVector PlaneEquation;
+  TGLVector PlaneEquation;
   Gls::Vectorgeometry::PVector pv;
   Gls::Vectorgeometry::PVector pv;
   TForm1 *MyForm;
   TForm1 *MyForm;
 
 
@@ -107,7 +107,7 @@ void __fastcall TForm1::GLSceneViewer1MouseDown(TObject *Sender, TMouseButton Bu
 void TForm1::MyForceAndTorqueDensity(const PNewtonBody cbody,
 void TForm1::MyForceAndTorqueDensity(const PNewtonBody cbody,
 	  NGDFloat timestep, int threadIndex)
 	  NGDFloat timestep, int threadIndex)
 {
 {
-  Gls::Vectorgeometry::TVector worldGravity;
+  TGLVector worldGravity;
   TGLNGDDynamic  *NGDDyn;
   TGLNGDDynamic  *NGDDyn;
   float fluidDensity, fluidLinearViscosity, fluidAngularViscosity;
   float fluidDensity, fluidLinearViscosity, fluidAngularViscosity;
 
 

+ 2 - 2
Demos/CPP/physics/OdeConveyor/Unit1.h

@@ -62,8 +62,8 @@ __published:	// IDE-managed Components
 	void __fastcall FrictionChange(TObject *Sender);
 	void __fastcall FrictionChange(TObject *Sender);
 
 
 private:	// User declarations
 private:	// User declarations
-	Gls::Vectorgeometry::TVector FUserDirection;
-	Gls::Vectorgeometry::TVector FDirectionVector;
+	TGLVector FUserDirection;
+	TGLVector FDirectionVector;
 
 
 public:		// User declarations
 public:		// User declarations
 	__fastcall TForm1(TComponent* Owner);
 	__fastcall TForm1(TComponent* Owner);

+ 1 - 1
Demos/CPP/specialsFX/waterplane/Unit1.cpp

@@ -15,7 +15,7 @@ TForm1 *Form1;
 
 
 void TForm1::ClickWater(int x, int y)
 void TForm1::ClickWater(int x, int y)
 {
 {
-  Gls::Vectorgeometry::TVector ip;
+  TGLVector ip;
   // create a ripple in the pond on a right-mousebutton click
   // create a ripple in the pond on a right-mousebutton click
   GLSceneViewer1->Buffer->
   GLSceneViewer1->Buffer->
     ScreenVectorIntersectWithPlaneXZ(VectorMake
     ScreenVectorIntersectWithPlaneXZ(VectorMake

+ 2 - 2
Demos/CPP/sprites/imposter/Unit1.cpp

@@ -96,8 +96,8 @@ void __fastcall TForm1::GLDirectOpenGL1Render(TObject *Sender, TGLRenderContextI
 
 
 {
 {
    int x, y;
    int x, y;
-   Gls::Vectorgeometry::TVector camPos;
-   Gls::Vectorgeometry::TVector pos;
+   TGLVector camPos;
+   TGLVector pos;
 
 
 /*   to do
 /*   to do
    TImposter *imp;
    TImposter *imp;

+ 1 - 1
Demos/CleanDemos.bat

@@ -57,7 +57,7 @@ attrib +R "AdvDemos/Q3Demo/Model/animation.cfg"
 rem del *.cfg /s  - there are quake's animations
 rem del *.cfg /s  - there are quake's animations
 attrib -R "AdvDemos/Q3Demo/Model/animation.cfg"
 attrib -R "AdvDemos/Q3Demo/Model/animation.cfg"
 
 
-del *.res /s
+rem del *.res /s
 rem del *.ico /s  - some projects have own icos
 rem del *.ico /s  - some projects have own icos
 rem del *.cur /s  - cursors
 rem del *.cur /s  - cursors
 rem del *.obj /s  - obj models and resources for lazarus
 rem del *.obj /s  - obj models and resources for lazarus

+ 1 - 1
Demos/Delphi/bench/CanvasFm.dfm

@@ -16,7 +16,7 @@ object FormCanvas: TFormCanvas
   TextHeight = 13
   TextHeight = 13
   object PaintBox: TPaintBox
   object PaintBox: TPaintBox
     Left = 272
     Left = 272
-    Top = 64
+    Top = 65
     Width = 256
     Width = 256
     Height = 256
     Height = 256
   end
   end

+ 1 - 1
Demos/Delphi/cgshaders/CgSimpleFm.pas

@@ -153,7 +153,7 @@ end;
 
 
 procedure TFormCgSimple.CgShader1ApplyVP(CgProgram: TCgProgram; Sender: TObject);
 procedure TFormCgSimple.CgShader1ApplyVP(CgProgram: TCgProgram; Sender: TObject);
 var
 var
-  v : TVector;
+  v : TGLVector;
   Param: TCgParameter;
   Param: TCgParameter;
 begin
 begin
   // rotate light vector for the "simple lighting" vertex program
   // rotate light vector for the "simple lighting" vertex program

+ 2 - 2
Demos/Delphi/cgshaders/CgTextureFm.pas

@@ -195,7 +195,7 @@ end;
 procedure TFormCgTexture.CgShader1ApplyVP(CgProgram: TCgProgram; Sender: TObject);
 procedure TFormCgTexture.CgShader1ApplyVP(CgProgram: TCgProgram; Sender: TObject);
 
 
 var
 var
-  v: TVector;
+  v: TGLVector;
 
 
   function conv(TrackBar: TTrackBar): single;
   function conv(TrackBar: TTrackBar): single;
   var
   var
@@ -219,7 +219,7 @@ end;
 
 
 procedure TFormCgTexture.CgShader1ApplyFP(CgProgram: TCgProgram; Sender: TObject);
 procedure TFormCgTexture.CgShader1ApplyFP(CgProgram: TCgProgram; Sender: TObject);
 var
 var
-  v: TVector;
+  v: TGLVector;
 
 
   function conv(TrackBar: TTrackBar): single;
   function conv(TrackBar: TTrackBar): single;
   var
   var

+ 1 - 1
Demos/Delphi/glslshaders/OceanFm.pas

@@ -166,7 +166,7 @@ end;
 procedure TForm1.GLUserShader1DoApply(Sender: TObject;
 procedure TForm1.GLUserShader1DoApply(Sender: TObject;
   var rci: TGLRenderContextInfo);
   var rci: TGLRenderContextInfo);
 var
 var
-  camPos: TVector;
+  camPos: TGLVector;
 begin
 begin
   programObject.UseProgramObject;
   programObject.UseProgramObject;
 
 

+ 2 - 2
Demos/Delphi/graph/ProjectionFm.pas

@@ -74,8 +74,8 @@ procedure TFormProjection.DirectOpenGLRender(Sender: TObject; var rci: TGLRender
 var
 var
   i: Integer;
   i: Integer;
   mat: TMatrix;
   mat: TMatrix;
-  p, pProj: TVector;
-  planePoint, planeNormal: TVector;
+  p, pProj: TGLVector;
+  planePoint, planeNormal: TGLVector;
   plane: THmgPlane;
   plane: THmgPlane;
 begin
 begin
   // Here we recover our plane point and normal...
   // Here we recover our plane point and normal...

+ 8 - 8
Demos/Delphi/interface/CameraControllerFm.pas

@@ -146,8 +146,8 @@ type
     FCameraSmoothAnimator_AbsPos: TGLNavigatorSmoothChangeVector;
     FCameraSmoothAnimator_AbsPos: TGLNavigatorSmoothChangeVector;
     FCameraSmoothAnimator_RelPos: TGLNavigatorSmoothChangeVector;
     FCameraSmoothAnimator_RelPos: TGLNavigatorSmoothChangeVector;
     procedure GetInput(Sender:TButton);
     procedure GetInput(Sender:TButton);
-    function OnGetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector): TVector;
-    procedure OnSetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector; const AValue: TVector);
+    function OnGetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector): TGLVector;
+    procedure OnSetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector; const AValue: TGLVector);
   public
   public
 end;
 end;
 
 
@@ -195,7 +195,7 @@ begin
   end;
   end;
 end;
 end;
 
 
-function TForm1.OnGetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector): TVector;
+function TForm1.OnGetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector): TGLVector;
 begin
 begin
   if ASender = FCameraSmoothAnimator_AbsPos then
   if ASender = FCameraSmoothAnimator_AbsPos then
     Result := GLCamera.AbsolutePosition
     Result := GLCamera.AbsolutePosition
@@ -203,7 +203,7 @@ begin
     Result := GLCamera.Position.DirectVector;
     Result := GLCamera.Position.DirectVector;
 end;
 end;
 
 
-procedure TForm1.OnSetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector; const AValue: TVector);
+procedure TForm1.OnSetCameraPosition(const ASender: TGLNavigatorSmoothChangeVector; const AValue: TGLVector);
 begin
 begin
   if ASender = FCameraSmoothAnimator_AbsPos then
   if ASender = FCameraSmoothAnimator_AbsPos then
     GLCamera.AbsolutePosition := AValue
     GLCamera.AbsolutePosition := AValue
@@ -248,7 +248,7 @@ end;
 //OrbitToPos Usage
 //OrbitToPos Usage
 procedure TForm1.btnOrbitToPosClick(Sender: TObject);
 procedure TForm1.btnOrbitToPosClick(Sender: TObject);
 var
 var
-  lTargetPosition: TVector;
+  lTargetPosition: TGLVector;
 begin
 begin
   GetInput(TButton(Sender));
   GetInput(TButton(Sender));
   lTargetPosition := dcSphere.LocalToAbsolute(PointMake(DextX, DextY, DextZ));
   lTargetPosition := dcSphere.LocalToAbsolute(PointMake(DextX, DextY, DextZ));
@@ -258,7 +258,7 @@ end;
 
 
 procedure TForm1.btnOrbitToPosAdvClick(Sender: TObject);
 procedure TForm1.btnOrbitToPosAdvClick(Sender: TObject);
 var
 var
-  lTargetPosition: TVector;
+  lTargetPosition: TGLVector;
 begin
 begin
   GetInput(TButton(Sender));
   GetInput(TButton(Sender));
   lTargetPosition := dcSphere.LocalToAbsolute(PointMake(DextX, DextY, DextZ));
   lTargetPosition := dcSphere.LocalToAbsolute(PointMake(DextX, DextY, DextZ));
@@ -355,7 +355,7 @@ var
   lAngle: Single; // In radians.
   lAngle: Single; // In radians.
   lTime: Single;
   lTime: Single;
   lNeedToRecalculateZoom: Boolean;
   lNeedToRecalculateZoom: Boolean;
-  lTargetPosition: TVector;
+  lTargetPosition: TGLVector;
 begin
 begin
   GetInput(TButton(Sender));
   GetInput(TButton(Sender));
 
 
@@ -393,7 +393,7 @@ procedure TForm1.btSmoothOrbitToPosAdvClick(Sender: TObject);
 var
 var
   lAngle: Single; // In radians.
   lAngle: Single; // In radians.
   lTime: Single;
   lTime: Single;
-  lTargetPosition: TVector;
+  lTargetPosition: TGLVector;
 begin
 begin
   GetInput(TButton(Sender));
   GetInput(TButton(Sender));
 
 

+ 1 - 1
Demos/Delphi/interface/CameraFm.pas

@@ -74,7 +74,7 @@ procedure TFormCamera.GLSceneViewer1MouseMove(Sender: TObject;
   Shift: TShiftState; X, Y: Integer);
   Shift: TShiftState; X, Y: Integer);
 var
 var
   dx, dy: Integer;
   dx, dy: Integer;
-  v: TVector;
+  v: TGLVector;
 begin
 begin
   // calculate delta since last move or last mousedown
   // calculate delta since last move or last mousedown
   dx := mdx - X;
   dx := mdx - X;

+ 6 - 6
Demos/Delphi/interface/GizmoexFm.pas

@@ -159,7 +159,7 @@ type
     procedure FormKeyUp(Sender: TObject; var Key: Word; Shift: TShiftState);
     procedure FormKeyUp(Sender: TObject; var Key: Word; Shift: TShiftState);
     procedure SpeedButton1Click(Sender: TObject);
     procedure SpeedButton1Click(Sender: TObject);
     procedure ComboBox3Change(Sender: TObject);
     procedure ComboBox3Change(Sender: TObject);
-    function MouseWorldPos(const X, Y: Integer; isy: boolean = false): TVector;
+    function MouseWorldPos(const X, Y: Integer; isy: boolean = false): TGLVector;
     procedure ComboBox4Change(Sender: TObject);
     procedure ComboBox4Change(Sender: TObject);
     procedure SpeedButton6MouseDown(Sender: TObject; Button: TMouseButton;
     procedure SpeedButton6MouseDown(Sender: TObject; Button: TMouseButton;
       Shift: TShiftState; X, Y: Integer);
       Shift: TShiftState; X, Y: Integer);
@@ -175,9 +175,9 @@ type
   public
   public
      
      
     mx, my: Integer;
     mx, my: Integer;
-    MousePos,LostMousePos: TVector;
+    MousePos,LostMousePos: TGLVector;
     MouseMoving: boolean;
     MouseMoving: boolean;
-    pos: TVector;
+    pos: TGLVector;
     FObj: TGLBaseSceneObject;
     FObj: TGLBaseSceneObject;
     procedure UpdateTreeView;
     procedure UpdateTreeView;
   end;
   end;
@@ -192,7 +192,7 @@ implementation
 
 
 {$R *.dfm}
 {$R *.dfm}
 
 
-procedure SettingsObj(Obj: TGLBaseSceneObject; Step: Integer; Length: TVector);
+procedure SettingsObj(Obj: TGLBaseSceneObject; Step: Integer; Length: TGLVector);
 begin
 begin
   if (Obj is TGLCube) then
   if (Obj is TGLCube) then
   with (Obj as TGLCube) do
   with (Obj as TGLCube) do
@@ -238,9 +238,9 @@ begin
    end;
    end;
 end;
 end;
 
 
-function TFormGizmoEx.MouseWorldPos(const X, Y: Integer; isy: boolean = false): TVector;
+function TFormGizmoEx.MouseWorldPos(const X, Y: Integer; isy: boolean = false): TGLVector;
 var
 var
-  v: TVector;
+  v: TGLVector;
   InvertedY: Integer;
   InvertedY: Integer;
 begin
 begin
   InvertedY := Viewer.Height - Y;
   InvertedY := Viewer.Height - Y;

+ 1 - 1
Demos/Delphi/meshes/ActorProxyFm.pas

@@ -112,7 +112,7 @@ end;
 
 
 procedure TFormActorProxy.DoRaycastStuff;
 procedure TFormActorProxy.DoRaycastStuff;
 var
 var
-   rayStart, rayVector, iPoint, iNormal : TVector;
+   rayStart, rayVector, iPoint, iNormal : TGLVector;
 begin
 begin
      SetVector(rayStart, GLCamera1.AbsolutePosition);
      SetVector(rayStart, GLCamera1.AbsolutePosition);
      SetVector(rayVector, GLSceneViewer1.Buffer.ScreenToVector(
      SetVector(rayVector, GLSceneViewer1.Buffer.ScreenToVector(

+ 1 - 1
Demos/Delphi/meshes/ActorTwocamFm.pas

@@ -215,7 +215,7 @@ procedure TFormActorTwocam.AddMushrooms;
 var
 var
    i : Integer;
    i : Integer;
    proxy : TGLProxyObject;
    proxy : TGLProxyObject;
-   s : TVector;
+   s : TGLVector;
    f : Single;
    f : Single;
 begin
 begin
    // spawn some more mushrooms using proxy objects
    // spawn some more mushrooms using proxy objects

+ 1 - 1
Demos/Delphi/meshes/MushroomFm.pas

@@ -86,7 +86,7 @@ procedure TFormMushroom.AddMushrooms;
 var
 var
    i : Integer;
    i : Integer;
    proxy : TGLProxyObject;
    proxy : TGLProxyObject;
-   s : TVector;
+   s : TGLVector;
    f : Single;
    f : Single;
 begin
 begin
    // spawn some more mushrooms using proxy objects
    // spawn some more mushrooms using proxy objects

+ 1 - 1
Demos/Delphi/meshes/ShadedTerrainFm.pas

@@ -146,7 +146,7 @@ end;
 procedure TFormShadedTerrain.GLBumpmapHDS1NewTilePrepared(Sender: TGLBumpmapHDS;
 procedure TFormShadedTerrain.GLBumpmapHDS1NewTilePrepared(Sender: TGLBumpmapHDS;
   heightData: TGLHeightData; normalMapMaterial: TGLLibMaterial);
   heightData: TGLHeightData; normalMapMaterial: TGLLibMaterial);
 var
 var
-  Vec: TVector;
+  Vec: TGLVector;
 begin
 begin
   heightData.MaterialName := normalMapMaterial.Name;
   heightData.MaterialName := normalMapMaterial.Name;
   normalMapMaterial.Texture2Name := 'contrast';//'details', 'texture' or 'contrast';
   normalMapMaterial.Texture2Name := 'contrast';//'details', 'texture' or 'contrast';

+ 1 - 1
Demos/Delphi/meshes/TerrainFm.pas

@@ -327,7 +327,7 @@ end;
 
 
 procedure TFormTerrain.TISoundTimer(Sender: TObject);
 procedure TFormTerrain.TISoundTimer(Sender: TObject);
 var
 var
-  wolfPos: TVector;
+  wolfPos: TGLVector;
   c, s: Single;
   c, s: Single;
 begin
 begin
   if not GLSMBASS1.Active then
   if not GLSMBASS1.Active then

+ 2 - 2
Demos/Delphi/meshes/TilesFm.pas

@@ -76,7 +76,7 @@ type
      
      
     mx, my: Integer;
     mx, my: Integer;
     tileX, tileY: Integer;
     tileX, tileY: Integer;
-    mip, translateOffset: TVector;
+    mip, translateOffset: TGLVector;
     translating: Boolean;
     translating: Boolean;
   end;
   end;
 
 
@@ -141,7 +141,7 @@ end;
 procedure TFormTiles.GLCadencer1Progress(Sender: TObject;
 procedure TFormTiles.GLCadencer1Progress(Sender: TObject;
   const deltaTime, newTime: Double);
   const deltaTime, newTime: Double);
 var
 var
-  ip: TVector;
+  ip: TGLVector;
   mp: TPoint;
   mp: TPoint;
   shiftDown: Boolean;
   shiftDown: Boolean;
 begin
 begin

+ 5 - 4
Demos/Delphi/movements/Objmove.dpr

@@ -1,13 +1,14 @@
-{ : Moving objects with the mouse.
+(*
+  Moving objects with the mouse.
 
 
-  In this demo you can move the two cubes around by picking and dragging
+  In this demo you can move the cubes around by picking and dragging
   them. This showcases the use of ScreenVectorIntersectXxxx functions.
   them. This showcases the use of ScreenVectorIntersectXxxx functions.
 
 
   You can also use the numeric keypad to move/zoom the camera and the arrow
   You can also use the numeric keypad to move/zoom the camera and the arrow
   to move the selected object around.
   to move the selected object around.
 
 
-  (Based on Rado Stoyanov's test project)
-}
+  // Based on Rado Stoyanov's test project
+*)
 program Objmove;
 program Objmove;
 
 
 uses
 uses

+ 44 - 55
Demos/Delphi/movements/ObjmoveFm.dfm

@@ -2,8 +2,8 @@ object FormObjmove: TFormObjmove
   Left = 87
   Left = 87
   Top = 128
   Top = 128
   Caption = 'Moving Objects with Mouse'
   Caption = 'Moving Objects with Mouse'
-  ClientHeight = 407
-  ClientWidth = 571
+  ClientHeight = 469
+  ClientWidth = 628
   Color = clBtnFace
   Color = clBtnFace
   ParentFont = True
   ParentFont = True
   KeyPreview = True
   KeyPreview = True
@@ -12,16 +12,17 @@ object FormObjmove: TFormObjmove
   OnCreate = FormCreate
   OnCreate = FormCreate
   OnKeyPress = FormKeyPress
   OnKeyPress = FormKeyPress
   OnKeyUp = FormKeyUp
   OnKeyUp = FormKeyUp
+  OnMouseWheel = FormMouseWheel
   PixelsPerInch = 96
   PixelsPerInch = 96
   TextHeight = 13
   TextHeight = 13
   object Scn: TGLSceneViewer
   object Scn: TGLSceneViewer
     Left = 161
     Left = 161
     Top = 0
     Top = 0
-    Width = 410
-    Height = 407
-    Camera = GLCamera1
+    Width = 467
+    Height = 450
+    Camera = GLCamera
     Buffer.BackgroundColor = clBackground
     Buffer.BackgroundColor = clBackground
-    FieldOfView = 25.000000000000000000
+    FieldOfView = 27.545242309570310000
     PenAsTouch = False
     PenAsTouch = False
     Align = alClient
     Align = alClient
     OnMouseDown = ScnMouseDown
     OnMouseDown = ScnMouseDown
@@ -33,64 +34,39 @@ object FormObjmove: TFormObjmove
     Left = 0
     Left = 0
     Top = 0
     Top = 0
     Width = 161
     Width = 161
-    Height = 407
+    Height = 450
     Align = alLeft
     Align = alLeft
     BevelOuter = bvNone
     BevelOuter = bvNone
     TabOrder = 1
     TabOrder = 1
     object Label2: TLabel
     object Label2: TLabel
-      Left = 0
-      Top = 26
-      Width = 161
-      Height = 26
-      Align = alTop
-      Caption = 'Select and move with the mouse any of the two cubes.'
-      ShowAccelChar = False
-      WordWrap = True
-      ExplicitWidth = 158
-    end
-    object Label1: TLabel
       Left = 0
       Left = 0
       Top = 0
       Top = 0
-      Width = 161
-      Height = 13
+      Width = 158
+      Height = 26
       Align = alTop
       Align = alTop
-      Caption = 'Author: Rado Stoyanov'
+      Caption = 'Select and move with the mouse any of the cubes.'
       ShowAccelChar = False
       ShowAccelChar = False
       WordWrap = True
       WordWrap = True
-      ExplicitWidth = 114
     end
     end
     object Label3: TLabel
     object Label3: TLabel
       Left = 0
       Left = 0
-      Top = 52
-      Width = 161
+      Top = 26
+      Width = 150
       Height = 26
       Height = 26
       Align = alTop
       Align = alTop
       Caption = 'Default movement is on the XY plane.'
       Caption = 'Default movement is on the XY plane.'
       ShowAccelChar = False
       ShowAccelChar = False
       WordWrap = True
       WordWrap = True
-      ExplicitWidth = 150
     end
     end
     object Label4: TLabel
     object Label4: TLabel
       Left = 0
       Left = 0
-      Top = 78
-      Width = 161
+      Top = 52
+      Width = 145
       Height = 26
       Height = 26
       Align = alTop
       Align = alTop
       Caption = 'Shift + Drag moves on the XZ plane.'
       Caption = 'Shift + Drag moves on the XZ plane.'
       ShowAccelChar = False
       ShowAccelChar = False
       WordWrap = True
       WordWrap = True
-      ExplicitWidth = 145
-    end
-    object Label5: TLabel
-      Left = 0
-      Top = 13
-      Width = 161
-      Height = 13
-      Align = alTop
-      Caption = '[email protected]'
-      ShowAccelChar = False
-      WordWrap = True
-      ExplicitWidth = 142
     end
     end
     object Button1: TButton
     object Button1: TButton
       Left = 618
       Left = 618
@@ -102,7 +78,7 @@ object FormObjmove: TFormObjmove
     end
     end
     object GroupBox1: TGroupBox
     object GroupBox1: TGroupBox
       Left = 0
       Left = 0
-      Top = 104
+      Top = 78
       Width = 161
       Width = 161
       Height = 43
       Height = 43
       Align = alTop
       Align = alTop
@@ -121,6 +97,13 @@ object FormObjmove: TFormObjmove
       end
       end
     end
     end
   end
   end
+  object StatusBar1: TStatusBar
+    Left = 0
+    Top = 450
+    Width = 628
+    Height = 19
+    Panels = <>
+  end
   object GLScene1: TGLScene
   object GLScene1: TGLScene
     Left = 296
     Left = 296
     Top = 8
     Top = 8
@@ -129,7 +112,21 @@ object FormObjmove: TFormObjmove
       Position.Coordinates = {00000000000000005C8F82BF0000803F}
       Position.Coordinates = {00000000000000005C8F82BF0000803F}
       CubeSize = {00000040000000400AD7233C}
       CubeSize = {00000040000000400AD7233C}
     end
     end
-    object TopLight1: TGLLightSource
+    object GLCamera: TGLCamera
+      DepthOfView = 1000.000000000000000000
+      FocalLength = 917.929199218750000000
+      NearPlaneBias = 0.001000000047497451
+      TargetObject = DummyCube
+      Position.Coordinates = {0000B8410000A041000080410000803F}
+      Direction.Coordinates = {2EF964BF2EF9E43E0000000000000000}
+      Up.Coordinates = {00000000000000000000803F00000000}
+    end
+    object DummyCube: TGLDummyCube
+      Position.Coordinates = {0000803F0000803F0000003F0000803F}
+      CubeSize = 0.200000002980232200
+      EdgeColor.Color = {DEDD5D3FDEDD5D3FE9E8683F0000803F}
+    end
+    object TopLight: TGLLightSource
       Ambient.Color = {0000003F0000003F0000003F0000803F}
       Ambient.Color = {0000003F0000003F0000003F0000803F}
       ConstAttenuation = 0.800000011920929000
       ConstAttenuation = 0.800000011920929000
       Diffuse.Color = {EAE9693FEAE9693FEAE9693F0000803F}
       Diffuse.Color = {EAE9693FEAE9693FEAE9693F0000803F}
@@ -150,11 +147,6 @@ object FormObjmove: TFormObjmove
       Position.Coordinates = {CDCCCCBECDCCCC3E000000BF0000803F}
       Position.Coordinates = {CDCCCCBECDCCCC3E000000BF0000803F}
       CubeSize = {0000803E0000803E0000803E}
       CubeSize = {0000803E0000803E0000803E}
     end
     end
-    object DummyCube1: TGLDummyCube
-      Position.Coordinates = {0000803F0000803F0000003F0000803F}
-      CubeSize = 0.200000002980232200
-      EdgeColor.Color = {DEDD5D3FDEDD5D3FE9E8683F0000803F}
-    end
     object XArrow: TGLArrowLine
     object XArrow: TGLArrowLine
       Direction.Coordinates = {0000803F000000000000000000000000}
       Direction.Coordinates = {0000803F000000000000000000000000}
       Position.Coordinates = {CDCCCC3D000080BF000080BF0000803F}
       Position.Coordinates = {CDCCCC3D000080BF000080BF0000803F}
@@ -234,15 +226,6 @@ object FormObjmove: TFormObjmove
         'Z')
         'Z')
       CharacterRange = stcrAlphaNum
       CharacterRange = stcrAlphaNum
     end
     end
-    object GLCamera1: TGLCamera
-      DepthOfView = 1000.000000000000000000
-      FocalLength = 917.929199218750000000
-      NearPlaneBias = 0.001000000047497451
-      TargetObject = DummyCube1
-      Position.Coordinates = {0000B8410000A041000080410000803F}
-      Direction.Coordinates = {2EF964BF2EF9E43E0000000000000000}
-      Up.Coordinates = {00000000000000000000803F00000000}
-    end
     object TopText: TGLHUDText
     object TopText: TGLHUDText
       Position.Coordinates = {0000A0400000A040000000000000803F}
       Position.Coordinates = {0000A0400000A040000000000000803F}
       BitmapFont = GLWindowsBitmapFont1
       BitmapFont = GLWindowsBitmapFont1
@@ -265,4 +248,10 @@ object FormObjmove: TFormObjmove
     Left = 448
     Left = 448
     Top = 8
     Top = 8
   end
   end
+  object GLSmoothNavigator1: TGLSmoothNavigator
+    MovingObject = DummyCube
+    MoveAroundParams.TargetObject = DummyCube
+    Left = 448
+    Top = 72
+  end
 end
 end

+ 40 - 29
Demos/Delphi/movements/ObjmoveFm.pas

@@ -13,55 +13,58 @@ uses
   Vcl.Graphics,
   Vcl.Graphics,
   Vcl.StdCtrls,
   Vcl.StdCtrls,
   Vcl.ExtCtrls,
   Vcl.ExtCtrls,
-  
-  GLS.Scene, 
-  GLS.Objects, 
-  GLS.Graph, 
-  GLS.Collision, 
-  GLS.Texture, 
+  Vcl.ComCtrls,
+
+  GLS.Scene,
+  GLS.Objects,
+  GLS.Graph,
+  GLS.Collision,
+  GLS.Texture,
   GLS.VectorTypes,
   GLS.VectorTypes,
-  GLS.VectorGeometry, 
-  GLS.VectorFileObjects, 
+  GLS.VectorGeometry,
+  GLS.VectorFileObjects,
   GLS.SceneViewer,
   GLS.SceneViewer,
-  GLS.SpaceText, 
-  GLS.GeomObjects, 
-  GLS.Color, 
- 
-  GLS.Coordinates, 
-  GLS.BaseClasses, 
-  GLS.BitmapFont, 
+  GLS.SpaceText,
+  GLS.GeomObjects,
+  GLS.Color,
+
+  GLS.Coordinates,
+  GLS.BaseClasses,
+  GLS.BitmapFont,
   GLS.WindowsFont,
   GLS.WindowsFont,
-  GLS.HUDObjects, 
-  GLS.SimpleNavigation;
+  GLS.HUDObjects,
+  GLS.SimpleNavigation,
+  GLS.Navigator,
+  GLS.SmoothNavigator;
 
 
 type
 type
   TFormObjmove = class(TForm)
   TFormObjmove = class(TForm)
     GLScene1: TGLScene;
     GLScene1: TGLScene;
     Scn: TGLSceneViewer;
     Scn: TGLSceneViewer;
-    GLCamera1: TGLCamera;
-    DummyCube1: TGLDummyCube;
+    GLCamera: TGLCamera;
+    DummyCube: TGLDummyCube;
     ZArrow: TGLArrowLine;
     ZArrow: TGLArrowLine;
     XArrow: TGLArrowLine;
     XArrow: TGLArrowLine;
     YArrow: TGLArrowLine;
     YArrow: TGLArrowLine;
     Cube1: TGLCube;
     Cube1: TGLCube;
-    TopLight1: TGLLightSource;
+    TopLight: TGLLightSource;
     Cube2: TGLCube;
     Cube2: TGLCube;
     Floor: TGLCube;
     Floor: TGLCube;
     Panel1: TPanel;
     Panel1: TPanel;
     Button1: TButton;
     Button1: TButton;
     Label2: TLabel;
     Label2: TLabel;
-    Label1: TLabel;
     TxtX: TGLSpaceText;
     TxtX: TGLSpaceText;
     TxtY: TGLSpaceText;
     TxtY: TGLSpaceText;
     Label3: TLabel;
     Label3: TLabel;
     Label4: TLabel;
     Label4: TLabel;
-    Label5: TLabel;
     TxtZ: TGLSpaceText;
     TxtZ: TGLSpaceText;
     TopText: TGLHUDText;
     TopText: TGLHUDText;
     GLWindowsBitmapFont1: TGLWindowsBitmapFont;
     GLWindowsBitmapFont1: TGLWindowsBitmapFont;
     ObjText: TGLHUDText;
     ObjText: TGLHUDText;
     GroupBox1: TGroupBox;
     GroupBox1: TGroupBox;
     ShowAxes: TCheckBox;
     ShowAxes: TCheckBox;
+    StatusBar1: TStatusBar;
+    GLSmoothNavigator1: TGLSmoothNavigator;
     procedure ScnMouseDown(Sender: TObject; Button: TMouseButton;
     procedure ScnMouseDown(Sender: TObject; Button: TMouseButton;
       Shift: TShiftState; X, Y: Integer);
       Shift: TShiftState; X, Y: Integer);
     procedure ScnMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
     procedure ScnMouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
@@ -72,11 +75,12 @@ type
     procedure FormCreate(Sender: TObject);
     procedure FormCreate(Sender: TObject);
     procedure ShowAxesClick(Sender: TObject);
     procedure ShowAxesClick(Sender: TObject);
   private
   private
-    lastMouseWorldPos: TVector;
+    lastMouseWorldPos: TGLVector;
+    Cube: TGLCube;
     movingOnZ: Boolean;
     movingOnZ: Boolean;
     CurrentPick: TGLCustomSceneObject;
     CurrentPick: TGLCustomSceneObject;
     ScnMouseMoveCnt: Integer;
     ScnMouseMoveCnt: Integer;
-    function MouseWorldPos(X, Y: Integer): TVector;
+    function MouseWorldPos(X, Y: Integer): TGLVector;
     procedure UpdateHudText;
     procedure UpdateHudText;
     procedure ProcessPick(pick: TGLBaseSceneObject);
     procedure ProcessPick(pick: TGLBaseSceneObject);
   end;
   end;
@@ -94,11 +98,18 @@ implementation
 procedure TFormObjmove.FormCreate(Sender: TObject);
 procedure TFormObjmove.FormCreate(Sender: TObject);
 begin
 begin
   UpdateHudText;
   UpdateHudText;
+  Cube := TGLCube.CreateAsChild(DummyCube);
+  Cube.CubeDepth := 0.2;
+  Cube.CubeWidth := 0.2;
+  Cube.CubeHeight := 0.2;
+  Cube.Position.X := 1;
+  Cube.Position.Y := 1;
+  Cube.Position.Z := 1;
 end;
 end;
 
 
-function TFormObjmove.MouseWorldPos(X, Y: Integer): TVector;
+function TFormObjmove.MouseWorldPos(X, Y: Integer): TGLVector;
 var
 var
-  v: TVector;
+  v: TGLVector;
 begin
 begin
   Y := Scn.Height - Y;
   Y := Scn.Height - Y;
   if Assigned(CurrentPick) then
   if Assigned(CurrentPick) then
@@ -159,7 +170,7 @@ end;
 procedure TFormObjmove.ScnMouseMove(Sender: TObject; Shift: TShiftState;
 procedure TFormObjmove.ScnMouseMove(Sender: TObject; Shift: TShiftState;
   X, Y: Integer);
   X, Y: Integer);
 var
 var
-  newPos: TVector;
+  newPos: TGLVector;
 begin
 begin
   Inc(ScnMouseMoveCnt);
   Inc(ScnMouseMoveCnt);
   Assert(ScnMouseMoveCnt < 2);
   Assert(ScnMouseMoveCnt < 2);
@@ -193,12 +204,12 @@ begin
   // Note that 1 wheel-step induces a WheelDelta of 120,
   // Note that 1 wheel-step induces a WheelDelta of 120,
   // this code adjusts the distance to target with a 10% per wheel-step ratio
   // this code adjusts the distance to target with a 10% per wheel-step ratio
   if WheelDelta <> 0 then
   if WheelDelta <> 0 then
-    GLCamera1.AdjustDistanceToTarget(Power(1.1, -WheelDelta / 120));
+    GLCamera.AdjustDistanceToTarget(Power(1.1, -WheelDelta / 120));
 end;
 end;
 
 
 procedure TFormObjmove.FormKeyPress(Sender: TObject; var Key: Char);
 procedure TFormObjmove.FormKeyPress(Sender: TObject; var Key: Char);
 begin
 begin
-  with GLCamera1 do
+  with GLCamera do
     case Key of
     case Key of
       '2':  MoveAroundTarget(3, 0);
       '2':  MoveAroundTarget(3, 0);
       '4':  MoveAroundTarget(0, -3);
       '4':  MoveAroundTarget(0, -3);

+ 1 - 1
Demos/Delphi/movements/PongFm.pas

@@ -106,7 +106,7 @@ end;
 procedure TFormPong.GLCadencer1Progress(Sender: TObject; const deltaTime,
 procedure TFormPong.GLCadencer1Progress(Sender: TObject; const deltaTime,
   newTime: Double);
   newTime: Double);
 var
 var
-	newBallPos : TVector;
+	newBallPos : TGLVector;
 begin
 begin
 	// gameOver is True as soon as the ball is behind the pad, but we don't end
 	// gameOver is True as soon as the ball is behind the pad, but we don't end
 	// the game immediately so the user can realize he has lost
 	// the game immediately so the user can realize he has lost

+ 1 - 1
Demos/Delphi/movements/TweeningFm.pas

@@ -55,7 +55,7 @@ type
     Initial1iValue: Integer;
     Initial1iValue: Integer;
     Initial1sValue: single;
     Initial1sValue: single;
     Initial3fValue: TAffineVector;
     Initial3fValue: TAffineVector;
-    Initial4fValue: TVector;
+    Initial4fValue: TGLVector;
     InitialPtValue: TSinglePoint;
     InitialPtValue: TSinglePoint;
   end;
   end;
 
 

+ 2 - 2
Demos/Delphi/physics/NewtonDensityFm.pas

@@ -83,7 +83,7 @@ function BuoyancyPlaneCallback(const collisionID: Integer; context: Pointer;
   cdecl;
   cdecl;
 var
 var
   BodyMatrix: TMatrix;
   BodyMatrix: TMatrix;
-  PlaneEquation: TVector;
+  PlaneEquation: TGLVector;
   pv: PVector;
   pv: PVector;
   MyForm: TFormNewtonDensity;
   MyForm: TFormNewtonDensity;
 begin
 begin
@@ -151,7 +151,7 @@ end;
 procedure TFormNewtonDensity.MyForceAndTorqueDensity(const cbody: PNewtonBody;
 procedure TFormNewtonDensity.MyForceAndTorqueDensity(const cbody: PNewtonBody;
   timestep: NGDFloat; threadIndex: Integer);
   timestep: NGDFloat; threadIndex: Integer);
 var
 var
-  worldGravity: TVector;
+  worldGravity: TGLVector;
   NGDDyn: TGLNGDDynamic;
   NGDDyn: TGLNGDDynamic;
   fluidDensity, fluidLinearViscosity, fluidAngularViscosity: Single;
   fluidDensity, fluidLinearViscosity, fluidAngularViscosity: Single;
 begin
 begin

+ 2 - 2
Demos/Delphi/physics/NewtonJointsFm.pas

@@ -67,7 +67,7 @@ type
     procedure FormCreate(Sender: TObject);
     procedure FormCreate(Sender: TObject);
   private
   private
      
      
-       point3d, FPaneNormal: TVector;
+       point3d, FPaneNormal: TGLVector;
 
 
   public
   public
      
      
@@ -90,7 +90,7 @@ end;
 procedure TFormNewtonJoints.GLCadencer1Progress(Sender: TObject;
 procedure TFormNewtonJoints.GLCadencer1Progress(Sender: TObject;
   const deltaTime, newTime: Double);
   const deltaTime, newTime: Double);
   var
   var
-  point2d, GotoPoint3d: TVector;
+  point2d, GotoPoint3d: TGLVector;
 begin
 begin
   GLNGDManager1.Step(deltaTime);
   GLNGDManager1.Step(deltaTime);
 
 

+ 2 - 2
Demos/Delphi/physics/NewtonMousePickFm.pas

@@ -48,7 +48,7 @@ type
     procedure FormCreate(Sender: TObject);
     procedure FormCreate(Sender: TObject);
   private
   private
      
      
-    point3d, FPaneNormal: TVector;
+    point3d, FPaneNormal: TGLVector;
   public
   public
      
      
     pickjoint: TGLNGDJoint;
     pickjoint: TGLNGDJoint;
@@ -101,7 +101,7 @@ end;
 procedure TFormNewtonMousePick.GLSceneViewer1MouseMove(Sender: TObject; Shift: TShiftState;
 procedure TFormNewtonMousePick.GLSceneViewer1MouseMove(Sender: TObject; Shift: TShiftState;
   X, Y: Integer);
   X, Y: Integer);
 var
 var
-  point2d, GotoPoint3d: TVector;
+  point2d, GotoPoint3d: TGLVector;
 begin
 begin
 
 
   if ssLeft in Shift then
   if ssLeft in Shift then

+ 2 - 2
Demos/Delphi/physics/NewtonWalkCarryFm.pas

@@ -101,7 +101,7 @@ var
 
 
   FPickedSceneObject: TGLBaseSceneObject;
   FPickedSceneObject: TGLBaseSceneObject;
   NGDDynamicBehav: TGLNGDDynamic;
   NGDDynamicBehav: TGLNGDDynamic;
-  point3d, FPaneNormal: TVector;
+  point3d, FPaneNormal: TGLVector;
   M_X, M_Y: Integer;
   M_X, M_Y: Integer;
   Maps_Count: Integer;
   Maps_Count: Integer;
   OnAir, OnGround: boolean;
   OnAir, OnGround: boolean;
@@ -133,7 +133,7 @@ var
   peak_Up, peak_Down: boolean;
   peak_Up, peak_Down: boolean;
   ray, GP3D, result_GP3D: TVector4f;
   ray, GP3D, result_GP3D: TVector4f;
   j: Integer;
   j: Integer;
-  point2d, GotoPoint3d: TVector;
+  point2d, GotoPoint3d: TGLVector;
   key_space: boolean;
   key_space: boolean;
   cp: TPoint;
   cp: TPoint;
   visible_cursor: boolean;
   visible_cursor: boolean;

+ 6 - 6
Demos/Delphi/physics/NewtonWalkShootFm.pas

@@ -183,10 +183,10 @@ procedure TFormNewtonWalkShoot.GLSceneViewer1MouseDown(Sender: TObject; Button:
   Shift: TShiftState; X, Y: Integer);
   Shift: TShiftState; X, Y: Integer);
 var
 var
   Ball: TGLSphere;
   Ball: TGLSphere;
-  delta: Tvector;
+  delta: TGLVector;
 
 
   PickedSceneObject: TGLBaseSceneObject;
   PickedSceneObject: TGLBaseSceneObject;
-  point3d: Tvector;
+  point3d: TGLVector;
   MyX, MyY: Integer;
   MyX, MyY: Integer;
 begin
 begin
   // Shoot a Bullet
   // Shoot a Bullet
@@ -250,8 +250,8 @@ end;
 
 
 procedure TFormNewtonWalkShoot.MoveCam(const deltaTime, newTime: Double);
 procedure TFormNewtonWalkShoot.MoveCam(const deltaTime, newTime: Double);
 var
 var
-  f: Tvector;
-  fup, fdn, flf, frg: Tvector;
+  f: TGLVector;
+  fup, fdn, flf, frg: TGLVector;
   Bup, Bdn, Blf, Brg: Boolean;
   Bup, Bdn, Blf, Brg: Boolean;
   NGDDyn: TGLNGDDynamic;
   NGDDyn: TGLNGDDynamic;
 begin
 begin
@@ -308,8 +308,8 @@ end;
 
 
 procedure TFormNewtonWalkShoot.MoveGrab;
 procedure TFormNewtonWalkShoot.MoveGrab;
 var
 var
-  point3d: Tvector;
-  delta: Tvector;
+  point3d: TGLVector;
+  delta: TGLVector;
 begin
 begin
   // Move the object in 3 unit front of GLCamera1.TargetObject
   // Move the object in 3 unit front of GLCamera1.TargetObject
   if IsKeyDown(VK_MBUTTON) then
   if IsKeyDown(VK_MBUTTON) then

+ 2 - 2
Demos/Delphi/physics/OdeConveyorFm.pas

@@ -71,8 +71,8 @@ type
     procedure FDirChange(Sender: TObject);
     procedure FDirChange(Sender: TObject);
     procedure AddODECubeClick(Sender: TObject);
     procedure AddODECubeClick(Sender: TObject);
   private
   private
-    FUserDirection: TVector;
-    FDirectionVector: TVector;
+    FUserDirection: TGLVector;
+    FDirectionVector: TGLVector;
   end;
   end;
 
 
 var
 var

+ 33 - 22
Demos/Delphi/rendering/FogFm.pas

@@ -16,14 +16,13 @@ uses
   Vcl.ExtCtrls,
   Vcl.ExtCtrls,
   Vcl.StdCtrls,
   Vcl.StdCtrls,
 
 
-  
   GLS.Scene,
   GLS.Scene,
   GLS.VectorTypes,
   GLS.VectorTypes,
   GLS.Objects,
   GLS.Objects,
   GLS.Cadencer,
   GLS.Cadencer,
   GLS.SceneViewer,
   GLS.SceneViewer,
   GLS.Texture,
   GLS.Texture,
- 
+
   GLS.Material,
   GLS.Material,
   GLS.Coordinates,
   GLS.Coordinates,
   GLS.Utils,
   GLS.Utils,
@@ -55,11 +54,14 @@ type
     CBApplyToBackground: TCheckBox;
     CBApplyToBackground: TCheckBox;
     LFogDensity: TLabel;
     LFogDensity: TLabel;
     EFogDensity: TEdit;
     EFogDensity: TEdit;
-    procedure GLSceneViewer1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
-    procedure GLSceneViewer1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
+    procedure GLSceneViewer1MouseDown(Sender: TObject; Button: TMouseButton;
+      Shift: TShiftState; X, Y: Integer);
+    procedure GLSceneViewer1MouseMove(Sender: TObject; Shift: TShiftState;
+      X, Y: Integer);
     procedure CBFogEnableClick(Sender: TObject);
     procedure CBFogEnableClick(Sender: TObject);
     procedure SEFogStartChange(Sender: TObject);
     procedure SEFogStartChange(Sender: TObject);
-    procedure SFogColorMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
+    procedure SFogColorMouseDown(Sender: TObject; Button: TMouseButton;
+      Shift: TShiftState; X, Y: Integer);
     procedure RGFogModeClick(Sender: TObject);
     procedure RGFogModeClick(Sender: TObject);
     procedure FormCreate(Sender: TObject);
     procedure FormCreate(Sender: TObject);
     procedure CBApplyToBackgroundClick(Sender: TObject);
     procedure CBApplyToBackgroundClick(Sender: TObject);
@@ -69,8 +71,8 @@ type
     procedure FormMouseWheel(Sender: TObject; Shift: TShiftState;
     procedure FormMouseWheel(Sender: TObject; Shift: TShiftState;
       WheelDelta: Integer; MousePos: TPoint; var Handled: Boolean);
       WheelDelta: Integer; MousePos: TPoint; var Handled: Boolean);
   private
   private
-    MX: integer;
-    MY: integer;
+    MX: Integer;
+    MY: Integer;
     procedure ApplyFogSettings;
     procedure ApplyFogSettings;
   public
   public
   end;
   end;
@@ -86,7 +88,8 @@ implementation
 //
 //
 procedure TFormFog.ApplyFogSettings;
 procedure TFormFog.ApplyFogSettings;
 begin
 begin
-  with GLSceneViewer1.Buffer.FogEnvironment do begin
+  with GLSceneViewer1.Buffer.FogEnvironment do
+  begin
     FogMode := TFogMode(RGFogMode.ItemIndex);
     FogMode := TFogMode(RGFogMode.ItemIndex);
     FogDistance := TFogDistance(RGFogDistance.ItemIndex);
     FogDistance := TFogDistance(RGFogDistance.ItemIndex);
     FogColor.AsWinColor := SFogColor.Brush.Color;
     FogColor.AsWinColor := SFogColor.Brush.Color;
@@ -101,7 +104,8 @@ end;
 
 
 // glsceneviewer1mousedown
 // glsceneviewer1mousedown
 //
 //
-procedure TFormFog.GLSceneViewer1MouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
+procedure TFormFog.GLSceneViewer1MouseDown(Sender: TObject;
+  Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
 begin
 begin
   MX := X;
   MX := X;
   MY := Y;
   MY := Y;
@@ -109,7 +113,8 @@ end;
 
 
 // glsceneviewer1mousemove
 // glsceneviewer1mousemove
 //
 //
-procedure TFormFog.GLSceneViewer1MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer);
+procedure TFormFog.GLSceneViewer1MouseMove(Sender: TObject; Shift: TShiftState;
+  X, Y: Integer);
 begin
 begin
   if Shift <> [] then
   if Shift <> [] then
     GLSceneViewer1.Camera.MoveAroundTarget(MY - Y, MX - X);
     GLSceneViewer1.Camera.MoveAroundTarget(MY - Y, MX - X);
@@ -136,9 +141,11 @@ end;
 
 
 // sgfogcolormousedown
 // sgfogcolormousedown
 //
 //
-procedure TFormFog.SFogColorMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
+procedure TFormFog.SFogColorMouseDown(Sender: TObject; Button: TMouseButton;
+  Shift: TShiftState; X, Y: Integer);
 begin
 begin
-  if ColorDialog1.Execute then begin
+  if ColorDialog1.Execute then
+  begin
     SFogColor.Brush.Color := ColorDialog1.Color;
     SFogColor.Brush.Color := ColorDialog1.Color;
     ApplyFogSettings;
     ApplyFogSettings;
   end;
   end;
@@ -157,13 +164,13 @@ procedure TFormFog.FormCreate(Sender: TObject);
 const
 const
   cSpacing = 2;
   cSpacing = 2;
   cEdgeLength = 0.7;
   cEdgeLength = 0.7;
-  cNb = 4;
+  cNb = 5;
 
 
 var
 var
-  X: integer;
-  Y: integer;
-  Z: integer;
-  Cube : TGLCube;
+  X: Integer;
+  Y: Integer;
+  Z: Integer;
+  Cube: TGLCube;
 
 
 begin
 begin
   SetGLSceneMediaDir();
   SetGLSceneMediaDir();
@@ -171,7 +178,8 @@ begin
   for X := -cNb to cNb do
   for X := -cNb to cNb do
     for Y := -cNb to cNb do
     for Y := -cNb to cNb do
       for Z := -cNb to cNb do
       for Z := -cNb to cNb do
-        if (X and Y and Z) <> 0 then begin
+        if (X and Y and Z) <> 0 then
+        begin
           Cube := TGLCube(GLDummyCube1.AddNewChild(TGLCube));
           Cube := TGLCube(GLDummyCube1.AddNewChild(TGLCube));
           Cube.Material.MaterialLibrary := GLMaterialLibrary1;
           Cube.Material.MaterialLibrary := GLMaterialLibrary1;
           Cube.Material.LibMaterialName := 'glscene';
           Cube.Material.LibMaterialName := 'glscene';
@@ -186,7 +194,7 @@ end;
 procedure TFormFog.FormMouseWheel(Sender: TObject; Shift: TShiftState;
 procedure TFormFog.FormMouseWheel(Sender: TObject; Shift: TShiftState;
   WheelDelta: Integer; MousePos: TPoint; var Handled: Boolean);
   WheelDelta: Integer; MousePos: TPoint; var Handled: Boolean);
 begin
 begin
-	GLCamera1.AdjustDistanceToTarget(Power(1.1, WheelDelta/120));
+  GLCamera1.AdjustDistanceToTarget(Power(1.1, WheelDelta / 120));
   Handled := true
   Handled := true
 end;
 end;
 
 
@@ -201,7 +209,8 @@ end;
 //
 //
 procedure TFormFog.CBTextureEnabledClick(Sender: TObject);
 procedure TFormFog.CBTextureEnabledClick(Sender: TObject);
 begin
 begin
-  GLMaterialLibrary1.Materials[0].Material.Texture.Enabled := CBTextureEnabled.Checked;
+  GLMaterialLibrary1.Materials[0].Material.Texture.Enabled :=
+    CBTextureEnabled.Checked;
 end;
 end;
 
 
 // cbtextureignorefogclick
 // cbtextureignorefogclick
@@ -209,9 +218,11 @@ end;
 procedure TFormFog.CBTextureIgnoreFogClick(Sender: TObject);
 procedure TFormFog.CBTextureIgnoreFogClick(Sender: TObject);
 begin
 begin
   if CBTextureIgnoreFog.Checked then
   if CBTextureIgnoreFog.Checked then
-    GLMaterialLibrary1.Materials[0].Material.MaterialOptions := GLMaterialLibrary1.Materials[0].Material.MaterialOptions + [moIgnoreFog]
+    GLMaterialLibrary1.Materials[0].Material.MaterialOptions :=
+      GLMaterialLibrary1.Materials[0].Material.MaterialOptions + [moIgnoreFog]
   else
   else
-    GLMaterialLibrary1.Materials[0].Material.MaterialOptions := GLMaterialLibrary1.Materials[0].Material.MaterialOptions - [moIgnoreFog];
+    GLMaterialLibrary1.Materials[0].Material.MaterialOptions :=
+      GLMaterialLibrary1.Materials[0].Material.MaterialOptions - [moIgnoreFog];
 end;
 end;
 
 
 procedure TFormFog.EFogStartChange(Sender: TObject);
 procedure TFormFog.EFogStartChange(Sender: TObject);

+ 4 - 4
Demos/Delphi/specialsFX/CandlesFm.dfm

@@ -12,13 +12,12 @@ object FormCandles: TFormCandles
   Font.Style = []
   Font.Style = []
   OldCreateOrder = False
   OldCreateOrder = False
   Position = poScreenCenter
   Position = poScreenCenter
-  WindowState = wsMaximized
   OnResize = FormResize
   OnResize = FormResize
   PixelsPerInch = 96
   PixelsPerInch = 96
   TextHeight = 13
   TextHeight = 13
   object GLSceneViewer1: TGLSceneViewer
   object GLSceneViewer1: TGLSceneViewer
     Left = 0
     Left = 0
-    Top = 0
+    Top = 29
     Width = 442
     Width = 442
     Height = 296
     Height = 296
     Camera = GLCamera1
     Camera = GLCamera1
@@ -32,11 +31,11 @@ object FormCandles: TFormCandles
   end
   end
   object TrackBar1: TTrackBar
   object TrackBar1: TTrackBar
     Left = 0
     Left = 0
-    Top = 296
+    Top = 0
     Width = 442
     Width = 442
     Height = 29
     Height = 29
     Hint = 'Wind'
     Hint = 'Wind'
-    Align = alBottom
+    Align = alTop
     Max = 20
     Max = 20
     Min = -20
     Min = -20
     ParentShowHint = False
     ParentShowHint = False
@@ -44,6 +43,7 @@ object FormCandles: TFormCandles
     ShowHint = True
     ShowHint = True
     TabOrder = 1
     TabOrder = 1
     OnChange = TrackBar1Change
     OnChange = TrackBar1Change
+    ExplicitTop = 302
   end
   end
   object GLScene1: TGLScene
   object GLScene1: TGLScene
     Left = 32
     Left = 32

+ 1 - 1
Demos/Delphi/specialsFX/WaterPlaneFm.pas

@@ -83,7 +83,7 @@ implementation
 
 
 procedure TFormWaterPlane.ClickWater(X, Y: Integer);
 procedure TFormWaterPlane.ClickWater(X, Y: Integer);
 var
 var
-  ip: TVector;
+  ip: TGLVector;
 begin
 begin
   // create a ripple in the pond on a right-mousebutton click
   // create a ripple in the pond on a right-mousebutton click
 
 

+ 1 - 3
Demos/Delphi/sprites/ImposterFm.pas

@@ -60,9 +60,7 @@ type
     procedure CBShowImposterClick(Sender: TObject);
     procedure CBShowImposterClick(Sender: TObject);
     procedure CBShowTeapotClick(Sender: TObject);
     procedure CBShowTeapotClick(Sender: TObject);
   private
   private
-     
   public
   public
-     
     impBuilder: TGLStaticImposterBuilder;
     impBuilder: TGLStaticImposterBuilder;
     renderPoint: TGLRenderPoint;
     renderPoint: TGLRenderPoint;
     mx, my: Integer;
     mx, my: Integer;
@@ -98,7 +96,7 @@ end;
 procedure TFormImposter.GLDirectOpenGL1Render(Sender: TObject;
 procedure TFormImposter.GLDirectOpenGL1Render(Sender: TObject;
   var rci: TGLRenderContextInfo);
   var rci: TGLRenderContextInfo);
 var
 var
-  camPos, pos: TVector;
+  camPos, pos: TGLVector;
   imp: TImposter;
   imp: TImposter;
   X, Y: Integer;
   X, Y: Integer;
 begin
 begin

+ 2 - 2
Demos/Delphi/utilities/ArchiveEdit/Main.dfm

@@ -42,7 +42,7 @@ object Form1: TForm1
     OnKeyDown = TreeViewKeyDown
     OnKeyDown = TreeViewKeyDown
   end
   end
   object ListView: TListView
   object ListView: TListView
-    Left = 176
+    Left = 175
     Top = 8
     Top = 8
     Width = 365
     Width = 365
     Height = 466
     Height = 466
@@ -72,7 +72,7 @@ object Form1: TForm1
   end
   end
   object GLSceneViewer1: TGLSceneViewer
   object GLSceneViewer1: TGLSceneViewer
     Left = 8
     Left = 8
-    Top = 312
+    Top = 311
     Width = 161
     Width = 161
     Height = 161
     Height = 161
     Camera = GLCamera1
     Camera = GLCamera1

+ 23 - 17
Demos/Delphi/utilities/ArchiveEdit/Main.pas

@@ -19,8 +19,6 @@ uses
   Vcl.Imaging.Jpeg,
   Vcl.Imaging.Jpeg,
 
 
   GLS.ArchiveManager,
   GLS.ArchiveManager,
-  GLS.FilePAK,
-  GLS.FileZLIB,
   GLS.SceneViewer,
   GLS.SceneViewer,
 
 
   GLS.BaseClasses,
   GLS.BaseClasses,
@@ -36,6 +34,10 @@ uses
   GLS.State,
   GLS.State,
   GLS.CompositeImage,
   GLS.CompositeImage,
   // FileFormats 3D
   // FileFormats 3D
+  GLS.FileJPEG,
+  GLS.FilePAK,
+  GLS.FileZLIB,
+
   GLS.FileMS3D,
   GLS.FileMS3D,
   GLS.File3DS,
   GLS.File3DS,
   GLS.FileMD2,
   GLS.FileMD2,
@@ -45,7 +47,9 @@ uses
   GLS.FileSMD,
   GLS.FileSMD,
   GLS.FileTGA,
   GLS.FileTGA,
   GLS.FilePNG,
   GLS.FilePNG,
-  GLS.FileDDS;
+  GLS.FileDDS,
+
+  GLS.Utils;
 
 
 type
 type
   TForm1 = class(TForm)
   TForm1 = class(TForm)
@@ -129,13 +133,28 @@ var
 implementation
 implementation
 //-------------------------------------
 //-------------------------------------
 
 
-uses 
+uses
   FolderDialog, 
   FolderDialog, 
   FolderSelect;
   FolderSelect;
 
 
 {$R *.dfm}
 {$R *.dfm}
 {.$R icons.res}
 {.$R icons.res}
 
 
+procedure TForm1.FormCreate(Sender: TObject);
+var
+  Bmp: TBitmap;
+begin
+  SetGLSceneMediaDir();
+  Bmp := TBitmap.Create;
+  Bmp.LoadFromResourceName(HInstance, 'ICONS');
+  ImageList1.AddMasked(Bmp, clWhite);
+  Bmp.Free;
+  ArchiveManager := TGLSArchiveManager.Create(Self);
+  Archive := ArchiveManager.Archives.Add;
+  vMenu := None1;
+end;
+
+
 procedure TForm1.AddNode(text: string; node: TTreeNode);
 procedure TForm1.AddNode(text: string; node: TTreeNode);
 var
 var
   s: string;
   s: string;
@@ -265,19 +284,6 @@ begin
     end;
     end;
 end;
 end;
 
 
-procedure TForm1.FormCreate(Sender: TObject);
-var
-  Bmp: TBitmap;
-begin
-  Bmp := TBitmap.Create;
-  Bmp.LoadFromResourceName(HInstance, 'ICONS');
-  ImageList1.AddMasked(Bmp, clWhite);
-  Bmp.Free;
-  ArchiveManager := TGLSArchiveManager.Create(Self);
-  Archive := ArchiveManager.Archives.Add;
-  vMenu := None1;
-end;
-
 procedure TForm1.TreeViewCollapsing(Sender: TObject; node: TTreeNode;
 procedure TForm1.TreeViewCollapsing(Sender: TObject; node: TTreeNode;
   var AllowCollapse: Boolean);
   var AllowCollapse: Boolean);
 begin
 begin

+ 1 - 0
Source/GLS.BaseClasses.pas

@@ -170,3 +170,4 @@ end;
 end.
 end.
 
 
 
 
+

+ 8 - 8
Source/GLS.Canvas.pas

@@ -17,7 +17,7 @@ uses
   System.Classes,
   System.Classes,
   System.Math,
   System.Math,
   Vcl.Graphics,
   Vcl.Graphics,
-  
+
   GLS.OpenGLTokens,
   GLS.OpenGLTokens,
   GLS.VectorGeometry,
   GLS.VectorGeometry,
   GLS.Color,
   GLS.Color,
@@ -27,7 +27,7 @@ uses
 
 
 type
 type
 
 
-  TArcDirection = (adCounterClockWise, adClockWise);
+  TGLArcDirection = (adCounterClockWise, adClockWise);
 
 
   (* A simple Canvas-like interface for OpenGL.
   (* A simple Canvas-like interface for OpenGL.
      This class implements a small "shell" for 2D operations in OpenGL,
      This class implements a small "shell" for 2D operations in OpenGL,
@@ -46,8 +46,8 @@ type
     FCurrentPos: TAffineVector;
     FCurrentPos: TAffineVector;
     FPenColor: TColor;
     FPenColor: TColor;
     FPenWidth: Integer;
     FPenWidth: Integer;
-    FCurrentPenColorVector: TVector;
-    FArcDirection: TArcDirection;
+    FCurrentPenColorVector: TGLVector;
+    FArcDirection: TGLArcDirection;
   protected
   protected
     procedure BackupOpenGLStates;
     procedure BackupOpenGLStates;
     procedure StartPrimitive(const primitiveType: Integer);
     procedure StartPrimitive(const primitiveType: Integer);
@@ -66,7 +66,7 @@ type
       UpdateCurrentPos: Boolean); overload;
       UpdateCurrentPos: Boolean); overload;
   public
   public
     constructor Create(bufferSizeX, bufferSizeY: Integer;
     constructor Create(bufferSizeX, bufferSizeY: Integer;
-      const baseTransform: TMatrix); overload;
+      const baseTransform: TGLMatrix); overload;
     constructor Create(bufferSizeX, bufferSizeY: Integer); overload;
     constructor Create(bufferSizeX, bufferSizeY: Integer); overload;
     destructor Destroy; override;
     destructor Destroy; override;
     (* Stops the current internal primitive.
     (* Stops the current internal primitive.
@@ -161,7 +161,7 @@ type
     procedure ArcTo(const x1, y1, x2, y2: Single; AngleBegin, AngleEnd: Single); overload;
     procedure ArcTo(const x1, y1, x2, y2: Single; AngleBegin, AngleEnd: Single); overload;
     procedure RoundRect(const x1, y1, x2, y2, xr, yr: Integer); overload;
     procedure RoundRect(const x1, y1, x2, y2, xr, yr: Integer); overload;
     procedure RoundRect(const x1, y1, x2, y2, xr, yr: Single); overload;
     procedure RoundRect(const x1, y1, x2, y2, xr, yr: Single); overload;
-    property ArcDirection: TArcDirection read FArcDirection write FArcDirection;
+    property ArcDirection: TGLArcDirection read FArcDirection write FArcDirection;
   end;
   end;
 
 
 //-------------------------------------------------------------
 //-------------------------------------------------------------
@@ -178,9 +178,9 @@ const
 // ------------------
 // ------------------
 
 
 constructor TGLCanvas.Create(bufferSizeX, bufferSizeY: Integer;
 constructor TGLCanvas.Create(bufferSizeX, bufferSizeY: Integer;
-  const baseTransform: TMatrix);
+  const baseTransform: TGLMatrix);
 var
 var
-  PM: TMatrix;
+  PM: TGLMatrix;
 begin
 begin
   FBufferSizeX := bufferSizeX;
   FBufferSizeX := bufferSizeX;
   FBufferSizeY := bufferSizeY;
   FBufferSizeY := bufferSizeY;

+ 10 - 11
Source/GLS.Imposter.pas

@@ -1,7 +1,6 @@
 //
 //
 // The graphics rendering engine GLScene http://glscene.org
 // The graphics rendering engine GLScene http://glscene.org
 //
 //
-
 unit GLS.Imposter;
 unit GLS.Imposter;
 
 
 (* Imposter building and rendering implementation for GLScene *)
 (* Imposter building and rendering implementation for GLScene *)
@@ -37,17 +36,17 @@ uses
 type
 type
   (* Imposter rendering options.
   (* Imposter rendering options.
      Following options are supported:
      Following options are supported:
-      impoBlended : the imposters are transparently blended during renders,
-     this will smooth their edges but requires them to be rendered sorted
-     from back to front
-      impoAlphaTest : alpha test is used to eliminate transparent pixels,
-     the alpha treshold is adjusted by the AlphaTreshold property
+     impoBlended : the imposters are transparently blended during renders,
+      this will smooth their edges but requires them to be rendered sorted
+      from back to front
+     impoAlphaTest : alpha test is used to eliminate transparent pixels,
+      the alpha treshold is adjusted by the AlphaTreshold property
       impoNearestFiltering : use nearest texture filtering (the alternative
       impoNearestFiltering : use nearest texture filtering (the alternative
-     is linear filtering)
-      impoPerspectiveCorrection : activates a special imposter rendering
-     projection suitable for distorting the sprites when seen from a level
-     angle of view with a wide focal camera (think trees/grass when walking
-     in a forest), if not active, the imposter sprites are camera-facing *)
+      is linear filtering)
+     impoPerspectiveCorrection : activates a special imposter rendering
+      projection suitable for distorting the sprites when seen from a level
+      angle of view with a wide focal camera (think trees/grass when walking
+      in a forest), if not active, the imposter sprites are camera-facing *)
   TImposterOption = (impoBlended, impoAlphaTest, impoNearestFiltering,
   TImposterOption = (impoBlended, impoAlphaTest, impoNearestFiltering,
     impoPerspectiveCorrection);
     impoPerspectiveCorrection);
   TImposterOptions = set of TImposterOption;
   TImposterOptions = set of TImposterOption;

+ 2 - 6
Source/GLS.Isosurface.pas

@@ -1,9 +1,7 @@
 //
 //
 // The graphics rendering engine GLScene http://glscene.org
 // The graphics rendering engine GLScene http://glscene.org
 //
 //
-
 unit GLS.Isosurface;
 unit GLS.Isosurface;
-
 (*
 (*
   Polygonising a scalar field by construction of isosurfaces
   Polygonising a scalar field by construction of isosurfaces
   Algorithms
   Algorithms
@@ -27,7 +25,6 @@ unit GLS.Isosurface;
   - Simple Data Structures to store Mesh. Vertices are calculated and stored twice
   - Simple Data Structures to store Mesh. Vertices are calculated and stored twice
   or even more often.
   or even more often.
 *)
 *)
-
 interface
 interface
 
 
 {$I GLScene.inc}
 {$I GLScene.inc}
@@ -51,7 +48,6 @@ type
   TSingle3DArray = array of array of array of Single;
   TSingle3DArray = array of array of array of Single;
   TVertexArray = array of TVector3f;
   TVertexArray = array of TVector3f;
   TIntegerArray = array of Integer;
   TIntegerArray = array of Integer;
-
   TGLMarchingCube = class(TObject)
   TGLMarchingCube = class(TObject)
   private
   private
     FIsoValue: TxScalarValue;
     FIsoValue: TxScalarValue;
@@ -156,10 +152,10 @@ type
       var AData: TSingle3DArray); overload;
       var AData: TSingle3DArray); overload;
     destructor Destroy(); override;
     destructor Destroy(); override;
     procedure AssignData(Xdim, Ydim, Zdim: Integer; var AData: TSingle3DArray);
     procedure AssignData(Xdim, Ydim, Zdim: Integer; var AData: TSingle3DArray);
-    { Launch Marching Cubes }
+    // Launch Marching Cubes
     procedure MarchingCubes(Isovalue: Single; out Vertices: TVertexArray;
     procedure MarchingCubes(Isovalue: Single; out Vertices: TVertexArray;
       out Triangles: TIntegerArray; isPolished: boolean);
       out Triangles: TIntegerArray; isPolished: boolean);
-    { Launch Marching Tetrahedra }
+    // Launch Marching Tetrahedra
     procedure MarchingTetrahedra(Isovalue: Single; out Vertices: TVertexArray;
     procedure MarchingTetrahedra(Isovalue: Single; out Vertices: TVertexArray;
       out Triangles: TIntegerArray; isPolished: boolean);
       out Triangles: TIntegerArray; isPolished: boolean);
   end;
   end;

+ 2 - 2
Source/GLS.Logger.pas

@@ -997,7 +997,7 @@ begin
 end;
 end;
 
 
 procedure TLogSession.DisplayLog;
 procedure TLogSession.DisplayLog;
-{$IFDEF LINUX}
+{$IF Defined(LINUX) and not Defined(CROSSVCL)}
 var
 var
   lProcess: TProcess;
   lProcess: TProcess;
 {$ENDIF}
 {$ENDIF}
@@ -1006,7 +1006,7 @@ begin
   ShellExecute(0, 'open', 'C:\WINDOWS\notepad.exe',
   ShellExecute(0, 'open', 'C:\WINDOWS\notepad.exe',
     PChar(FCurrentLogFileName), nil, 1);
     PChar(FCurrentLogFileName), nil, 1);
 {$ENDIF}
 {$ENDIF}
-{$IFDEF LINUX}
+{$IF Defined(LINUX) and not Defined(CROSSVCL)}
   lProcess := TProcess.Create(nil);
   lProcess := TProcess.Create(nil);
   lProcess.CommandLine := 'gedit ' + FCurrentLogFileName;
   lProcess.CommandLine := 'gedit ' + FCurrentLogFileName;
   lProcess.Execute;
   lProcess.Execute;

+ 2 - 1
Source/GLS.Mesh.pas

@@ -6,7 +6,8 @@ unit GLS.Mesh;
 
 
 (*
 (*
   This unit is for simple meshes and legacy support,
   This unit is for simple meshes and legacy support,
-  GLS.VectorFileObjects implements more efficient (though more complex) mesh tools.
+  GLS.VectorFileObjects implements more efficient
+  (though more complex) mesh tools.
 *)
 *)
 
 
 interface
 interface

+ 6 - 6
Source/GLS.Objects.pas

@@ -477,8 +477,8 @@ type
     property Options: TGLLinesOptions read FOptions write SetOptions;
     property Options: TGLLinesOptions read FOptions write SetOptions;
   end;
   end;
 
 
-  TCubePart = (cpTop, cpBottom, cpFront, cpBack, cpLeft, cpRight);
-  TCubeParts = set of TCubePart;
+  TGLCubePart = (cpTop, cpBottom, cpFront, cpBack, cpLeft, cpRight);
+  TGLCubeParts = set of TGLCubePart;
 
 
   (* A simple cube object.
   (* A simple cube object.
     This cube use the same material for each of its faces, ie. all faces look
     This cube use the same material for each of its faces, ie. all faces look
@@ -487,11 +487,11 @@ type
   TGLCube = class(TGLSceneObject)
   TGLCube = class(TGLSceneObject)
   private
   private
     FCubeSize: TAffineVector;
     FCubeSize: TAffineVector;
-    FParts: TCubeParts;
+    FParts: TGLCubeParts;
     FNormalDirection: TGLNormalDirection;
     FNormalDirection: TGLNormalDirection;
     function GetCubeWHD(const Index: Integer): TGLFloat; inline;
     function GetCubeWHD(const Index: Integer): TGLFloat; inline;
     procedure SetCubeWHD(Index: Integer; aValue: TGLFloat); inline;
     procedure SetCubeWHD(Index: Integer; aValue: TGLFloat); inline;
-    procedure SetParts(aValue: TCubeParts); inline;
+    procedure SetParts(aValue: TGLCubeParts); inline;
     procedure SetNormalDirection(aValue: TGLNormalDirection); inline;
     procedure SetNormalDirection(aValue: TGLNormalDirection); inline;
   protected
   protected
     procedure DefineProperties(Filer: TFiler); override;
     procedure DefineProperties(Filer: TFiler); override;
@@ -516,7 +516,7 @@ type
       stored False;
       stored False;
     property NormalDirection: TGLNormalDirection read FNormalDirection
     property NormalDirection: TGLNormalDirection read FNormalDirection
       write SetNormalDirection default ndOutside;
       write SetNormalDirection default ndOutside;
-    property Parts: TCubeParts read FParts write SetParts
+    property Parts: TGLCubeParts read FParts write SetParts
       default [cpTop, cpBottom, cpFront, cpBack, cpLeft, cpRight];
       default [cpTop, cpBottom, cpFront, cpBack, cpLeft, cpRight];
   end;
   end;
 
 
@@ -2520,7 +2520,7 @@ begin
   end;
   end;
 end;
 end;
 
 
-procedure TGLCube.SetParts(aValue: TCubeParts);
+procedure TGLCube.SetParts(aValue: TGLCubeParts);
 begin
 begin
   if aValue <> FParts then
   if aValue <> FParts then
   begin
   begin

+ 23 - 0
Source/GLS.OpenGLAdapter.pas

@@ -23,8 +23,20 @@ uses
   GLS.VectorTypes;
   GLS.VectorTypes;
 
 
 const
 const
+  {$IFDEF CROSSVCL}
+    {$IF Defined(LINUX)}
+    opengl32 = 'libGL.so';
+    glu32 = 'libGLU.so.1';
+    {$ELSEIF Defined(MACOS)}
+    opengl32 = '/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib';
+    glu32 = '/System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLU.dylib';
+    {$ELSE}
+    Unsupported platform 
+    {$ENDIF}
+  {$ELSE}
   opengl32 = 'OpenGL32.dll';
   opengl32 = 'OpenGL32.dll';
   glu32 = 'GLU32.dll';
   glu32 = 'GLU32.dll';
+  {$ENDIF}
 
 
 type
 type
   EOpenGLError = class(Exception);
   EOpenGLError = class(Exception);
@@ -1766,8 +1778,17 @@ end;
 {$ENDIF} //MSWINDOWS
 {$ENDIF} //MSWINDOWS
 
 
 function GetProcAddressGLLib(ProcName: PAnsiChar): Pointer;
 function GetProcAddressGLLib(ProcName: PAnsiChar): Pointer;
+{$IFDEF CROSSVCL}
+var
+  UniProcName: string;
+{$ENDIF}
 begin
 begin
+  {$IFDEF CROSSVCL}
+  UniProcName := ProcName;
+  Result := getProcAddress(GLHandle, PChar(UniProcName));
+  {$ELSE}
   Result := getProcAddress(GLHandle, ProcName);
   Result := getProcAddress(GLHandle, ProcName);
+  {$ENDIF}
 end;
 end;
 
 
 var
 var
@@ -4909,7 +4930,9 @@ end;
 initialization
 initialization
 //--------------------------------------
 //--------------------------------------
 
 
+{$IFNDEF CROSSVCL}
 Set8087CW($133F);
 Set8087CW($133F);
+{$ENDIF}
 
 
 finalization
 finalization
 
 

+ 6 - 18
Source/GLS.Selection.pas

@@ -1,7 +1,6 @@
 //
 //
 // The graphics rendering engine GLScene http://glscene.org
 // The graphics rendering engine GLScene http://glscene.org
 //
 //
-
 unit GLS.Selection;
 unit GLS.Selection;
 
 
 (* Picking and selection of objects *)
 (* Picking and selection of objects *)
@@ -14,19 +13,18 @@ uses
   Winapi.OpenGL,
   Winapi.OpenGL,
   System.SysUtils,
   System.SysUtils,
   System.Classes,
   System.Classes,
-   
-  GLS.OpenGLTokens, 
-  GLS.Context, 
-  GLS.VectorLists, 
+
+  GLS.OpenGLTokens,
+  GLS.Context,
+  GLS.VectorLists,
   GLS.VectorGeometry,
   GLS.VectorGeometry,
-  GLS.BaseClasses, 
+  GLS.BaseClasses,
   GLS.PersistentClasses;
   GLS.PersistentClasses;
 
 
- const
+const
   MAX_OBJECT_STACK_DEPTH = 512;
   MAX_OBJECT_STACK_DEPTH = 512;
 
 
 type
 type
-
   TPickSubObjects = array of LongInt;
   TPickSubObjects = array of LongInt;
 
 
   TPickRecord = class
   TPickRecord = class
@@ -86,7 +84,6 @@ type
 
 
   TGLBaseSelectTechniqueClass = class of TGLBaseSelectTechnique;
   TGLBaseSelectTechniqueClass = class of TGLBaseSelectTechnique;
 
 
-
   TGLSelectRenderModeTechnique = class(TGLBaseSelectTechnique)
   TGLSelectRenderModeTechnique = class(TGLBaseSelectTechnique)
   private
   private
     FBuffer: array of Cardinal;
     FBuffer: array of Cardinal;
@@ -180,14 +177,12 @@ begin
     Sort(@Comparefunction);
     Sort(@Comparefunction);
 end;
 end;
 
 
-
 procedure TGLPickList.Clear;
 procedure TGLPickList.Clear;
 begin
 begin
   DoClean;
   DoClean;
   inherited;
   inherited;
 end;
 end;
 
 
-
 function TGLPickList.FindObject(aObject: TObject): Integer;
 function TGLPickList.FindObject(aObject: TObject): Integer;
 var
 var
   i: Integer;
   i: Integer;
@@ -204,19 +199,16 @@ begin
     end;
     end;
 end;
 end;
 
 
-
 function TGLPickList.GetFar(aValue: Integer): Single;
 function TGLPickList.GetFar(aValue: Integer): Single;
 begin
 begin
   Result := TPickRecord(Items[AValue]).ZMax;
   Result := TPickRecord(Items[AValue]).ZMax;
 end;
 end;
 
 
-
 function TGLPickList.GetHit(aValue: Integer): TObject;
 function TGLPickList.GetHit(aValue: Integer): TObject;
 begin
 begin
   Result := TPickRecord(Items[AValue]).AObject;
   Result := TPickRecord(Items[AValue]).AObject;
 end;
 end;
 
 
-
 function TGLPickList.GetNear(aValue: Integer): Single;
 function TGLPickList.GetNear(aValue: Integer): Single;
 begin
 begin
   Result := TPickRecord(Items[AValue]).ZMin;
   Result := TPickRecord(Items[AValue]).ZMin;
@@ -227,7 +219,6 @@ begin
   Result := TPickRecord(Items[AValue]).SubObjects;
   Result := TPickRecord(Items[AValue]).SubObjects;
 end;
 end;
 
 
-
 // ------------------
 // ------------------
 // ------------------ TGLSelectRenderModeTechnique ------------------
 // ------------------ TGLSelectRenderModeTechnique ------------------
 // ------------------
 // ------------------
@@ -286,7 +277,6 @@ begin
     AList := TGLPickList.Create(psDefault)
     AList := TGLPickList.Create(psDefault)
   else
   else
     AList.Clear;
     AList.Clear;
-
   if FHits > -1 then
   if FHits > -1 then
   begin
   begin
     next := 0;
     next := 0;
@@ -329,6 +319,4 @@ begin
   Inc(FCurrentName);
   Inc(FCurrentName);
 end;
 end;
 
 
- 
-
 end.
 end.

+ 2 - 0
Source/GLS.Sound.pas

@@ -20,6 +20,8 @@ uses
   GLS.VectorGeometry,
   GLS.VectorGeometry,
   GLS.Cadencer,
   GLS.Cadencer,
   GLS.BaseClasses,
   GLS.BaseClasses,
+  GLS.FileMP3,
+  GLS.FileWAV,
   GLS.Utils;
   GLS.Utils;
 
 
 {$I GLScene.inc}
 {$I GLScene.inc}

+ 4 - 0
Source/GLS.VectorGeometry.pas

@@ -72,7 +72,11 @@ type
 
 
   PExtendedVector = ^TExtendedVector;
   PExtendedVector = ^TExtendedVector;
   PExtendedArray = PExtendedVector;
   PExtendedArray = PExtendedVector;
+  {$IFDEF CROSSVCL}
+  TExtendedVector = array [0 .. cMaxArray div 2] of Extended;
+  {$ELSE}
   TExtendedVector = array [0 .. cMaxArray] of Extended;
   TExtendedVector = array [0 .. cMaxArray] of Extended;
+  {$ENDIF}
 
 
   PPointerVector = ^TPointerVector;
   PPointerVector = ^TPointerVector;
   PPointerArray = PPointerVector;
   PPointerArray = PPointerVector;

+ 19 - 2
Source/GLS.VectorTypes.pas

@@ -25,6 +25,9 @@ uses
   Winapi.Windows;
   Winapi.Windows;
 
 
 type
 type
+
+// ===========  OpenGL types  ============
+
   TGLboolean = BYTEBOOL;
   TGLboolean = BYTEBOOL;
   PGLboolean = ^TGLboolean;
   PGLboolean = ^TGLboolean;
 
 
@@ -101,7 +104,8 @@ type
   TGLhalf = WORD;
   TGLhalf = WORD;
   PGLhalf = ^TGLhalf;
   PGLhalf = ^TGLhalf;
 
 
-  // Windows types
+// ========= Windows types ==============
+
   PWGLswap = ^TWGLswap;
   PWGLswap = ^TWGLswap;
   _WGLSWAP = packed record
   _WGLSWAP = packed record
     hdc: HDC;
     hdc: HDC;
@@ -112,13 +116,18 @@ type
   WGLSWAP = _WGLSWAP;
   WGLSWAP = _WGLSWAP;
   HPBUFFERARB = Integer;
   HPBUFFERARB = Integer;
 
 
-  (* These OpenCL's types are compatible with cl_context and cl_event *)
+(* These OpenCL's types are compatible with cl_context and cl_event *)
+
   T_cl_context = record end;
   T_cl_context = record end;
   P_cl_context = ^T_cl_context;
   P_cl_context = ^T_cl_context;
   T_cl_event = record end;
   T_cl_event = record end;
   P_cl_event = ^T_cl_event;
   P_cl_event = ^T_cl_event;
 
 
+
 type
 type
+
+// ===========  Vectors  ============
+
   //2
   //2
   TVector2d = record
   TVector2d = record
     case Integer of
     case Integer of
@@ -293,6 +302,11 @@ type
       1 : (X,Y,Z,W: Pointer);
       1 : (X,Y,Z,W: Pointer);
   end;
   end;
 
 
+  PGLVector = ^TGLVector;
+  TGLVector = TVector4f;
+
+// ===========  Matrices  ============
+
  TMatrix2d = record
  TMatrix2d = record
     case Integer of
     case Integer of
       0 : (V: array[0..1] of TVector2d);
       0 : (V: array[0..1] of TVector2d);
@@ -433,6 +447,9 @@ type
       1 : (M : TMatrix4f);
       1 : (M : TMatrix4f);
   end;
   end;
 
 
+  PGLMatrix = ^TMatrix4f;
+  TGLMatrix = TMatrix4f;
+
 //-----------------------------------------------  
 //-----------------------------------------------  
 implementation
 implementation
 //-----------------------------------------------  
 //-----------------------------------------------  

+ 8 - 6
Source/GLScene.inc

@@ -80,12 +80,14 @@
   {$DEFINE SUPPORT_WGL}
   {$DEFINE SUPPORT_WGL}
 {$ENDIF}
 {$ENDIF}
 
 
-{$IFDEF LINUX}
-  {$UNDEF SUPPORT_WGL}
-  {$UNDEF USE_ASM}
-  {$DEFINE UNIX}
-  {$DEFINE SUPPORT_GLX}
-  {$DEFINE X11_SUPPORT}
+{$IFNDEF CROSSVCL}
+  {$IFDEF LINUX}
+    {$UNDEF SUPPORT_WGL}
+    {$UNDEF USE_ASM}
+    {$DEFINE UNIX}
+    {$DEFINE SUPPORT_GLX}
+    {$DEFINE X11_SUPPORT}
+  {$ENDIF}
 {$ENDIF}
 {$ENDIF}
 
 
 // .NET
 // .NET

+ 4 - 2
Source/Physics.NGDRagdoll.pas

@@ -121,6 +121,8 @@ var
   p1, p2: TVector4f;
   p1, p2: TVector4f;
   d: single;
   d: single;
   Collision: PNewtonCollision;
   Collision: PNewtonCollision;
+  CollisionBox, CollisionCylinder, CollisionSphere: PNewtonCollision;
+  Matrix: Tmatrix;
   CollisionOffsetMatrix: TMatrix; // For cone capsule and cylinder
   CollisionOffsetMatrix: TMatrix; // For cone capsule and cylinder
 begin
 begin
   collisionOffsetMatrix := IdentityHmgMatrix;
   collisionOffsetMatrix := IdentityHmgMatrix;
@@ -138,9 +140,9 @@ begin
   SetLength(joints, actor.Skeleton.BoneCount - 1);
   SetLength(joints, actor.Skeleton.BoneCount - 1);
   for i := 0 to actor.Skeleton.BoneCount - 2 do
   for i := 0 to actor.Skeleton.BoneCount - 2 do
   begin
   begin
-    p1 := actor.Skeleton.BoneByID(i).GlobalMatrix.w;
+    p1 := actor.Skeleton.BoneByID(i).GlobalMatrix.W;
     if actor.Skeleton.BoneByID(i).BoneCount > 1 then
     if actor.Skeleton.BoneByID(i).BoneCount > 1 then
-      p2 := actor.Skeleton.BoneByID(i).Items[0].GlobalMatrix.w
+      p2 := actor.Skeleton.BoneByID(i).Items[0].GlobalMatrix.W
     else
     else
       p2 := p1;
       p2 := p1;
     p1 := VectorTransform(p1, actor.AbsoluteMatrix);
     p1 := VectorTransform(p1, actor.AbsoluteMatrix);