0
Click Rotation
This discussion was imported from CodePlex
chimou wrote at 2013-05-14 18:52:
First of all I would like to thank you for this great job.
In my scene i have tow superposed CubeVisual3D like this :
<ht:CubeVisual3D x:Name="plateau" Width="140" Length="180" Height="15" Center="0 0 -5" TopFace="False" BottomFace="False" Fill="SteelBlue">
<ht:BindableRotateManipulator x:Name="Rotation1" InnerDiameter="1" Diameter="5" Length="175" Position="0 70 2 " Color="SteelBlue"
thank you in advance
In my scene i have tow superposed CubeVisual3D like this :
<ht:CubeVisual3D x:Name="plateau" Width="140" Length="180" Height="15" Center="0 0 -5" TopFace="False" BottomFace="False" Fill="SteelBlue">
<ht:CubeVisual3D.Children>
<ht:GridLinesVisual3D Width="140" Length="180" MinorDistance="5" Center="0 0 -11" Fill="SteelBlue"></ht:GridLinesVisual3D>
</ht:CubeVisual3D.Children>
</ht:CubeVisual3D>
<ht:CubeVisual3D x:Name="Cover" Width="140" Length="180" Height="15" Center="0 0 10" TopFace="False" BottomFace="False" Fill="#4C58ABF0">
<ht:CubeVisual3D.Children>
<ht:GridLinesVisual3D Width="140" Length="180" MinorDistance="5" Center="0 0 17" Fill="SteelBlue" Thickness="1"></ht:GridLinesVisual3D>
</ht:CubeVisual3D.Children>
</ht:CubeVisual3D>
for this moment i rotate le outside CubeVisual3D called "Cover" like this :
<ht:BindableRotateManipulator x:Name="Rotation1" InnerDiameter="1" Diameter="5" Length="175" Position="0 70 2 " Color="SteelBlue"
Value="{Binding CoverRotateValue}"
Axis="-1 0 0" AllowDrop="True" TargetTransform="{Binding ElementName=Cover, Path=Transform}">
I want please enable rotation by a click on the Cube called "Cover", Is It possible ??
thank you in advance
objo wrote at 2013-06-07 11:54:
CubeVisual3D
is based on ModelVisual3D
and does not support click events. I think you need to create a Visual3D based on
ModelUIElement3D
to handle mouse clicks on a cube. Try setting
IsHitTestVisible = false
on the manipulator to disable it (but I think a "Enabled" property on the
Manipulator
class could be a good idea!)Customer support service by UserEcho