I have checked tutorials here and Jan Horn demos but
the thing is too complicated for me;(
Could someone be so kind to write an app for me which
will preload for example 10 or more jpgs to memory
and be abble to display them one-by-one without page flickering?
I wish the jpgs would be like 1280x1024 or even 1600x1200.
I think OpenGL or DirectX etc would be the direction
for this application.
I wish to create a simple animation from these jpgs.
*C++ Builder 6* or Delphi would be the best for me.
I would kindly ask you to contact me by icq: 47223521
or by email: sp@sw.pl
Thank you!
Arek
Hallo Ich habe Tutorials hier und Jan Horn demos überprüft, aber die Sache ist für me zu schwierig:(
Könnte jemand so freundlich sein, eine APP für mich zu schreiben, welches 10 zum Beispiel oder mehr jpgs
zum Gedächtnis vorbelastet und abble ist, sie one-by-one anzuzeigen, ohne Seite zu flackern?
Ich denke, daß OpenGL oder DirectX usw. die Richtung für diese Anwendung sein würden.
Ich möchte eine einfache Animation von diesen jpgs verursachen.
* C++ Builder 6 * oder Delphi würde für mich das beste sein.
Ich würde Sie freundlich bitten, mit mir durch icq in Verbindung zu treten: 47223521
oder durch email: sp@sw.pl
Registriert: Do Sep 25, 2003 15:56 Beiträge: 7804 Wohnort: Sachsen - ERZ / C
Programmiersprache: Java (, Pascal)
Most of use are not fans of "alien coding", but we would help you to get the problem solved.
Yes you are right: OpenGL can do what you whant.
If you whant to use Delphi as language I can recommend glBitmap.pas from LossyX (our texture specialist).
But I'm not shure about the handling of that texture sizes. Because older grafic cards are used to "power of 2"-textures (means the size was for instance 512x512 or 1024x256 or something). But ... hmm ... I think even this is handled by glBitmap.pas.
The only thing you have to do is taking one of your templates an build a texture-manager on basis of the glBitmap.pas.
so far...
_________________ Blog: kevin-fleischer.de und fbaingermany.com
Registriert: Do Dez 05, 2002 10:35 Beiträge: 4234 Wohnort: Dortmund
I also think like Flash. We are not here to code your apps but we can help you to do it self.
For simple animations its possible to use texture_rectangle. In this case you dosn't have to perform any changes on the textures. Its really easy to implement it with the glbitmap loader. And the best its supported by older graphiccard.
If you are intrested to learn more we can help you.
You can modify it easily that it doesn't use the whole form but a panel for rendering. After you made this work, you will see your very first OpenGL output.
After this we will help you with this steps:
1. Changing perspective to ortho mode (glOrtho)
2. Displaying a white quad all over your rendering context (glBegin(GL_QUADS))
3. Loading Textures by using glBitmap.pas 4. Displaying Textures in your scene
After that small steps you will have your first picture rendered. Thats realy no big thing. It is more difficult do build a usable interface. But this is a problem you should be able to solve.
_________________ Blog: kevin-fleischer.de und fbaingermany.com
Well I doubt that Google has better skills concerning our language and as most(/all) of us are capable of reading and writing in english, it isn't necessary to translate your posts. In fact the german translation is a bit confusing ^^.
_________________ [18:30] tomok: so wie ich das sehe : alles. was nich was anderes ist als nen Essay ist nen Essay
hi, i'm a signature viruz, plz set me as your signature and help me spread
Registriert: Do Sep 25, 2003 15:56 Beiträge: 7804 Wohnort: Sachsen - ERZ / C
Programmiersprache: Java (, Pascal)
Ok...
Did the code you have, render something in your panel? A triangle ore something?
If no, look at this:
Code:
glBegin(GL_QUADS);
glVertex3f(-1,1,0);
glVertex3f(-1,-1,0);
glVertex3f(1,-1,0);
glVertex3f(1,1,0);
glEnd;
Put this inside of your "render" function. This will draw a rectangle on your screen. The rectangle is the basis for your pictures. The will be mapped on this rectangle as textures. So the rectangel is a kind of canvas.
After you have got the quad on your panel, we can move to Step 2: glOrtho.
Search in your code for gluPerspective and replace it with glOrtho(0,Panel.width,0,panel.height, 0,128);
When you start your app you will see nearly nothing. Because the resolution is now pixel precise. So the quad is only 2x2 pixel. You have to change the Vertex-Coords to (0,0)-(panel.width, panel.height). After that you will have the quad all over your panel.
(How should I do this Vertex-Coord-Transfor thing? Just look at the code above. You will find it out. But remark: The order of the coords is important and must be counter clockwise.)
_________________ Blog: kevin-fleischer.de und fbaingermany.com
Registriert: Do Sep 25, 2003 15:56 Beiträge: 7804 Wohnort: Sachsen - ERZ / C
Programmiersprache: Java (, Pascal)
First: Please use our pascal-tags. So much unformatted code nearly blinds us
Ok... let me look....
@1: This is possible.
@2: This is normal if you are in Ortho-Mode. The z-direction is used for stacking the different layers. It has nearly no effekt on the position. Its all White because your quad is now "fullscreen" on your panel. You see just the quad, nothing else.
@3: After you have loaded an bound the texture you must give so called texture coordinates. The comand for this is glTexCoord2f(). With glTexCoord(0,0) you map the upper left corner to the folowing vertex. With glTexCoord2f(0,1) you map the lower right corner to the following vertex, and so on. That means, you have to write glTexCoord3f(); glVertex3f(); inside your glBegin/glEnd block.
You also have to enable Texturing (glEnable(GL_TEXTURE_2D)). This should be done once at the beginning. And for your application you can let it enabled all over the time.
_________________ Blog: kevin-fleischer.de und fbaingermany.com
Registriert: Do Dez 05, 2002 10:35 Beiträge: 4234 Wohnort: Dortmund
Code:
fTexture.GenTexture(False);// i have put her "false" to skip texture 512x512 size check.
The optional Parameter has an reason. But only for advanced Developers they 100 percently know what they do. When you call GenTextures with True you get an exception. Is it Right? I think. When the glbitmap raised an error it has an reason.
In my earlier post i speak about an TextureRectangle extension. To use this extension you must told the glbitmap to use an other target for the texture. It looks like so.
Code:
fTexture.Target:= GL_TEXTURE_RECTANGLE_ARB;
fTexture.GenTexture(True);
Please open the glBitmap an go to Line 2226 and remove the (* and *) from the line.
TexRec :=(GL_ARB_texture_rectangle or GL_EXT_texture_rectangle or GL_NV_texture_rectangle)and
An the Same in line 3077.
I must comment these extension because our header dosnt supported it at this time. But i have implemented it in our 2.0 header. On ATI graphiccards only the EXT version of the TextureRectangle extension is supported.
The next thing you must do ist to set your Texturecoordinates. For Texture without TextureRectangle the coordinates are between 0 and 1. With TextureRectangle they were between 0 and the Height or the Width of the image. In you code it must look like.
Mitglieder in diesem Forum: 0 Mitglieder und 9 Gäste
Du darfst keine neuen Themen in diesem Forum erstellen. Du darfst keine Antworten zu Themen in diesem Forum erstellen. Du darfst deine Beiträge in diesem Forum nicht ändern. Du darfst deine Beiträge in diesem Forum nicht löschen. Du darfst keine Dateianhänge in diesem Forum erstellen.