[fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread James Richters
I'm curious if Freepascal has any package available that would calculate X,Y screen pixels based on 3D X,Y,Z data at some given rotations. I'm using Agg-Pas with PTC-Graph in a console application on Windows. I'm not sure what the technical term is for figuring out what pixels are used to r

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Sven Barth via fpc-pascal
James Richters schrieb am Di., 17. Sep. 2019, 16:15: > I'm curious if Freepascal has any package available that would calculate > X,Y screen pixels based on 3D X,Y,Z data at some given rotations. I'm > using Agg-Pas with PTC-Graph in a console application on Windows. I'm not > sure what the

[fpc-pascal] Talkback and detecting touch events

2019-09-17 Thread Mgr. Janusz Chmiel
Please would somebody of us try to tell Me, if Android API functions can detect how many fingers have been used to touch The display even while Talkback screen reader work ane Explore by touch service is communicating with display? I do not want to use graphical mode, since it require that Talkba

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Graeme Geldenhuys
On 17/09/2019 3:10 pm, James Richters wrote: > I'm not sure what the technical term is for figuring out what pixels > are used to represent 3D coordinates on a 2D screen, but I'm hoping > maybe there is something that just does the calculations that I can > use https://en.wikipedia.org/wiki/Ray_tr

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Ryan Joseph
What exactly are you trying to do? Usually if you’re doing 3D this all happens on the GPU and you get back a color/depth buffer. Maybe you need to know where a 2D coordinate is in 3D space? > On Sep 17, 2019, at 10:10 AM, James Richters > wrote: > > I'm curious if Freepascal has any package a

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread James Richters
>What exactly are you trying to do? Usually if you’re doing 3D this all happens >on the GPU and you get back a color/depth buffer. Maybe you need to know where >a 2D coordinate is in 3D space? What I'm trying to do is much simpler than rendering a 3D object.. All I'm trying to do is display a

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Gustavo Enrique Jimenez
A simple transformation is: P3D=(X,Y,Z) P2D=(x,y) x=X+Y*0.707 y=Y*0.707+Z I did not tried it, but I think that this is the transformation that you are looking for. Gustavo El mar., 17 sept. 2019 a las 17:37, James Richters () escribió: > > >What exactly are you trying to do? Usually if you’re

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Wolf
What you are trying to do is write a very simple CAD program. Have a look at this link , which gives the basic formulae and also Pascal routines to do it. Wolf On 18/09/19 2:10 AM, James Richters wrote: I'm curious if Freepasc

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Karoly Balogh (Charlie/SGR)
Hi, On Tue, 17 Sep 2019, James Richters wrote: > What I'm trying to do is much simpler than rendering a 3D object.. All > I'm trying to do is display a 3D line drawing or wireframe on the > screen. I don't need it to dynamically rotate or anything, and it > doesn't need to show any surfaces, te

Re: [fpc-pascal] Talkback and detecting touch events

2019-09-17 Thread Thomas Young via fpc-pascal
Hi, Years ago I had a career as a technical illustrator. First analog then digital. Perhaps the following code I developed back around 1992 might be helpful to you. H = Horizontal coordinate on picture plane. V = Vertical coordinate on picture plane. XYZ = 3D coordinate. distance = "camera" d

Re: [fpc-pascal] Calculating Pixels to represent 3D coordinates

2019-09-17 Thread Thomas Young via fpc-pascal
This is an isometric projection I use: var H1 = (Y - X) * 0.86602 + ScreenOrgin_H; var V1 = (X + Y) * 0.5 - Z + ScreenOrgin_V; Thomas Young 330-256-7064 Sent from my iPhone > On Sep 17, 2019, at 4:53 PM, Gustavo Enrique Jimenez > wrote: > > A simple transformation is: > > P3D=(X,Y,Z) > P2D=(x