I'm still not "getting" what you're trying to explain.
I have a Viewport3D. It has a certain physical size on the screen - X pixels by Y pixels. The Viewport3D has an orthographic camera with a position, an up direction a look direction etc. Here's the XAML describing my Viewport3D...
Is there an implicit view volume from which I can determine the width and height for the OrthoRH Matrix in your previous answer?
And here's some sample C# to draw some lines . . .
... now these particular lines just outline the Viewport3D (see the attachment). So what I want to know is, for a given Point3D in the coordinate system of the polyLineVisual3D's in the code, where will that appear in pixel-space in the Viewport3D? Thanks in advance.
I have a Viewport3D. It has a certain physical size on the screen - X pixels by Y pixels. The Viewport3D has an orthographic camera with a position, an up direction a look direction etc. Here's the XAML describing my Viewport3D...
Code:
<dxControls:DXViewportView Name="MainViewportView" PresentationType="DirectXImage" Margin="230,70,20,170" ClipToBounds="true">
<Viewport3D Name="MainViewport" >
<Viewport3D.Camera>
<OrthographicCamera LookDirection="0,0,-1" Position="0,0,10" UpDirection="0, 1, 0" />
</Viewport3D.Camera>
</Viewport3D>
</dxControls:DXViewportView>Is there an implicit view volume from which I can determine the width and height for the OrthoRH Matrix in your previous answer?
And here's some sample C# to draw some lines . . .
Code:
Point3D point3Da = new Point3D(-0.99, 0.6, -5);
Point3D point3Db = new Point3D(-0.99, -0.6, -5);
Point3D point3Dc = new Point3D(0.99, -0.6, -5);
Point3D point3Dd = new Point3D(0.99, 0.6, -5);
Point3D point3De = new Point3D(0.0, 0.0, -5);
allPositions.Add(point3Da);
allPositions.Add(point3Db);
allPositions.Add(point3Dc);
allPositions.Add(point3Dd);
allPositions.Add(point3De);
var simplePositionCollection = new Point3DCollection(allPositions);
int size = simplePositionCollection.Count;
MainViewport.BeginInit();
MainViewport.Children.Clear();
var polyLineVisual3D = new Ab3d.Visuals.PolyLineVisual3D()
{
Positions = simplePositionCollection,
LineColor = Colors.DarkOrange,
LineThickness = 3, // was 1 - made it 3 so see better on screen shots
Transform = new TranslateTransform3D(0, 0, 0)
};
MainViewport.Children.Add(polyLineVisual3D);
MainViewport.EndInit();... now these particular lines just outline the Viewport3D (see the attachment). So what I want to know is, for a given Point3D in the coordinate system of the polyLineVisual3D's in the code, where will that appear in pixel-space in the Viewport3D? Thanks in advance.

