I have an elevation dataset with elevation values of -32768 to 32767. I'm testing this dataset with smaller map sizes, so I need to scale the vertical axis so the map isn't insanely spikey. I did so...
Type: Posts; User: kevinfishburne
I have an elevation dataset with elevation values of -32768 to 32767. I'm testing this dataset with smaller map sizes, so I need to scale the vertical axis so the map isn't insanely spikey. I did so...
Just a sad attempt at humor, or at least being passive-aggressive. Ignoring all that, I hope the code I came up with is reasonably correct for my purpose.
This seems to work:
Dim cs As Single
Dim sn As Single
Dim x As Single
Dim y As Single
Dim px As Single
Dim py As Single
I have some code:
' Update solar light source direction.
SolarPosition[0] = Unknown
SolarPosition[1] = 0
SolarPosition[2] = 1
SolarPosition[3] = 0
Gl.Lightfv(Gl.LIGHT0, Gl.POSITION,...
Awesome. I'm assuming the output of a shader call can "spread" across the many pixels of a quad or other geometry by referencing vertices as you mentioned. Sounds like doing per-pixel software...
Nothing's completely out of the picture, although being a jack of all trades (and master of none) and being solely responsible for the entire project I am limited in how much time I can spend on any...
I'm trying to make this driver independent, so NVIDIA can suck it with their extensions if they're not supported by other OpenGL-compliant cards. Good to know, though, thanks. :)
I applied the...
To follow up, it appears that linear fog is the problem. EXP2 with a precise density parameter seems to work well. Why in the world would linear fog, which has the most intuitive parameters (start,...
I did that and the difference seems to make no sense. This is the order of operations of what I think is the relevant code:
' Set projection mode.
Gl.MatrixMode(Gl.PROJECTION)
...
I'm trying to implement fog and it appears as though FOG_START and FOG_END values are being ignored by Fogf. It also appears as though the resulting fog begins at zero of the modelview matrix's Z...
Thanks for the tips on handling materials. Got those figure out now. :)
I'll be ordering a hard copy from Amazon, although the online version didn't have as much information as I thought in...
I made some progress in that I created a function to calculate the surface normal of a triangle:
Public Function Normal(p1 As Single[], p2 As Single[], p3 As Single[]) As Single[]
'...
Here are the Convert.RotateX and Convert.RotateY functions so the main procedure is more complete:
Public Function RotateX(PWOX As Single, PWOY As Single, OriginX As Single, OriginY As Single,...
I am rendering a grid of quads to represent a section of a landscape. Each quad has its own separate texture (required) and elevation. I use an averaging algorithm so the vertices of a given quad...
Got it to work by manually offsetting and rotating the vertices rather than fudging around with matrices:
Public Sub Texture3D(Group As String, Optional ID As Short, Optional SubID As Byte,...
It's funny; when I first read that it was straight Chinese, but after working on my game for a while and re-reading it I actually mostly understand you. That will come in handy when I eventually...
Interesting. I had avoided trying GluLookAt() because like a fool I assumed that it would just "point" at a coordinate and not also translate the scene. I now have this code, which does what I was...
I posted this question in the GAMBAS user mailing list, archived here: http://old.nabble.com/gb3%3A-OpenGL-Rotate-and-Translate-logic-td33886871.html I'll completely rewrite it here out of respect...