Advertisement Jump to content
  • Advertisement

DJHoltkamp

Member
  • Content Count

    30
  • Joined

  • Last visited

Community Reputation

122 Neutral

About DJHoltkamp

  • Rank
    Member
  1. I am creating a game for Symbian S60 on a 5800 and I just can't figure out why my OpenGL code is so incredibly slow. I can think of a couple possibilities, but no diffinitive answer. If anyone has some insight into optimizations on this platform, it would be a huge help. Currently, here are some of my ideas: - I am using a 32 bit RGBA values, maybe I should do 16 bit? - Is there a way to activate the FPU to run with OpenGL ES? - Does using Color3f make the system do simulated floating point operations?
  2. DJHoltkamp

    Rotating a point_sprite texture

    The currently selected matrix will not have any affect on the DrawElements (but i tried it just to make sure). Thanks for the guess! Anybody else?
  3. DJHoltkamp

    Rotating a point_sprite texture

    ha ha, ok, this is what I get for programming at 4 in the morning... I totally missed the return false in the middle of my statement. Nonetheless, the texture matrix still doesnt seem to provide a way to rotate the texture. Suggestions?
  4. Is there any way to rotate a point_sprite texture... I tried altering the texture matrix but everything went crazy leading me to believe that it is not possible. I am using OpenGL ES. Thanks. Here is my code: glPointSize(32.0f); glDisableClientState(GL_TEXTURE_COORD_ARRAY); glEnable(GL_POINT_SPRITE_OES); glTexEnvi(GL_POINT_SPRITE_OES, GL_COORD_REPLACE_OES, GL_TRUE); glMatrixMode(GL_TEXTURE); glRotatef(70, 0, 0, 1); float Intensity = 1.0f - TotalSeconds / 6.0f; glColor4f(Intensity, Intensity, Intensity, Intensity); glDrawElements(GL_POINTS, Count , GL_UNSIGNED_SHORT, GLIndicies); return false; glDisable(GL_POINT_SPRITE_OES); glLoadIdentity(); glMatrixMode(GL_MODELVIEW); glEnableClientState(GL_TEXTURE_COORD_ARRAY); glTexEnvi(GL_POINT_SPRITE_OES, GL_COORD_REPLACE_OES, GL_FALSE);
  5. DJHoltkamp

    Best way to rewrite texture

    Opinions Anybody???
  6. Hey Guys, Whats the best way to completely rewrite a texture which has already been created with a block of memory in processor memory. Would it be faster to make a framebuffer for it and use GLDrawPixels or to just delete it and create a new one with glTexImage2D. Or perhaps there is a better way? Im using OpenGL ES on iPhone if it matters. Thanks!
  7. I have a small c++ universal binary which opens a resource file. I am having trouble because when a resource file is opened on a PowerPC machine, it reads wrong because of the big-endian to little-endian difference. Is there a way that I can detect this in code so I can swap the endian when running on PowerPC. Thanks! David
  8. Hello, I need to do some circular drawing to achieve an effect where two buffers keep using each other as a source. I had been using two frame buffers bound to textures and then kept switching back and forth but this is very slow on the architecture I am using (its opengl ES -- embedded systems). In the documentation it says that binding to a new framebuffer is expensive so here is my question... Is it legal for a framebuffer to use its own texture when drawing to itself so that I might have both items on the same frame buffer and texture and just keep drawing both sides to eachother? Thanks!
  9. Still looking for a solution... Anybody else have any ideas to throw out there? In case it helps, the person who is debugging has an NVIDIA card.
  10. The only major difference is in the graphics card, so I am guessing that it is something I am doing in OpenGL that this particular implementation is not liking. I have spent a lot of time making sure that it was not a memory bufferflow of some type (perhaps the memory lines up differently on the two machines?) but have not found anything. Thanks for the idea though!
  11. Upon review, I do not know if it would make sense to say that this error is coming from the bad billboarding. I am deriving the right and up vectors only once for all of the sprites seen. However, the error is only happening sometimes and it always happens to only the sprite nearest the screen. If the vector was wrong it should mess up all of the sprites for that frame. I find it strange also that the sprite always locks to the viewable screen when there is an error (Perhaps an Inf. or NaN condition?) Good idea with the Polygon_Offset by the way. I may explicitly disable it in case it is just a bug in the implementation which has it enabled by default. Any other ideas?
  12. Yann, This sounds like you might be onto something. The reason which I had doubted this originally is that I never saw this on my PC, any other PC, or my MAC, but your right, its such a strange bug that this seems like it might be the only explination, although why would it react differently on my machine? The basic billboarding technique used is as follows (Note that it is somewhat simplified but you'll get the idea) float mat[16]; glGetFloatv( GL_MODELVIEW_MATRIX, mat ); vector3f vRight( mat[0], mat[4], mat[8] ); vector3f vUp( mat[1], mat[5], mat[9] ); vector3f vPoint0; vector3f vPoint1; vector3f vPoint2; vector3f vPoint3; vector3f vCenter; vector3f rAxis = vector3f::crossProduct(vRight, vUp); vPoint0 = vCenter + ((-vRight*tempASx - vUp*tempASy )); vPoint1 = vCenter + (( vRight*tempASx - vUp*tempASy )); vPoint2 = vCenter + (( vRight*tempASx + vUp*tempASy )); vPoint3 = vCenter + ((-vRight*tempASx + vUp*tempASy )); glVertex3f( vPoint0.x, vPoint0.y, vPoint0.z ); glVertex3f( vPoint1.x, vPoint1.y, vPoint1.z ); glVertex3f( vPoint2.x, vPoint2.y, vPoint2.z ); glVertex3f( vPoint3.x, vPoint3.y, vPoint3.z ); I hadn't even noticed that I didn't normalize the vectors. I haven't seen any side effects on my computer, however, if the OpenGL implementation on my Beta Tester (who's getting the bad result) computer is not as stable with the matrix, this could cause some issues. Any one else have any observations? I know my matrix algebra, but I don't the Model view matrix enough to think of any exception cases right off hand. Time to consult the red book. Any tips would be appreciated.
  13. Tried moving the clipping plane around. Didn't have any effect. Good idea though. One thing which is especially strange, if you step through the video frame by frame, you can see the glitch stays in the exact same position on multiple frames which points to something a little bit stranger than just the clipping plane.
  14. Well I did have it set as follows glEnable(GL_DEPTH_TEST); glDepthFunc(GL_ALWAYS); glDepthMask(GL_TRUE); glBlendFunc (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); glEnable(GL_BLEND); Because I had it depth sorted before render and I had previously been using depth data for depth of field calculations. It probably would be a good idea to just disable it all together when not needed. Any additional ideas?
  15. So I have been having to delay the release of a product for weeks now because one of my beta testers gets a strange artifact. It happens every few frames frames when he gets too close to an GL_QUAD. I am using a manual billboarding technique. I have attached a short video of what it looks like. If you look at it frame by frame you can see that the messed up quad will stay in the same place across frames even when the the camera moves which I really do not understand. It may be a memory corruption error somewhere, but I just don't understand how an artifact like this could be generated. As I said, I can not debug this because it does not occur on any of my machines (Mac or PC). ANY suggestion would be very appreciated. To see the short video, go to: www.AvidionMedia.com/Comp.mov Thanks
  • Advertisement
×

Important Information

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

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!