Answer the question
In order to leave comments, you need to log in
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?
Answer the question
In order to leave comments, you need to log in
its zero point relative to its coordinate system
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 questionAsk a Question
731 491 924 answers to any question