Forum

Notifications
Clear all

Making 3D widgets? Sure, its already there!

2 Posts
2 Users
2 Reactions
427 Views
Jon Lennart Aasenden
(@tao4all)
Posts: 44
Member Admin
Topic starter
 

Quartex pascal supports what is called "partial classes", which means that the implementation of a class can be spread out over multiple units -- and classes can even be extended with new methods (this is not the same as inheritance, just to be clear on that).

As such, if you add the unit "qtx.dom.sprite3d" to your form's uses clause (or any unit), all your TQTXWidget's will have 3d properties and methods!

How to

  • First, set the 3d options you would like (open up the unit and have a look)
  • Second, call Init3d() on the widget you want to have 3D features
  • Third, adjust the X, Y, Z and RotateX, RotateY, RotateZ (or ScaleX, ScaleY, ScaleZ) properties as you wish
  • Finally, call Update3d() to apply the values.

Here is a little video where I mess around with RotateZ during a window move, just for fun 🙂

https://www.youtube.com/watch?v=jpvZL85reHA

 
Posted : 15/04/2023 6:06 pm
dryphon and RTOlivier reacted
Topic Tags
(@rtolivier)
Posts: 6
Active Member
 

Niiice. Good job

 
Posted : 18/04/2023 6:37 pm
Share: