LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   2d/3d rendering (https://www.linuxquestions.org/questions/programming-9/2d-3d-rendering-6285/)

Jeffrey 09-06-2001 08:24 AM

2d/3d rendering
 
how should i go about rendering graphics? i get just about everything in programming but how to go about rendering graphics!!! wtf should i do? write a sub program to draw certain types of objects on the screen? like write a subprogram and do something like:

Render object.ball (where render is a script to load a graphic and put it where object.ball.ypos and object.ball.xpos is or something?!?!!?)

oh well, i suck at programming. itd be cool to at least make a small sidescroller on turbo-pascal though.

(or actually finish that rpg)

:)

isajera 09-06-2001 11:44 PM

well.. if you first learned graphics programming in turbo pascal (like i did), then programming under linux is going to be a bit of a nasty shock. it's not the easiest - what you probably want to do is download a few example programs for Xlib, and work from there. another useful package to learn, and much easier to work with, would be opengl. the best thing to do tho, is just to look around the source code of some programs and learn from them.

Jeffrey 09-20-2001 08:26 AM

opengl is a library for compiling programs with isnt it?
where can i find something like that for c?

isajera 09-20-2001 07:37 PM

open gl is a library package for c - like <stdio.h> or <system/types.h> - it's usually <gl/gl.h> or something like that. i haven't used it in a few months and can't remember right off the top of my head.
you might want to find a book on open gl - there are two books that are considered the defacto bibles for gl - they're commonly referred to as the green book and the red book. both by some guy named mark or mike k-something. kilgard i think. again, can't remember off the top of my head. :) they're both good, but the green one is specifically for gl and X-windows.


All times are GMT -5. The time now is 04:33 AM.