Customize transform controls

We have an already customized transform-controls class, and we would need further work on it.
The working class can be seen here https://app.3dviewermax.com/

We need the rotation control to be able to snap to 0º, 90º, 180º & 270º on world coordinates with a 2º offset (from 89º to 91º should snap the object on 90º).

We hope to find someone to work with on long term basis, we have many of these tasks.

If interested please message me with the estimated hours to complete and expected hourly rate.

Here’s a rough example of how this can be achieved:

applyQuaternion(quaternion) {
const snapAngle = Math.PI / 2; // 90 degrees in radians

// Get Euler angles from the quaternion
const euler = new THREE.Euler().setFromQuaternion(quaternion, this.transformSpace);

// Round off the current angle to the nearest 90 degrees
euler.x = Math.round(euler.x / snapAngle) * snapAngle;
euler.y = Math.round(euler.y / snapAngle) * snapAngle;
euler.z = Math.round(euler.z / snapAngle) * snapAngle + (2 * snapAngle); // Add offset of 2 degrees

// Convert the Euler back to Quaternion and apply it
const snapQuat = new THREE.Quaternion().setFromEuler(euler, this.transformSpace);
this.object.quaternion.premultiply(snapQuat);
}

This should snap the rotation to the nearest 90-degree increment with an additional 2-degree offset in the Z-axis.

Dear @Juan_Renoldi
I have read your project post and I think this will be a good chance to make good relationship with you via more projects in the future.
I’m very excited to solve these problems and I love this type of work.
Let’s meet and discuss in more detail.
This is my contact info

Summary

skype: live:.cid.d3953209a5266c9a
discord: Crazy Manager#9491

Looking forward to your reply.
Best regards

This topic was automatically closed after 30 days. New replies are no longer allowed.