Jump to content

loss of precision collision, after scaling


photo

Recommended Posts

При масштабировании объектов, сильно теряется точность.

 

Отладочный пример:

 

1. basic players demo из EvaluationKIT

2. Добавить пирамиду, в основании квадрат 1*1 метр и высота 1 метр.

3. Подбежать actor(ом), коллизия точная, относительно.

4. Делаем масштабирование пирамиды по x, y, z в 5 раз.

5. Коллизия стала очень неточной.

 

Translate:

 

Debug sample:

1. Start basic players sample from EvaluationKIT browser.

2. Add new static mesh: pyramid with square 1*1 metr and height 1 metr.

3. Run and jump on it by PlayerActor, precision is normally.

4. Scale pyramid by x, y, z in 5 times.

5. Collision has been very inaccurate.

 

normal.bmpscale_bug.bmp

Link to comment

If you are going to use Physics (calculate collisions), do not scale meshes. It is valid both for physical objects (that are approximated with bodies and shapes) and non=physical meshes around them.

Link to comment

Sorry, physics and scaling does not go together. It was designed this way, because otherwise checking for collisions would've been too long and would have dropped the performance.

Link to comment

If you are going to use Physics (calculate collisions), do not scale meshes.

 

Which means that meshes have to be 'pre'-scaled in the modelling tool and multiple meshes have to be used when different scaling for same mesh geometry is required (which might be problematic if some dynamic scaling effect is required...)

Link to comment

Данная особенность нам критически необходима. На текущий момент при масштабированнии всё равно задействуются ресурсы компьютера, но при этом результат некорректный. Нужен корректный рассчёт коллизии, для масштабированных ObjectMesh. Можно сделать проверку по матрице трансформации и отключать блок алгоритма, если нет масштабированния, чтобы избежать потерь производительности для немасштабированных объектов.

 

Translate:

This feature is critical to us is required. At the moment when zooming all the same computer resources are utilized, but the result is incorrect. Need a correct calculation of collisions, scaled to ObjectMesh. You can do a background check on a matrix transformation on and off the block algorithm, if there is no scale to avoid loss of performance for unscaled objects.

Link to comment

Glad to see I'm not the only one who assumed this feature would be supported. If you could find a solution that allows scaled collisions to incur the penalty, but non-scaled to remain unaffected performance-wise, then it would be up to the user to determine whether or not to use scaled-collisions and incur the appropriate performance penalty.

Link to comment
  • 2 weeks later...

We can implement this feature for additional fee, if it's critical for your project (contact licensing@unigine.com for that). Otherwise it has very low priority since scaling of physical objects is not supported by design (and it is clearly stated in the documentation).

Link to comment
×
×
  • Create New...