Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Offline PavelB  
#1 Posted : Sunday, March 30, 2014 4:23:29 PM(UTC)
PavelB

Joined: 5/18/2012(UTC)
Posts: 5

I have tried Windows Form Sample and according to the code it should go from Vector.Zero to Vector.One, in other words from (0,0) to (1, 1). My assumption was that it will draw line from 1 corner to another. However, I might miss something. Can you explain me the reason I see it differently that I think it should be?
You can find the snapshot here https://onedrive.live.co...r?resid=EA55413E711E171A!6080&authkey=!AESVy02I2LtXqfU&v=3&ithint=photo%2c.bmp

Wanna join the discussion?! Login to your forum accountregister a new account. Or Connect via Facebook Twitter Google

Offline Michael Koch  
#2 Posted : Sunday, March 30, 2014 6:56:25 PM(UTC)
Michael Koch

Joined: 12/27/2013(UTC)
Posts: 41
Location: Regensburg

Thanks: 3 times
Was thanked: 1 time(s) in 1 post(s)
PavelB, I think this could be related to the screenspace concept that DE uses.
Please see here: http://www.deltaengine.net/learn/screenspace

MiKo
Offline mc-kay  
#3 Posted : Monday, March 31, 2014 12:21:19 PM(UTC)
mc-kay

Medals: Admin

Joined: 8/24/2011(UTC)
Posts: 138
Location: Hannover

Thanks: 1 times
Was thanked: 12 time(s) in 7 post(s)
Yes, this belongs to the relative screen space that you are using.
If you want to draw a straight line across the screen you have to do something like this:
Code:
var screenSpace = Resolve<ScreenSpace>();
var topLeft = screenSpace.TopLeft;
var bottomRight = screenSpace.BottomRight;
new Line2D(topLeft, bottomRight, Color.Red);
Offline PavelB  
#4 Posted : Monday, March 31, 2014 12:56:56 PM(UTC)
PavelB

Joined: 5/18/2012(UTC)
Posts: 5

Cool, I didn't know about it. I have tried the code and it does work as expected. I will read a little bit more about it and will try to understand it.
Rss Feed  Atom Feed
Users browsing this topic
OceanSpiders 2.0
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2018, Yet Another Forum.NET
This page was generated in 0.071 seconds.