• Dear Cerberus X User!

    As we prepare to transition the forum ownership from Mike to Phil (TripleHead GmbH), we need your explicit consent to transfer your user data in accordance with our amended Terms and Rules in order to be compliant with data protection laws.

    Important: If you accept the amended Terms and Rules, you agree to the transfer of your user data to the future forum owner!

    Please read the new Terms and Rules below, check the box to agree, and click "Accept" to continue enjoying your Cerberus X Forum experience. The deadline for consent is April 5, 2024.

    Do not accept the amended Terms and Rules if you do not wish your personal data to be transferred to the future forum owner!

    Accepting ensures:

    - Continued access to your account with a short break for the actual transfer.

    - Retention of your data under the same terms.

    Without consent:

    - You don't have further access to your forum user account.

    - Your account and personal data will be deleted after April 5, 2024.

    - Public posts remain, but usernames indicating real identity will be anonymized. If you disagree with a fictitious name you have the option to contact us so we can find a name that is acceptable to you.

    We hope to keep you in our community and see you on the forum soon!

    All the best

    Your Cerberus X Team

Vortex - Camera Picking and Project

Status
Not open for further replies.
Thanks again. I have added your code to my fork of Vortex at
Which will become the backend for our official 3D module.
When you say that Vortex will be the backend for the 3D module, do you mean that you want to add a layer on top of it with a different API? If that's the case, then we could take a different (and probably cleaner) approach: I could simplify Vortex to handle the lower level stuff, and you can integrate that with your API, with the entity / material / etc API that you like.
 
Last edited:
@MikeHart would you like me to merge your and innerloop's changes to main Vortex repo and continue working from there?

@JaviCervera of course, that would be great. If you would accept PRs on yours that would be awesome.

One thing you could look at , if oyu have time for it, is the LookAt command. Did I made a mistake there? Also, I have implemented methods for loading OBJ and B3D-Files directly. With B3D, it doesn't load the animation but static files so far are fine. It seems that I don't have the calculation of normals correct. A mesh doesn't look the same like when you first convert it with your meshtool.

When you say that Vortex will be the backend for the 3D module, do you mean that you want to add a layer on top of it with a different API?

Kinda like that. But I would not change Vortex for this. I am more after something to make it less wordy. For an example...
Cerberus:
floorObj = New Model(Mesh.CreateQuad(New Material(Texture.Load("environment/Tile1.png"))))

could be simpolified with

Cerberus:
floorObj = CreatePlane("environment/Tile1.png")

Things like that.
 
@JaviCervera
Great news :)
@MikeHart
For LookAt like in Blitz3D use this code:

[CODE lang="cerberus" title="add this to class Entity inside file "entity.cxs""]
Method LookAt:Void( targetPoint:Float[3], rollAngle:Float = 0.0 )
Local dirX := targetPoint[0] - mPosition[0]
Local dirY := targetPoint[1] - mPosition[1]
Local dirZ := targetPoint[2] - mPosition[2]
mRotation[0] = -ATan2( dirY, Sqrt( dirX * dirX + dirZ * dirZ ) )
mRotation[1] = ATan2( dirX, dirZ )
mRotation[2] = rollAngle
End

Method LookAt:Void( targetEntity:Entity, rollAngle:Float = 0.0 )
LookAt( targetEntity.mPosition, rollAngle )
End
[/CODE]

PS
I made a typo in code for "ProjectedY" function - it returns X component instead of Y :-(
 
Is there a possibility of adding animated .obj model import and thus not needing to use the model converter?
 
@Amon: FBX is a complex format. Supporting it would be easier if Vortex was written in C++, because we could use Assimp or Autodesk's FBX SDK to do the importing. Even although using meshtool requires an additional model conversion, I prefer this approach, since it generates a format optimized for Vortex. It would probably be easier to add animation support for the B3D loader MikeHart has already written. How good is B3D support nowadays in the most popular modelling applications?

@innerloop: That LookAt function seems correct. An implementation could also be done with the code in meshtool.cxs, lines 108-110, and the Vec3Pitch and Vec3Yaw functions at the end of that file. Actually, I could add a Vec3LookAt function to math3d.cxs.

@MikeHart: Please do a PR to branch release/2.0 and I'll review it later this week.
 
Last edited:
Ah missed that one. Thanks for your work. :)
 
I raised an issue about his latest published changes on github made it unusable over a month ago but so far no response. I hope he is OK but that doesn't look insuring.
 
Status
Not open for further replies.
Back
Top Bottom