Position of points in an isometric image after rotationGetting point-coordinates after a rotationcalculate out-of-plane and in-plane rotation from virtual camera position.Find center of rotation after object rotated by known angle (2D)New angle formed after rotating pipeSquare's angle of rotation using 4 cornersImage after Rotation in Geometry???Geometric : Distance after Rotation 2DCalculate image rotation to correct for camera angleCalculate the position of two points based on direction and midpoint.How to rotate relative points in degrees?
How to deal with fear of taking dependencies
Finding files for which a command fails
What do the Banks children have against barley water?
Doomsday-clock for my fantasy planet
What's the difference between repeating elections every few years and repeating a referendum after a few years?
Is it legal to have the "// (c) 2019 John Smith" header in all files when there are hundreds of contributors?
Is it wise to focus on putting odd beats on left when playing double bass drums?
Crop image to path created in TikZ?
How can I fix this gap between bookcases I made?
Manga about a female worker who got dragged into another world together with this high school girl and she was just told she's not needed anymore
Hosting Wordpress in a EC2 Load Balanced Instance
What to wear for invited talk in Canada
What does 'script /dev/null' do?
What does it exactly mean if a random variable follows a distribution
"My colleague's body is amazing"
What are the advantages and disadvantages of running one shots compared to campaigns?
Why was the "bread communication" in the arena of Catching Fire left out in the movie?
Symmetry in quantum mechanics
How to make payment on the internet without leaving a money trail?
Eliminate empty elements from a list with a specific pattern
Does bootstrapped regression allow for inference?
If a centaur druid Wild Shapes into a Giant Elk, do their Charge features stack?
COUNT(*) or MAX(id) - which is faster?
Check if two datetimes are between two others
Position of points in an isometric image after rotation
Getting point-coordinates after a rotationcalculate out-of-plane and in-plane rotation from virtual camera position.Find center of rotation after object rotated by known angle (2D)New angle formed after rotating pipeSquare's angle of rotation using 4 cornersImage after Rotation in Geometry???Geometric : Distance after Rotation 2DCalculate image rotation to correct for camera angleCalculate the position of two points based on direction and midpoint.How to rotate relative points in degrees?
$begingroup$
I'm developing a game using isometric images for the units.
Each units has weapons represented in red on the first image below.
To attach animations to the weapons, I have to be able to calculate the position of each of those points after a rotation of X degrees (units move in 8 directions).
The isometric view is set with an angle of 45 degrees top down :
Points on the image for the main angle
My goal is to find a way to manually spot the red dots on one angle, and then apply a mathematical transformation to get the position of those points for all others angles.
Image after a rotation
Image after an other rotation
I have no clue on how to approach the problematic and I'd be happy to get some help here !
The 3 images are properly scaled if you want to give it a try.
Here is the first point coordinates in pixels on each image, from the top left corner (0,0) :
Point A - 0 degree rotation : (89,522)
Point A - 45 degree rotation : (573,550)
Point A - 90 degree rotation : (609,207)
So the goal is to have (89,522) and deduce (573,550) and (609,207) from that.
Thanks a lot !
G.
Edit :
It seems that a rotation on one frame around a given center point would not work as shown in that picture, probably because of the 45 degree top down angle.
rotations
$endgroup$
add a comment |
$begingroup$
I'm developing a game using isometric images for the units.
Each units has weapons represented in red on the first image below.
To attach animations to the weapons, I have to be able to calculate the position of each of those points after a rotation of X degrees (units move in 8 directions).
The isometric view is set with an angle of 45 degrees top down :
Points on the image for the main angle
My goal is to find a way to manually spot the red dots on one angle, and then apply a mathematical transformation to get the position of those points for all others angles.
Image after a rotation
Image after an other rotation
I have no clue on how to approach the problematic and I'd be happy to get some help here !
The 3 images are properly scaled if you want to give it a try.
Here is the first point coordinates in pixels on each image, from the top left corner (0,0) :
Point A - 0 degree rotation : (89,522)
Point A - 45 degree rotation : (573,550)
Point A - 90 degree rotation : (609,207)
So the goal is to have (89,522) and deduce (573,550) and (609,207) from that.
Thanks a lot !
G.
Edit :
It seems that a rotation on one frame around a given center point would not work as shown in that picture, probably because of the 45 degree top down angle.
rotations
$endgroup$
add a comment |
$begingroup$
I'm developing a game using isometric images for the units.
Each units has weapons represented in red on the first image below.
To attach animations to the weapons, I have to be able to calculate the position of each of those points after a rotation of X degrees (units move in 8 directions).
The isometric view is set with an angle of 45 degrees top down :
Points on the image for the main angle
My goal is to find a way to manually spot the red dots on one angle, and then apply a mathematical transformation to get the position of those points for all others angles.
Image after a rotation
Image after an other rotation
I have no clue on how to approach the problematic and I'd be happy to get some help here !
The 3 images are properly scaled if you want to give it a try.
Here is the first point coordinates in pixels on each image, from the top left corner (0,0) :
Point A - 0 degree rotation : (89,522)
Point A - 45 degree rotation : (573,550)
Point A - 90 degree rotation : (609,207)
So the goal is to have (89,522) and deduce (573,550) and (609,207) from that.
Thanks a lot !
G.
Edit :
It seems that a rotation on one frame around a given center point would not work as shown in that picture, probably because of the 45 degree top down angle.
rotations
$endgroup$
I'm developing a game using isometric images for the units.
Each units has weapons represented in red on the first image below.
To attach animations to the weapons, I have to be able to calculate the position of each of those points after a rotation of X degrees (units move in 8 directions).
The isometric view is set with an angle of 45 degrees top down :
Points on the image for the main angle
My goal is to find a way to manually spot the red dots on one angle, and then apply a mathematical transformation to get the position of those points for all others angles.
Image after a rotation
Image after an other rotation
I have no clue on how to approach the problematic and I'd be happy to get some help here !
The 3 images are properly scaled if you want to give it a try.
Here is the first point coordinates in pixels on each image, from the top left corner (0,0) :
Point A - 0 degree rotation : (89,522)
Point A - 45 degree rotation : (573,550)
Point A - 90 degree rotation : (609,207)
So the goal is to have (89,522) and deduce (573,550) and (609,207) from that.
Thanks a lot !
G.
Edit :
It seems that a rotation on one frame around a given center point would not work as shown in that picture, probably because of the 45 degree top down angle.
rotations
rotations
edited Mar 23 at 5:47
giviz
asked Mar 22 at 14:26
givizgiviz
33
33
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
$begingroup$
You need to know not just the angle of the rotation, but also what axis the rotation is about. A 30 degree rotation about the x-axis is going to give a much different location than a 30 degree rotation about the y-axis. And a rotation about the y-axis passing through the ankles is going to give a different result than the same rotation about the y-axis passing through the shoulders.
Game developers tend to prefer quaternion to matrix notation for these rotations, and I find it hard to believe you don't already such rotations built into your application. If you really haven't worked out how to move the camera around, then I urge you to put aside your immediate problem and start working your way through the wealth of material out there that explains how it's done, because it is far more than I (or anyone else) can adequately explain in a forum post.
I don't have much need for 3D rotations, so I never remember how quaternion rotation works, but if you are interested, this is how it works by vectors:
Suppose you want to rotate the point $mathbf p$ by $theta$ degrees about the axis passing through the point $mathbf q$ and extending in the direction of the vector $hat n$, where $|hat n| = 1$, and $theta$ is positive when rotating in the same direction as the fingers of your right-hand curl when your extended thumb points in the direction of $hat n$.
Let $mathbf o = mathbf q + ((mathbf p - mathbf q)cdot hat n)hat n$ and let $vec p = mathbf p - mathbf o$ be the vector pointing to $mathbf p$ from $mathbf o$. Then $mathbf o$ is the point on the axis of rotation that is closest to $mathbf p$, and $vec p$ is perpendicular to $hat n$. Let $vec r = hat n times vec p$. The rotated point that you want is
$$mathbf p' = mathbf o + vec pcos theta + vec rsintheta $$
FYI - the reason for the somewhat unusual mixture of bold and $to$ notation is that the bold letters represent points in space, while $vec v$ represents a vector (direction and magnitude only). And the hat notation $hat n$ is a common way of denoting unit vectors.
$endgroup$
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
1
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
return StackExchange.using("mathjaxEditing", function ()
StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
);
);
, "mathjax-editing");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "69"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
noCode: true, onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3158204%2fposition-of-points-in-an-isometric-image-after-rotation%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
$begingroup$
You need to know not just the angle of the rotation, but also what axis the rotation is about. A 30 degree rotation about the x-axis is going to give a much different location than a 30 degree rotation about the y-axis. And a rotation about the y-axis passing through the ankles is going to give a different result than the same rotation about the y-axis passing through the shoulders.
Game developers tend to prefer quaternion to matrix notation for these rotations, and I find it hard to believe you don't already such rotations built into your application. If you really haven't worked out how to move the camera around, then I urge you to put aside your immediate problem and start working your way through the wealth of material out there that explains how it's done, because it is far more than I (or anyone else) can adequately explain in a forum post.
I don't have much need for 3D rotations, so I never remember how quaternion rotation works, but if you are interested, this is how it works by vectors:
Suppose you want to rotate the point $mathbf p$ by $theta$ degrees about the axis passing through the point $mathbf q$ and extending in the direction of the vector $hat n$, where $|hat n| = 1$, and $theta$ is positive when rotating in the same direction as the fingers of your right-hand curl when your extended thumb points in the direction of $hat n$.
Let $mathbf o = mathbf q + ((mathbf p - mathbf q)cdot hat n)hat n$ and let $vec p = mathbf p - mathbf o$ be the vector pointing to $mathbf p$ from $mathbf o$. Then $mathbf o$ is the point on the axis of rotation that is closest to $mathbf p$, and $vec p$ is perpendicular to $hat n$. Let $vec r = hat n times vec p$. The rotated point that you want is
$$mathbf p' = mathbf o + vec pcos theta + vec rsintheta $$
FYI - the reason for the somewhat unusual mixture of bold and $to$ notation is that the bold letters represent points in space, while $vec v$ represents a vector (direction and magnitude only). And the hat notation $hat n$ is a common way of denoting unit vectors.
$endgroup$
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
1
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
add a comment |
$begingroup$
You need to know not just the angle of the rotation, but also what axis the rotation is about. A 30 degree rotation about the x-axis is going to give a much different location than a 30 degree rotation about the y-axis. And a rotation about the y-axis passing through the ankles is going to give a different result than the same rotation about the y-axis passing through the shoulders.
Game developers tend to prefer quaternion to matrix notation for these rotations, and I find it hard to believe you don't already such rotations built into your application. If you really haven't worked out how to move the camera around, then I urge you to put aside your immediate problem and start working your way through the wealth of material out there that explains how it's done, because it is far more than I (or anyone else) can adequately explain in a forum post.
I don't have much need for 3D rotations, so I never remember how quaternion rotation works, but if you are interested, this is how it works by vectors:
Suppose you want to rotate the point $mathbf p$ by $theta$ degrees about the axis passing through the point $mathbf q$ and extending in the direction of the vector $hat n$, where $|hat n| = 1$, and $theta$ is positive when rotating in the same direction as the fingers of your right-hand curl when your extended thumb points in the direction of $hat n$.
Let $mathbf o = mathbf q + ((mathbf p - mathbf q)cdot hat n)hat n$ and let $vec p = mathbf p - mathbf o$ be the vector pointing to $mathbf p$ from $mathbf o$. Then $mathbf o$ is the point on the axis of rotation that is closest to $mathbf p$, and $vec p$ is perpendicular to $hat n$. Let $vec r = hat n times vec p$. The rotated point that you want is
$$mathbf p' = mathbf o + vec pcos theta + vec rsintheta $$
FYI - the reason for the somewhat unusual mixture of bold and $to$ notation is that the bold letters represent points in space, while $vec v$ represents a vector (direction and magnitude only). And the hat notation $hat n$ is a common way of denoting unit vectors.
$endgroup$
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
1
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
add a comment |
$begingroup$
You need to know not just the angle of the rotation, but also what axis the rotation is about. A 30 degree rotation about the x-axis is going to give a much different location than a 30 degree rotation about the y-axis. And a rotation about the y-axis passing through the ankles is going to give a different result than the same rotation about the y-axis passing through the shoulders.
Game developers tend to prefer quaternion to matrix notation for these rotations, and I find it hard to believe you don't already such rotations built into your application. If you really haven't worked out how to move the camera around, then I urge you to put aside your immediate problem and start working your way through the wealth of material out there that explains how it's done, because it is far more than I (or anyone else) can adequately explain in a forum post.
I don't have much need for 3D rotations, so I never remember how quaternion rotation works, but if you are interested, this is how it works by vectors:
Suppose you want to rotate the point $mathbf p$ by $theta$ degrees about the axis passing through the point $mathbf q$ and extending in the direction of the vector $hat n$, where $|hat n| = 1$, and $theta$ is positive when rotating in the same direction as the fingers of your right-hand curl when your extended thumb points in the direction of $hat n$.
Let $mathbf o = mathbf q + ((mathbf p - mathbf q)cdot hat n)hat n$ and let $vec p = mathbf p - mathbf o$ be the vector pointing to $mathbf p$ from $mathbf o$. Then $mathbf o$ is the point on the axis of rotation that is closest to $mathbf p$, and $vec p$ is perpendicular to $hat n$. Let $vec r = hat n times vec p$. The rotated point that you want is
$$mathbf p' = mathbf o + vec pcos theta + vec rsintheta $$
FYI - the reason for the somewhat unusual mixture of bold and $to$ notation is that the bold letters represent points in space, while $vec v$ represents a vector (direction and magnitude only). And the hat notation $hat n$ is a common way of denoting unit vectors.
$endgroup$
You need to know not just the angle of the rotation, but also what axis the rotation is about. A 30 degree rotation about the x-axis is going to give a much different location than a 30 degree rotation about the y-axis. And a rotation about the y-axis passing through the ankles is going to give a different result than the same rotation about the y-axis passing through the shoulders.
Game developers tend to prefer quaternion to matrix notation for these rotations, and I find it hard to believe you don't already such rotations built into your application. If you really haven't worked out how to move the camera around, then I urge you to put aside your immediate problem and start working your way through the wealth of material out there that explains how it's done, because it is far more than I (or anyone else) can adequately explain in a forum post.
I don't have much need for 3D rotations, so I never remember how quaternion rotation works, but if you are interested, this is how it works by vectors:
Suppose you want to rotate the point $mathbf p$ by $theta$ degrees about the axis passing through the point $mathbf q$ and extending in the direction of the vector $hat n$, where $|hat n| = 1$, and $theta$ is positive when rotating in the same direction as the fingers of your right-hand curl when your extended thumb points in the direction of $hat n$.
Let $mathbf o = mathbf q + ((mathbf p - mathbf q)cdot hat n)hat n$ and let $vec p = mathbf p - mathbf o$ be the vector pointing to $mathbf p$ from $mathbf o$. Then $mathbf o$ is the point on the axis of rotation that is closest to $mathbf p$, and $vec p$ is perpendicular to $hat n$. Let $vec r = hat n times vec p$. The rotated point that you want is
$$mathbf p' = mathbf o + vec pcos theta + vec rsintheta $$
FYI - the reason for the somewhat unusual mixture of bold and $to$ notation is that the bold letters represent points in space, while $vec v$ represents a vector (direction and magnitude only). And the hat notation $hat n$ is a common way of denoting unit vectors.
answered Mar 22 at 23:25
Paul SinclairPaul Sinclair
20.8k21543
20.8k21543
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
1
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
add a comment |
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
1
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Thank you for your response, I should have mentioned that it's a 2D game so I haven't had to work with the camera. The sprites are made from a 3D model where a script rotate it and take an image on each angle. The rotation point is on the center of the model, so we know it's position. The 45 degree top down angle make things even more complicated. My initial though was that as the rotation point is fixed, all points might be located on a given circle around that center on the 1st image, and if we have one point we can determine the circle and so all others positions. Does that make any sense ?
$endgroup$
– giviz
Mar 23 at 5:39
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
$begingroup$
Well nan, I've added a picture 4 with such circle, and that's not a valid method, probably because of the top down angle.
$endgroup$
– giviz
Mar 23 at 5:49
1
1
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
You have a 3D model. You HAVE to treat the points you are trying to track as 3D points. Once you've thrown out that 3rd dimension of information, you can't get it back, and it is necessary to get the locations right. Identify the points in your 3D model where your weapons are. Then for each orientation, rotate the 3D points first, then project it to your iso view to get the 2D coordinates.
$endgroup$
– Paul Sinclair
Mar 23 at 14:06
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
Yeah that make sense. Thank you, I'd look into the 3D software to see if I can find a way to get those points coordinates there instead of using rotation calculations.
$endgroup$
– giviz
Mar 23 at 14:46
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
$begingroup$
@giviz The projected path of a point on the rotating model is going to be an ellipse in general.
$endgroup$
– amd
Mar 24 at 19:50
add a comment |
Thanks for contributing an answer to Mathematics Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
Use MathJax to format equations. MathJax reference.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmath.stackexchange.com%2fquestions%2f3158204%2fposition-of-points-in-an-isometric-image-after-rotation%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown