Delphi base compatibility, Spine improvements, other stuff :)

Posted on

Delphi running CGE base test :)
  1. Intensive work on the engine Delphi compatibility is ongoing 🙂

    We can now actually compile and run in Delphi (10.2) a simple console demo using our “base” units. Vectors, matrices, colors, rectangles, time measuring, logging, a lot of string and class and other utilities… it’s all working in Delphi. This is the demo code.

    In parallel, I’m fixing the syntax of all the code to compile in “FPC Delphi test mode”, this is providing a nice baseline to later compile in the actual Delphi. On this front, I almost finished porting everything non-visual (I’m finishing the X3DNodes unit, which is a huge unit that depends on almost everything non-visual in the engine). So, we’re close 🙂

    The “FPC Delphi test mode” means that we use FPC, but in Delphi mode, and disable macros, and disable operators like += etc. And I can run on Linux too, which is comfortable for me 🙂 So it’s like “make FPC behave as much as Delphi”. Any changes required at this stage would be required by Delphi too. To use it, you can set environment variable CASTLE_ENGINE_TEST_DELPHI_MODE to “true” before running the build tool.

  2. Units cleanup was done along the way. I rearranged some units, to remove some uncomfortable dependencies (when too many units are inter-dependent on each other). In effect, we now have a “files” unit group that includes units from old group “net” + units dealing with files. More details in the units map in the wiki.

  3. Spine (2D animations format) improvements:

    1. When animating in Spine using Bezier curves (translations or rotations), the resulting movement in our engine is now exactly what you see in Spine.
    2. Animating the scale in Spine is now fixed (it was accidentally changing the order of layers).
  4. DDS (image file format) improvements: support reading DX10 + DXGI_FORMAT_R8G8B8A8_UNORM case (produced e.g. by PowerVR Texture Tools when converting RGBA image to DDS).

  5. In a spur of the moment, I wrote a short page about “What are range and overflow checks (and errors) in Pascal” 🙂

  6. TDebug3D class is a new simple approach to visualize debug things attached to 3D objects.

One Reply to “Delphi base compatibility, Spine improvements, other stuff :)”

Leave a Reply

Your email address will not be published. Required fields are marked *