필터 지우기
필터 지우기

How to get xyz coordinates of a 3d object

조회 수: 8 (최근 30일)
Paula Daella
Paula Daella 2015년 9월 22일
답변: Anandh 2019년 6월 21일
I need to get the xyz coordinate points of a 3d object that I've loaded in MATLAB.
So far, I've been able to load the .stl file and I can already rotate it. The part I'm having trouble in is getting the xyz coordinates of the object before rotating it.
Basically, what I need is to get the xyz coordinate points in that blue line, rotate it, and then get the xyz coordinates again, and so on, and so forth until I got all the xyz coordinates of the 3d object.
Is it possible to do this? And can anyone point me in the right direction?
I'm sorry because I'm fairly new to Matlab and 3d processing.
Thanks in advance!
  댓글 수: 6
Walter Roberson
Walter Roberson 2015년 9월 22일
I am known by many names but Matthew is not one of them ;)
I will need to think about an implementation. Are the faces all in a consistent "handedness" that allow you to know which way is inside? Consistent orientation is needed for proper lighting so they might be in consistent order in the model file. Consistent order allows some linear algebra approaches to determine whether a given point is inside or outside.
Paula Daella
Paula Daella 2015년 9월 22일
Oops, I'm sorry. I don't know where I got Matthew from. :) It looks like I need to take a little break from this project.
I'm not really sure I know the answer to your question. But I will try to think about it and get back to you on that. Thank you.

댓글을 달려면 로그인하십시오.

답변 (2개)

Walter Roberson
Walter Roberson 2015년 9월 22일
So create a cubiod grid of the x and y points you want to test together with z sampled over a fine enough interval for your purpose. Then put the grid through the above routine along with the geometry. This will voxelize the geometry into binary inside or outside test. Then for any given row and column indices the positions where the third dimension is true are the coordinates you are looking for.
  댓글 수: 1
Paula Daella
Paula Daella 2015년 9월 22일
I get it in theory and I will try to implement it. Thanks for this Walter!

댓글을 달려면 로그인하십시오.


Anandh
Anandh 2019년 6월 21일
Hi, I need a help. I have a 3D MRI data. I want to get the x,y,z coordinate matrices of the data. Can you please help me?
Thanks in advance!
Anandh.

카테고리

Help CenterFile Exchange에서 STL (STereoLithography)에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by