E
E
Evgeny Ivanovich2019-09-21 23:36:26
Game development
Evgeny Ivanovich, 2019-09-21 23:36:26

How to correctly calculate the position of an object?

There is an object, its zero point relative to its coordinate system, the maximum point of the physical object and the minimum point of the physical object. It is necessary to arrange this object in space so that it does not intersect with another object. How to do this if there is only a raytracer-a position and a function for obtaining objects in a cube by two points?
945A6F775D1CF89C937A8F7D140BC89C3AC0DB93

Answer the question

In order to leave comments, you need to log in

2 answer(s)
G
Griboks, 2019-09-22
@Griboks

its zero point relative to its coordinate system

This is his coordinate system.
What it is? Maximum of what? An object is an incalculable thing.
What kind of position is this?
And what is this function?
Perhaps you should attach a sketch to make it clearer. And on this wording, I can advise you to read about physics engines and collision detection.

M
maaGames, 2019-09-22
@maaGames

It is impossible to reconstruct an arbitrarily oriented parallelepiped from two points. The zero point will not help in any way, because. it can be seen that for different objects it is in different places and is not tied to the bounding cube.
The Coordinate System of each object is needed (most likely either in the form of a matrix, or as two or three unit vectors). Then, using the zero point of the object, and the position of the min-max points in the Local Coordinate System, it will be possible to construct a cube rotated in space in any form necessary for calculations.
Is it because of the math problems that HalfLife 3 is being delayed?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question