Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can i use the output .ply files on Unity with textures? #29

Closed
Jacky-MYQ opened this issue Oct 27, 2023 · 2 comments
Closed

How can i use the output .ply files on Unity with textures? #29

Jacky-MYQ opened this issue Oct 27, 2023 · 2 comments

Comments

@Jacky-MYQ
Copy link

Dear Lukas,
I sincerely appreciate it that you can answer my plain questions patiently.
Now, I have another question that though i successfully got a geometry with textures in Meshlab, i actually want to open ply files in the Unity and it just displays a gray geometry again. Because ply files can not import in Unity directly, I change ply format into fbx format and obj format but it doesn't work. It is also just a gray geometry without any textures.
I try to use many methods as they said in Google but it doesn't work. So I have to ask you to obtain some solutions. I would like to kown whether you have any solutions. If you can do me a favor, I am sincerely grateful to you again!!!

@lukasHoel
Copy link
Owner

Unfortunately I do not have experience with Unity, but there must be a solution for sure... ^^ sorry, can't help with this

@Jacky-MYQ
Copy link
Author

Luckily, I used Point Cloud Free Viewer which is in Unity Assets store to succeefully open the file of .off format with textures(I use Meshlab to change .ply format into .off format ).
My step is as follow:
First, I download Point Cloud Free Viewer in Unity Hub. Then you need to open Unity , click "Window"->"Package Manager", import Point Cloud Free Viewer.
Scendly, you need to add "EnablePointSize.cs" to "Main Camera" as a componet. Then create a new "GameObject" and add "PointCloudManager.cs" to "GameObject" as a componet too. (This step may occur an error which may say "Can't add script component ..... because script class cannot be found. Make sure that ...... " My solution is that i reopen the Unity and it will put a small window which basically means to update something. I clicked "yes" and then the error disappeared. )
Thirdly, in your "Point Cloud Manager" componet, amend "Data Path" using your .off file path and select "VertexColor" in "Mat Vertex". Then click run button and you will see your geometry with textures.
Hoping this will help you guys!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants