Is it possible to find objects collision and intersection?

Dear Friends,
I am noob in castle engine but I know Delphi,
At first please see this :slight_smile:
https://wordart.com/gallery
As you see this site can Javascript create Nesting Words cloud by putting text in 2D
I want an application to create something like this in 2D/3D by text and objects and export SVG/3DModel
Do you think is it possible?
Has Castle game engine enough functions for detecting Collision/Intersection irregular shapes to put No overlap objects?
Thank you for your time.

I want an application to create something like this in 2D/3D by text and objects and export SVG/3DModel

Note that, while we support a lot of input formats, we only support saving to X3D. It’s a 3D format, although you can of course also store 2D stuff there (just leave Z = constant 0). So not SVG.

Of course you have all the information to write export to SVG yourself.

Has Castle game engine enough functions for detecting Collision/Intersection irregular shapes to put No overlap objects?

We can detect collisions between mesh (any irregular shape, and each text letter has it’s own box) and a simple object (like axis-aligned box or sphere) using our octree structures.

If you don’t need to rotate words, then that’s enough. If you need to rotate them by any angle (like 45) then it’s not enough, and you would need to implement collision octree <->rotated rect yourself.

Note that I don’t think that simply checking for collisions is what you need. You need an algorithm that places the new word in a “smart” place among existing words. This algorithm should have a built-in knowledge about existing words anyway, as it not only has to avoid collisions, it also wants to “invent” a smart place to put the word.

Bottom line: sure you can use Castle Game Engine. Although, if it’s for offline generation, than I’m not sure do you need CGE. You will need a specialized algorithm for layout of the words, this is very application-specific anyway. But you can use CGE to visualize and/or export it to X3D, if that’s important in your case.