You can also use glTexSubImage2D to copy your 456x340 image onto 512x512 texture. Do something like this during your OpenGL initialization
//bind 512x512 texture...
Type: Posts; User: grudzio
You can also use glTexSubImage2D to copy your 456x340 image onto 512x512 texture. Do something like this during your OpenGL initialization
//bind 512x512 texture...
Thanks for checking it with wine.
I think that it depends if the x11 system is present and if SDL will use its x11 code.
I am planning to add support for linux as soon I have it installed. I don't have access to a mac machine, so I am not able to make macosx version.
Hello everyone,
I have created a small add-on that allows creating OpenGL 3 context for SDL 1.2. It uses dglOpenGL.pas header and, for now, is Windows only. So if you don't want to wait for a SDL...
I think that this error is caused by wrong version/format of the sdl.o file. Therefore deleting it and compiling again should work.
Maybe the win and linux fpc linkers require different format of...
If you do not have to use img element, you can use the background attribute of the div. Something like this:
<div style="width:100px;height:100px;background:url(image.jpg) no-repeat center...
You can speed up terrain rendering by using triangle strips instead of quads. It is a bit tricky because you have to draw odd rows of terrain in one direction and event in opposite one. Here is...
Oops, I have confused left side with a right side (it sometimes happens to me). What I meant is that on the left side of the equation you have an acceleration and on the right side sum of forces....
My two cents. I don't like the part about Weight. Near the surface of the Earth gravity force (weight) is equal to objects mass m multiplied by earth acceleration g.
FG=mg g=9.81 m/s2.
Of course...
You do not have to calculate integrals given in the Wikipedia article for a simple airplane simulation. Those integrals describe the moment of inertia (or to be more precise moment of inertia tensor)...
You can use SDL_putenv function to force SDL to use an existing window instead of creating its own. Look for the SDL_WINDOWID flag.
JEDI-SDL package also comes with an example. It is located in...
Actually, FPC comes with a utility for doing cleanup - delp. It is not configurable at the moment, so point for You :).
On Linux one can also use fpcmake to create makefiles, to enjoy the full...
Actually I am on PC (Windows XP) :). I've tried it on Firefox 3.6 and everything is ok. So it looks like this second sprite of Julian is an Opera issue :(.
Nice little game. Add more levels and it will be really fun to play.
It worked perfectly in my Opera 10.10, but did not start in IE 6. Only title image appeared and nothing more.
Few comments:
...
It is located in the Search menu, last position from the bottom (at least in 0.9.26 version).
The shortcut key is Alt-G.
Yes, the formula for a normal vector is incorrect. The normal vector is a vector of length one which is perpendicular to the object it is calculated for (line in your case).
A function for finding...
The line
procedure TVerletSystem.Update
...
Item[i].Force := Item[i].Mass * Force;
...
looks susopicious to me (units don't match :)). Since the force acting on the item is multiplied by its...
I like the "jedism" answer.
You can make all procedures in class2 that should be available only to class1 private. Private methods and fields can be accessed by any other class in the same unit file.
First thing that comes to my mind is to leave constructors as they are and add Init procedure with dofferent parameters. So the code would look like this.
type
TClass1 = class;
...
If You want something more flexible, You can use class objects to create any object derived from TClass1. But it requires that all constructors have same list of parameters. Here is a sample code:
...
How about using JSON? It is not as powerfull as YAML but there are two toolkits for Delphi/FPC available.
Are You sure it is Event.Key.KeySym.Mod not Event.Key.KeySym.Modifier?
I think you should check for release event like this:
flags := GetKeyEventFlags(K);
if (flags and kbReleased) <> 0 then
writeln('Released key event'):
I suspect that since flags is a byte...
It crashes on mine.
If it is going to be cross platform You probably should use smpeg (or other cross platform video library).
There is a demo how to use smpeg with OpenGL in the JEDI_SDL...