I am trying to use multiple custom objects to be placed on the face using ARCore SDK. I import the face mesh FBX file provided by Google in the SDK using Blender and place my custom object relative to the face mesh. then I remove the face mesh and export the object as .obj file to be used inside my app.
However, the object is not shown at the position I placed it at relative to the face mesh.
I am using sceneform to render the object on the face.
Any idea what I am doing wrong?
Google Documentation for adding custom objects
I followed the same hierarchy google provided, I left the bones and removed the face mesh and set the main asset as a parent to my object,
but still the object is not placed correctly on the face.
Blender Screenshot
I added a modifier and vertex group as shown in the screenshot. I also reassigned the pivot point of the object to be the same as the face anchor, but sill not shown in the desired position
I don't know if you figured it out, but for me I had the same issue, what I did was adjust my object relative to people's face instead of google's presets, which may be out of place inside blender.
Now that may not be the best approach because it means you are constantly testing and moving the object in blender to then import to the app, but it works for me.
To circunvent this, I made my own guidelines inside blender, for my specific use case, and place new objects relative to this "custom guide".
Related
I am getting free 3d models from some sites. I have to place a Hat,Mask,and Spectacles like an object on my face. But my models are not rendering properly on face. Sometimes it renders above expected position or sometimes not in exact depth. How can I make this model set properly? I am importing models in blender for placing models with reference to canonical_face_mesh.fbx. If possible, please give some extension export specific guide from blender.Thanks.
To properly place 3D model (whether it's a hat, or a mask, or a glasses) on a detected face in ARCore you have to translate a pivot point of a model to the place where a facial anchor resides (keeping the correct offset from where the 3D object should be). In other words, model's pivot must meet a face's anchor.
I tried to place an object on face. But does not understand how to set depth in object.
Like when I add 3d object like spects frames on face.
It does not show in correct depth.
When you use Augmented Faces feature, it's worth to note that if any face is detected, ARCore at first puts a Face Anchor (which must be located behind a nose or, more precise to say, inside a skull), and secondly ARCore puts a canonical mask – its pivot point resides on the same place as anchor does.
Hence, if you wanna place your glasses at the appropriate depth – set a pivot point of your 3D object the same way it was set on a canonical mask. In other words – marry these pivot points.
Another way of doing this is getting the canonical face mesh from here
https://github.com/google-ar/arcore-android-sdk/blob/master/assets/canonical_face_mesh.fbx
And as described very nicely here on this blog post by Kristina Simakova:
https://creativetech.blog/home/try-on-glasses-arcore-augmented-faces
In blender you can set whatever model you want at any place on that face mesh,
while also maintaining scale, which is very important.
Also very important is this part:
Following the instructions from ARCore documentation, add the glass
model under “asset“ object. Check out this short tutorial to learn
about parenting in Blender.
How can I place a plane with infinite length using arcore.
I want to do exactly like this github discussion URL.
The I found solution for unity ARCore sdk : link.
So how can I achieve that using java?
I think you're mixing up two different elements.
in ARCore you have a plane which is mapped surface on which you can put your objects. Examples you've provided are referring to GameObject. You can put as big "plane" as wide/long area you've mapped using your camera. Because first, you need to map the surface. Of course you can put as big GameObject as you want but this is
If you want to treat a detected plane as infinite, you can use Plane.isInExtent to check whether a Pose is in this plane.
If you want to use this in combination with some Sceneform UX functionality, you could create an own version of TranslationController that uses isInExtent instead of isInPolygon (the default way).
I want to recreate AR measurement app using ARCore and OpenGL without sceneform. Is there any way to display text and anchor it to another object like the image below?
Yup, you can see a preview of it here : reference and example.
You can use ViewRenderable Class from AR Core
Your text should be an object like everything that you draw on the screen. Then using sceneform you can place and anchor in reference to another anchor. Check out the solar system example that is provided with sceneform SDK. You have there a perfect example of putting multiple objects in relation each to another and also an example of placing overlays with text.
I have displayed a 3d object on top of Ui Image, and applied lean touch library on 3d object for moving, scaling and rotating the object. The issue is I am able to scale and rotate the object but cannot move it. I am missing anything?
Cannot comment yet, so I need to put there as an answer.
In one of my projects, I was using a TouchKit Unity3D tool. It has many features like rotating and moving objects.
to move your 3d object, you need to use LeanTranslate script and add it to your 3d object.