arkit_flutter_plugin icon indicating copy to clipboard operation
arkit_flutter_plugin copied to clipboard

[Question] Where is the pivot property?

Open James-A-White opened this issue 4 years ago • 5 comments

Just curious, on the SCNNode object there is a pivot property, I don't see that exposed in ARKit. I'm sure I must be missing something basic.

I'm trying to rotate text around its centerpoint and (evidently) to do that I need to access the pivot property.

Many thanks for the great package! I'm having so much fun working with AR!

James-A-White avatar Jun 19 '20 08:06 James-A-White

Unfortunately, it's not there yet. ARKit is huge, hence I'm adding the functionality only when someone needs it. It should be easy to bridge the pivot property, hence I'll do that right after I finish with another task.

olexale avatar Jun 25 '20 15:06 olexale

Excellent! Many thanks!

James-A-White avatar Jun 27 '20 17:06 James-A-White

Hey @olexale if you can guide me I can take this issue 😄

Rohithgilla12 avatar Jul 15 '20 07:07 Rohithgilla12

Hi @Rohithgilla12 . Sure, the code will be identical to any other node's property. You may pick, for example, position as a reference. The only difference is that the pivot is a matrix, hence you'll need to use not vector3 converter, but matrix4. Feel free to ping me in case of any questions. Thanks!!

olexale avatar Jul 15 '20 07:07 olexale

Sure, I will give it a try and ping you if I struck anywhere. I guess I need to make changes in this file https://github.com/olexale/arkit_flutter_plugin/blob/master/lib/arkit_node.dart and use one of the converter from https://github.com/olexale/arkit_flutter_plugin/blob/master/lib/utils/json_converters.dart

Awesome, can you assign the issue to me, I will start working on it.

Rohithgilla12 avatar Jul 15 '20 08:07 Rohithgilla12