Jump to content
  • Advertisement


  • Content count

  • Joined

  • Last visited

Community Reputation

211 Neutral

About jdaniel

  • Rank
  1. I've been trying to build up a texture library in order to texture map my levels. I brought my digital camera to the park here in Knoxville, and took some shots of the grass, some rocks by the river, the sky. They were nice but I needed a little more variety. So I logged onto expedia and bought two round airline trip tickets to the Middle East. The first stop was in Mersin in southeastern Turkey, where I did not see another tourist at all. Next we traveled to Goreme in the middle of the country. We ended up in Istanbul. The entire trip took about half a month. While there we went hot air ballooning, horse back riding, trekking, white water rafting, and abseiling. Many oppurtunities to sample some textures. Here is a small sample of what I was able to collect. I have hundreds more of these that need processing. If anyone is interested in the full collection in high resolution, let me know. I will let you have these to use in a non-commercial game royalty free. We made it back more or less intact. My wife suffered from a fractured hand, and several lacerations, cuts, and scrapes. I only had to visit a rural doctor once, where he loaded me up with four unknown prescription drugs. One of our guides was bitten by a scorpion and required hospitalization, another guide engaged in a brutal fistfight for some unknown reason, another fell down a series of stone steps and broke his arm, and yet another stepped on a rusty nail and had to be taken to the hospital. And for those that are interested, here is a shot from our hotair balloon as we accidently violated the airspace over a maximum security prison. Maybe I will make a Turkish prison level.
  2. jdaniel


    Oh wow, those screenshots are beautiful. It reminds me of Outcast in a way.
  3. jdaniel

    The Reason For GTL...

    I have to say that I like your motto the best. "Not dead... ...dreaming". That is really cool.
  4. jdaniel


    Good luck on your interview!
  5. I finished coded and implementing the quad-tree data structure to handle my collision detection geometry. I figured that a quad-tree would do the trick because I see no reason to partition the geometry along the y axis. If my level geometry consists of several rooms above rooms, I don't think it will affect the framerate that much. Basically I recursively subdivide the collision detection geometry into a 2D quad-tree, ignoring the y values. Then during a collision pass I build a 2D bounding box around my bounding ellipsoid representing the player's current position and the ellipsoid representing the players final position. I then, non-recursively, test this bounding box against the subdivided quads. Each quad that contained the player's bounding box is then passed to the collision detection routine. It works well, but I need some larger level geometry to test it. With the partial test level I have constructed consisting of 555 triangles, an average of 11 triangles was passed to the collision routine. This was with 3 levels of recursion when building the quad-tree. Next I will work on finishing the test level geometry in Maya and then texturing and populating the rooms with various geometry. This will give me a good testing environment to finish up the visibility culling. It should also make for some more interesting screenshots. As far as visibility culling is concerned, I have decided that I will do a basic frustum cull on the bounding boxes of each object. I will then render all the "room" geometry. Finally, I will make a GL_ARB_occlusion_query call on each "non-room" bounding box that passed the frustum cull. If the occlusion query call returns an integer greater than my threshold, I will send the geometry down the pipe. My game will consists primarily of indoor environments so this approach should allow for fast framerates. I also have a seperate code that allows me to run a Perlin noise filter through a mesh. I want to incorporate this vertex shader into my engine for various animated effects. The first geometry I will tweak with this shader will be flames. Torchlight will play a key role in my game and I would like for it to look nice. ----------------- On a different note, I have spent a couple of evenings last week reading Alan Watt's 3D Computer Graphics (Third Edition). This was the textbook we used in Computer Graphics CS594 at the University of Tennessee when I was a teaching assistant for the class. Since then, the professor has changed to Real-Time Rendering (2nd Edition), which I currently have on order from amazon. In the first chapter entitled, Mathematical Fundamentals of Computer Graphics I noticed several errors. On page 14, the last sentence on the page reads, "or the angle between two vectors is the dot product of their normalized versions". This statement is false. I believe what the author meant to say was "or the cosine of the angle between two vectors is the dot product of their normalized versions". On page 19, the last paragraph second sentence reads "This means that the ray is in the half space, defined by the plane that does not contain the polygon". This too is a false statement. I believe what the author meant to say was "This means that the ray is in the half space, defined by the plane that does not contain the polyhedron". On page 24 there are two diagrams at the bottom of the page. The first has a caption that reads "R = I + 2N cos theta". This is not true. What the author probably meant was "R = I + 2N cos phi". This error is particularly brutal because theta is used to describe another angle in the same diagram. These mistakes are unfortunate, because they can lead the reader in the wrong direction. Watt doesn't do a great job of explaining the math in the first place, often leaving it to the reader to fill in the gaps. This approach might be suitable for a quick refresher for someone that is already familar with the concepts, but the errors might make this text particularly treacherous for someone learning for the first time. There is also no errata that I could find online.
  6. jdaniel

    Yes...more progress. Good. *Rubs hands together*

    Amazing. What is your release strategy?
  7. jdaniel

    More E3 stuff

    I am afraid if I buy a Wii I might lose some Balls Points.
  8. In a recent entry I made some comments about Paul Nettle's collision detection article here on gamedev. You can find his article here: General Collision Detection for Games Using Ellipsoids I spent some time this weekend combing through my code to try to find my mistakes. I found them and fixed them. Long story short, with the exception of adding one parallel check to abort computations if a collision could never occur (which is necessary or anomalies will appear), his pseudo-code is correct. I have implemented it fully and it works just as advertised. In fact, his article is the best I have seen in regards to implementing sliding plane collision detection. It is still used widely in games today (i.e. Oblivion) and works really well with human shaped ellipsoids. I went on a shopping spree also. I ordered the following books and games from Amazon: Mathematics for 3D Game Programming and Computer Graphics Second Edition Real-Time Rendering (2nd Edition) OpenGL(R) Shading Language OpenGL(R) Programming Guide : The Official Guide to Learning OpenGL(R), Version 2 (5th Edition) and I saw Night of the Raven was finally translated to English, so although I still own the original Gothic II, I ordered this to get the expansion... Gothic 2 Gold I wrote the pseudo-code for a quad-tree to sort my collision detection geometry. I also pulled down a few frustum culling papers that I will leverage to cull the actual scene geometry. These are the two coding events that will occur next in my engine. ------------- On the gaming front, I was able to play a little bit of Oblivion. I am amazed at the technology every time I play this. It is quite possibly the best RPG to date. I also played a little online of Fight Night 3 on the 360, which is also a wonderful game, with my brother that lives in D.C. I recently hooked up my PC (which is in my office) to my home theater (that is in my living room). The whole project involved drilling through the floor several times, crawling around under the house running cables, and once nearly receiving a concussion when a huge oak piece of my home theater cabinet crashed into my skull. But I have it hooked up now and even bought an Adaptoid for much more money that I should have spent on one. Ever heard of an adaptoid? It basically allows you to make your old Nintendo 64 into a programmable PC joystick. It is a wonderful device that is no longer being produced. So if you want one, you have to compete with the rest of the geeks on eBay. But the experience playing the original Golden Ax emulated through Mame on my big screen and surround sound with the N64 joystick is priceless. :) -------------------
  9. jdaniel


    Comedic possibilities? I think this sounds like a hardcore serious simulation. I think it would be better if you could somehow work in some Sea Monkeys though. Maybe as a topping?
  10. jdaniel


    I really liked those effects. Great work! Did you know that there are more than 3 million lightning flashes worldwide per day, or more than 30 flashes per second on average? Across the United States, lightning detectors show an average of about 20 million cloud-to-ground flashes per year. :)
  11. jdaniel


    I use to have a Sea Monkey kit that had a little portable aquarium. So you could scoop out your favorite sea monkey and bring it along in your pocket. Hey... wait a damn minute here... I just thought of something. What isn't there a Sea Monkey game ??!
  12. I fixed the key repeat issue with my engine tonight. Before, I was relying on the operating system key repeat setting to implement movement. So when the player held down the 'W' key, for example, the engine would move forward a frame, pause, and then start smooth scrolling forward. There were two problems with this. First, the pause before scrolling kicked in was ugly. Second, the player could only hold down one key at a time. There was no way to hold down 'w' and 'a' at the same time and move diagonally. Now all that is fixed. It works well with the collision detection and sliding planes also. Basically, I used the keypress routine here (as found on the old lighthouse3D website) #include #include #include float angle=0.0,deltaAngle = 0.0,ratio; float x=0.0f,y=1.75f,z=5.0f; float lx=0.0f,ly=0.0f,lz=-1.0f; GLint snowman_display_list; int deltaMove = 0; void changeSize(int w, int h) { // Prevent a divide by zero, when window is too short // (you cant make a window of zero width). if(h == 0) h = 1; ratio = 1.0f * w / h; // Reset the coordinate system before modifying glMatrixMode(GL_PROJECTION); glLoadIdentity(); // Set the viewport to be the entire window glViewport(0, 0, w, h); // Set the clipping volume gluPerspective(45,ratio,1,1000); glMatrixMode(GL_MODELVIEW); glLoadIdentity(); gluLookAt(x, y, z, x + lx,y + ly,z + lz, 0.0f,1.0f,0.0f); } void drawSnowMan() { glColor3f(1.0f, 1.0f, 1.0f); // Draw Body glTranslatef(0.0f ,0.75f, 0.0f); glutSolidSphere(0.75f,20,20); // Draw Head glTranslatef(0.0f, 1.0f, 0.0f); glutSolidSphere(0.25f,20,20); // Draw Eyes glPushMatrix(); glColor3f(0.0f,0.0f,0.0f); glTranslatef(0.05f, 0.10f, 0.18f); glutSolidSphere(0.05f,10,10); glTranslatef(-0.1f, 0.0f, 0.0f); glutSolidSphere(0.05f,10,10); glPopMatrix(); // Draw Nose glColor3f(1.0f, 0.5f , 0.5f); glRotatef(0.0f,1.0f, 0.0f, 0.0f); glutSolidCone(0.08f,0.5f,10,2); } GLuint createDL() { GLuint snowManDL; // Create the id for the list snowManDL = glGenLists(1); // start list glNewList(snowManDL,GL_COMPILE); // call the function that contains the rendering commands drawSnowMan(); // endList glEndList(); return(snowManDL); } void initScene() { glEnable(GL_DEPTH_TEST); snowman_display_list = createDL(); } void orientMe(float ang) { lx = sin(ang); lz = -cos(ang); glLoadIdentity(); gluLookAt(x, y, z, x + lx,y + ly,z + lz, 0.0f,1.0f,0.0f); } void moveMeFlat(int i) { x = x + i*(lx)*0.1; z = z + i*(lz)*0.1; glLoadIdentity(); gluLookAt(x, y, z, x + lx,y + ly,z + lz, 0.0f,1.0f,0.0f); } void renderScene(void) { if (deltaMove) moveMeFlat(deltaMove); if (deltaAngle) { angle += deltaAngle; orientMe(angle); } glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // Draw ground glColor3f(0.9f, 0.9f, 0.9f); glBegin(GL_QUADS); glVertex3f(-100.0f, 0.0f, -100.0f); glVertex3f(-100.0f, 0.0f, 100.0f); glVertex3f( 100.0f, 0.0f, 100.0f); glVertex3f( 100.0f, 0.0f, -100.0f); glEnd(); // Draw 36 SnowMen for(int i = -3; i < 3; i++) for(int j=-3; j < 3; j++) { glPushMatrix(); glTranslatef(i*10.0,0,j * 10.0); glCallList(snowman_display_list);; glPopMatrix(); } glutSwapBuffers(); } void pressKey(int key, int x, int y) { switch (key) { case GLUT_KEY_LEFT : deltaAngle = -0.01f;break; case GLUT_KEY_RIGHT : deltaAngle = 0.01f;break; case GLUT_KEY_UP : deltaMove = 1;break; case GLUT_KEY_DOWN : deltaMove = -1;break; } } void releaseKey(int key, int x, int y) { switch (key) { case GLUT_KEY_LEFT : case GLUT_KEY_RIGHT : deltaAngle = 0.0f;break; case GLUT_KEY_UP : case GLUT_KEY_DOWN : deltaMove = 0;break; } } void processNormalKeys(unsigned char key, int x, int y) { if (key == 27) exit(0); } int main(int argc, char **argv) { glutInit(&argc, argv); glutInitDisplayMode(GLUT_DEPTH | GLUT_DOUBLE | GLUT_RGBA); glutInitWindowPosition(100,100); glutInitWindowSize(640,360); glutCreateWindow("SnowMen from Lighthouse 3D"); initScene(); glutIgnoreKeyRepeat(1); glutKeyboardFunc(processNormalKeys); glutSpecialFunc(pressKey); glutSpecialUpFunc(releaseKey); glutDisplayFunc(renderScene); glutIdleFunc(renderScene); glutReshapeFunc(changeSize); glutMainLoop(); return(0); } I already have a timer built into the engine to calculate framerate. Next I will modify the code to implement framerate independence. I also want to implement a perlin noise shader soon in Cg. I plan to use this shader for various effects throughout the levels. I recently had to give a presentation regarding GPU depth buffers, so I have Cg fresh on my mind. Sound is also on the horizon, and this is something that I do not have much experience with at the moment. I believe I will use openAl to do this, but I really know nothing about it currently. It should be interesting learning about it. Finally, I found a bug the other day in my code that was responsible for constructing my data structures from OBJs. It was a small little looping bug, but it caused certain faces to be added twice, while the face count was only incremented once. Since the faces that were added twice were identical, there was no noticeable difference when rendering. Unfortunately, all my rendering benchmarks are now suspect. Suspect for the better, but suspect nonetheless. I might benchmark again sometime to get more accurate results, but for the moment I would like to continue coding.
  13. jdaniel

    In a rush

    Those screenshots look interesting. nice work.
  14. jdaniel


    Congratulations! Is she into video games too, or is that asking too much? ;)
  15. jdaniel

    Another article

    Nice article. I bookmarked for future reference. You may want to consider changing the first sentence of your second paragraph to this: "First we have our vertex format; we'll cover that further on in the article. We derive our class from the CDevice base class to extend its functionality." Minor errors, but you need a semicolon to separate those two sentences and there is no apostrophe on 'its' unless it means 'it is'. I always hated that rule. :)
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!