How do you rotate a 3D model using HelixToolkit?Why does two Transform do not work with a Helix Toolkit ObjectHow do you give a C# Auto-Property a default value?How do I enumerate an enum in C#?How to get StackPanel's children to fill maximum space downward?MVVM: Tutorial from start to finish?How to import a 3D model in WPF using Helix Toolkit?ReSharper “Cannot resolve symbol” even when project buildsWhy not inherit from List<T>?Rotate an object in HelixViewport3D in a WPF appHelix toolkit Rotate 3D ModelHow to rotate 3D model automatically in helix WPF
How could empty set be unique if it could be vacuously false
Subtract the Folded Matrix
Boss wants someone else to lead a project based on the idea I presented to him
"What is the maximum that Player 1 can win?"
Why does independence imply zero correlation?
Do I have to explain the mechanical superiority of the player-character within the fiction of the game?
Is there a difference between an NFC and RFID chip?
How does DC work with natural 20?
I found a password with hashcat, but it doesn't work
In the US, can a former president run again?
I just entered the USA without passport control at Atlanta airport
What happened to Hopper's girlfriend in season one?
What are the current battlegrounds for people’s “rights” in the UK?
What are Elsa's reasons for selecting the Holy Grail on behalf of Donovan?
How many people are necessary to maintain modern civilisation?
Is "Busen" just the area between the breasts?
Dmesg full of I/O errors, smart ok, four disks affected
Is the continuity test limit resistance of a multimeter standard?
Umlaut character order when sorting
Why does Linux list NVMe drives as /dev/nvme0 instead of /dev/sda?
Print one file per line using echo
Covering index used despite missing column
Can I enter the UK for 24 hours from a Schengen area, holding an Indian passport?
What are the pros and cons for the two possible "gear directions" when parking the car on a hill?
How do you rotate a 3D model using HelixToolkit?
Why does two Transform do not work with a Helix Toolkit ObjectHow do you give a C# Auto-Property a default value?How do I enumerate an enum in C#?How to get StackPanel's children to fill maximum space downward?MVVM: Tutorial from start to finish?How to import a 3D model in WPF using Helix Toolkit?ReSharper “Cannot resolve symbol” even when project buildsWhy not inherit from List<T>?Rotate an object in HelixViewport3D in a WPF appHelix toolkit Rotate 3D ModelHow to rotate 3D model automatically in helix WPF
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
I need some help rotating a 3D model in a WPF project on visual studios. I have imported the model in through the use of the helix toolkit. But I can not find any example of how to rotate the 3D model online. I've found some C# and xaml examples but they mainly seem to rotate the camera not the model.
c# wpf helix-3d-toolkit
add a comment |
I need some help rotating a 3D model in a WPF project on visual studios. I have imported the model in through the use of the helix toolkit. But I can not find any example of how to rotate the 3D model online. I've found some C# and xaml examples but they mainly seem to rotate the camera not the model.
c# wpf helix-3d-toolkit
add a comment |
I need some help rotating a 3D model in a WPF project on visual studios. I have imported the model in through the use of the helix toolkit. But I can not find any example of how to rotate the 3D model online. I've found some C# and xaml examples but they mainly seem to rotate the camera not the model.
c# wpf helix-3d-toolkit
I need some help rotating a 3D model in a WPF project on visual studios. I have imported the model in through the use of the helix toolkit. But I can not find any example of how to rotate the 3D model online. I've found some C# and xaml examples but they mainly seem to rotate the camera not the model.
c# wpf helix-3d-toolkit
c# wpf helix-3d-toolkit
edited Feb 26 at 19:06
zeitnot
1,068925
1,068925
asked Feb 26 at 16:12
ArashArash
33
33
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
WPF 3D Rotation
Create a RotateTransform3D for your GeometryModel3D.Transform
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
add a comment |
I have found it particularly useful to use matrices in order to make tranformations.
In my case, what I noticed was that usually if you apply a transformation such as a RotateTransform3D, and then apply another transformation using your model's '.transform' property, it overrides the last transform. In most cases, you want the new transformation to be applied over the last one.
This is how I make my rotations:
Vector3D axis = new Vector3D (1,0,0) //In case you want to rotate it about the x-axis
Matrix3D transformationMatrix = model.Content.Transform.Value; //Gets the matrix indicating the current transformation value
transformationMatrix.Rotate(new Quaternion(axis, angle)) //Makes a rotation transformation over this matrix
model.Content.Transform = new MatrixTransform3D(transformationMatrix); //Applies the transformation to your model
Don't forget, if you want the model to rotate on it's own center, instead of '.Rotate', use '.RotateAt' like such:
transformationMatrix.RotateAt(new Quaternion(axis, angle), modelCenter); //modelCenter is the Point3D variable indicating the center
add a comment |
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
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
,
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%2fstackoverflow.com%2fquestions%2f54889775%2fhow-do-you-rotate-a-3d-model-using-helixtoolkit%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
WPF 3D Rotation
Create a RotateTransform3D for your GeometryModel3D.Transform
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
add a comment |
WPF 3D Rotation
Create a RotateTransform3D for your GeometryModel3D.Transform
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
add a comment |
WPF 3D Rotation
Create a RotateTransform3D for your GeometryModel3D.Transform
WPF 3D Rotation
Create a RotateTransform3D for your GeometryModel3D.Transform
answered Feb 27 at 18:05
Lance HLance H
451169
451169
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
add a comment |
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
Would this work even if I'm importing in a model using the helix tool kit.
– Arash
Feb 27 at 20:27
add a comment |
I have found it particularly useful to use matrices in order to make tranformations.
In my case, what I noticed was that usually if you apply a transformation such as a RotateTransform3D, and then apply another transformation using your model's '.transform' property, it overrides the last transform. In most cases, you want the new transformation to be applied over the last one.
This is how I make my rotations:
Vector3D axis = new Vector3D (1,0,0) //In case you want to rotate it about the x-axis
Matrix3D transformationMatrix = model.Content.Transform.Value; //Gets the matrix indicating the current transformation value
transformationMatrix.Rotate(new Quaternion(axis, angle)) //Makes a rotation transformation over this matrix
model.Content.Transform = new MatrixTransform3D(transformationMatrix); //Applies the transformation to your model
Don't forget, if you want the model to rotate on it's own center, instead of '.Rotate', use '.RotateAt' like such:
transformationMatrix.RotateAt(new Quaternion(axis, angle), modelCenter); //modelCenter is the Point3D variable indicating the center
add a comment |
I have found it particularly useful to use matrices in order to make tranformations.
In my case, what I noticed was that usually if you apply a transformation such as a RotateTransform3D, and then apply another transformation using your model's '.transform' property, it overrides the last transform. In most cases, you want the new transformation to be applied over the last one.
This is how I make my rotations:
Vector3D axis = new Vector3D (1,0,0) //In case you want to rotate it about the x-axis
Matrix3D transformationMatrix = model.Content.Transform.Value; //Gets the matrix indicating the current transformation value
transformationMatrix.Rotate(new Quaternion(axis, angle)) //Makes a rotation transformation over this matrix
model.Content.Transform = new MatrixTransform3D(transformationMatrix); //Applies the transformation to your model
Don't forget, if you want the model to rotate on it's own center, instead of '.Rotate', use '.RotateAt' like such:
transformationMatrix.RotateAt(new Quaternion(axis, angle), modelCenter); //modelCenter is the Point3D variable indicating the center
add a comment |
I have found it particularly useful to use matrices in order to make tranformations.
In my case, what I noticed was that usually if you apply a transformation such as a RotateTransform3D, and then apply another transformation using your model's '.transform' property, it overrides the last transform. In most cases, you want the new transformation to be applied over the last one.
This is how I make my rotations:
Vector3D axis = new Vector3D (1,0,0) //In case you want to rotate it about the x-axis
Matrix3D transformationMatrix = model.Content.Transform.Value; //Gets the matrix indicating the current transformation value
transformationMatrix.Rotate(new Quaternion(axis, angle)) //Makes a rotation transformation over this matrix
model.Content.Transform = new MatrixTransform3D(transformationMatrix); //Applies the transformation to your model
Don't forget, if you want the model to rotate on it's own center, instead of '.Rotate', use '.RotateAt' like such:
transformationMatrix.RotateAt(new Quaternion(axis, angle), modelCenter); //modelCenter is the Point3D variable indicating the center
I have found it particularly useful to use matrices in order to make tranformations.
In my case, what I noticed was that usually if you apply a transformation such as a RotateTransform3D, and then apply another transformation using your model's '.transform' property, it overrides the last transform. In most cases, you want the new transformation to be applied over the last one.
This is how I make my rotations:
Vector3D axis = new Vector3D (1,0,0) //In case you want to rotate it about the x-axis
Matrix3D transformationMatrix = model.Content.Transform.Value; //Gets the matrix indicating the current transformation value
transformationMatrix.Rotate(new Quaternion(axis, angle)) //Makes a rotation transformation over this matrix
model.Content.Transform = new MatrixTransform3D(transformationMatrix); //Applies the transformation to your model
Don't forget, if you want the model to rotate on it's own center, instead of '.Rotate', use '.RotateAt' like such:
transformationMatrix.RotateAt(new Quaternion(axis, angle), modelCenter); //modelCenter is the Point3D variable indicating the center
answered Mar 25 at 6:52
Hassnain AliHassnain Ali
737
737
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- 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.
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%2fstackoverflow.com%2fquestions%2f54889775%2fhow-do-you-rotate-a-3d-model-using-helixtoolkit%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