For bugs and new features, use the issue tracker located at GitHub.
Also try the chat room!
AddPolygon wrong number of normals
murray_b wrote at 2012-01-30 05:07:
Hi
I am trying to display a mesh created from a polygon.
But when I run the toMesh I am getting the message "Wrong number of normals" And I am not sure what that message is referring to.
List<Point3D> vrt = new List<Point3D>(); // Create a list of Points for (int i = 0; i < set.Count(); i++) { vrt.Add( new Point3D ( (double)set[i].X, (double)set[i].Y, (double)set[i].Z )); } var surface = new MeshBuilder(); surface.AddPolygon(vrt); var mesh = surface.ToMesh();
Any help will be greatly appreciated. I am very new to WPF 3D and am finding the learning curve quite steep.
Thanks a lot
Murray
objo wrote at 2012-01-30 08:41:
hi Murray,
I see this can be a bit confusing, it should be improved..
The parameterless MeshBuilder constructor will create a mesh with both normals and texture coordinates. The AddPolygon will currently only add vertices, not normals and texture coordinates.
I think changing the constructor to
new MeshBuilder(false,false)
should work.
I think there are two possible improvements here
a. Let AddPolygon calculate normals and texture coordinates if this is requested
b. Remove the parameterless constructor of MeshBuilder - so you _have to_ specify if normals/texture coordinates should be generated
murray_b wrote at 2012-01-31 09:07:
Thanks for the quick reply Objo
That fixed the error I was getting.
Great work!
murray_b wrote at 2012-01-31 09:34:
Objo
When the meshbuilder now creates the mesh I can only see it from one side.
How do I get the meshbuilder to generate a mesh that I can rotate around and see from both sides?
Regards
Murray
objo wrote at 2012-01-31 10:01:
Remember to set the BackMaterial, it can be the same as the (front) Material.
Helix Sharpdx
eonxxx wrote at 2014-01-30 22:54:
i tried to integrate parts of source code from deferred shading demo into my own app.
cproject compiles well. but at runtime i get following error:
error registering effect: sharpdx_direct3d11_effects_x86.dll
where in the project path should the file located and how shuld i register it to my project?
thanks
eonxxx
objo wrote at 2014-02-02 12:06:
http://www.microsoft.com/en-us/download/details.aspx?id=6812
http://sharpdx.org/download/
This is a fork and I am not sure about the build requirements for it at the moment.
eonxxx wrote at 2014-02-02 21:38:
Examples (whole fork) compiled well and all the examples run fine.
eonxxx wrote at 2014-02-28 22:52:
thanks eonxxx
VishwaPrasad wrote at 2014-07-25 13:37:
I was also got the same error in my standalone application, I have copied sharpdx_direct3d11_effects_x86.dll file in bin folder. and issue has resolved.
But , when I test SharDX on XBAP, same issue occur, even I copied the dlls also , but issue still persist.
Can anyone help on this.
Thanks
Vishwa
Samples
saphua wrote at 2011-02-24 09:14:
I can't find any downloads for the samples?
Edit: Never mind, found them in the source code. Personally, i think that's a little confusing. But then again I can understand making sepperate downloads of each sample is a lot of work.
objo wrote at 2011-02-24 13:57:
you are right, the examples are changed/added frequently - so I haven't made any downloads yet. I'll make a download for the examples at release 1.0!
how to make chart like this
Has anyone tried to load Helix WPF into an Open Inventor project
Obviously devil will be in the details. Has anyone tried to do this?
Thanks,
<ht:PanoramaCube3D Source="Models\GrandHotel\"/> Its giving XML PARSE EXCEPTION
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:ht="clr-namespace:HelixToolkit.Wpf;assembly=HelixToolkit.Wpf"
Title="MainWindow" Height="350" Width="525">
<Grid>
<ht:HelixViewport3D x:Name="view1" RenderOptions.BitmapScalingMode="HighQuality" RenderOptions.EdgeMode="Aliased" ShowViewCube="False" ShowCameraTarget="False" CameraMode="FixedPosition" RotationSensitivity="0.6">
<ModelVisual3D>
<ht:PanoramaCube3D Source="Models\GrandHotel\"/>
<ModelVisual3D.Content>
<AmbientLight Color="White"/>
</ModelVisual3D.Content>
</ModelVisual3D>
</ht:HelixViewport3D>
</Grid>
</Window>
How to make RTS camera?
Overlord123 wrote at 2012-01-03 19:21:
Is it possible to create a RTS camera, like in Starcraft II etc?
objo wrote at 2012-01-03 19:55:
sorry, I have no experience with Starcraft or any other real time strategy games, so I don't know what is needed. Do you need camera translation by WASD keys?
can this link help (from irrlicht 3d)? http://www.irrlicht3d.org/wiki/index.php?n=Main.RTSCameraByCmdKewin
Overlord123 wrote at 2012-01-03 20:27:
Yeah, basically the feature set of the linked camera is what I need.
- No vertical translation
- Translates with WASD keys, (right mouse button and arrow keys)
- Translates with mouse movement on border screen. Left, Right, Up and Down
- Zooms with wheel (and right-left mouse buttons)
- Ability to recenter itself around a node
- define min and max zoom levels
- define boundaries for translation so it does not translate outside the map.
I put not so important stuff in brackets. Is this possible to realize with the Helix 3D Toolkit?
Thanks.
objo wrote at 2012-01-03 21:09:
This should be included in the 'walkaround' camera mode - I have not tested it after latest camera control refactorings, might need some updates...
http://helixtoolkit.codeplex.com/wikipage?title=Input%20gestures&referringTitle=Documentation
RotateManipulator help please
badgerbadger wrote at 2011-12-14 16:41:
I am attempting to code a RotateManipulator in C# codebehind (not xaml) to add rotateable and translateable planes on a double click event.
How would this line from ManipulatorDemo / MainWindow.xaml line 185 be coded in c#?
<ht:RotateManipulator Color="Blue" Axis="0,0,1" Transform="{Binding Transform, ElementName=plane2}" TargetTransform="{Binding Transform, ElementName=plane2}" Diameter="1"/>
It is the syntax of the binding transforms that I am struggling with (I am new to wpf if you haven't guessed)
Thanks! badgerbadger.
objo wrote at 2011-12-14 19:26:
use the SetBinding method
http://msdn.microsoft.com/en-us/library/system.windows.frameworkelement.setbinding.aspx
badgerbadger wrote at 2011-12-15 10:11:
Thanks, I had been using that but not getting it to work. Attempted to code ManipulatorDemo / MainWindow.xaml line 185 as
var plane = new RectangleVisual3D();
plane. etc
var manip = new RotateManipulator();
...
BindingOperations.SetBinding(manip, RotateManipulator.TransformProperty, new Binding("Transform") { ElementName = "plane" });
BindingOperations.SetBinding(manip, RotateManipulator.TargetTransformProperty, new Binding("Transform") { ElementName = "plane" });
and other combinations of setBinding but get "System.Windows.Data Error: 4 : Cannot find source for binding with reference 'ElementName=plane'"...
Apologies if this is a newbie wpf error but not finding much relevant on the web
How to 'dampen' RMouse 'scrolling'?
BogusException wrote at 2014-07-29 21:13:
I can't seem to find where I would make my right-mouse-drag rotation of objects a little less quick/severe.
In other words, how much rotation I get with RMouse down moving 1", I'd like to actually take 3"-in other words, less sensitive to mouse.
Any ideas?
TIA!
pat
:)
everytimer wrote at 2014-07-30 19:35:
LeftRightRotationSensitivityI'm not sure if this is what you were looking for, let us know if this helped! Good luck
RotationSensitivity
BogusException wrote at 2014-07-30 21:17:
pat
:)
Customer support service by UserEcho