Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

119 Neutral

About aqrit

  • Rank
  1. http://bitpatch.com/downloads/ddwrapperx.7z   the opengl stuff is in "the_fun_stuff.cpp", SetupOpenGL() and ToScreen()
  2. I've got a OpenGL window that basically displays a bitmap. The program never reads anything from the "screen".   It seems to "stop responding" (somewhere in nvidia's opengl stuff**), when another window manages to steal focus from my window.   I can reproduce this issue fairly reliably by popping up a [Warning this file came from the internet] box anywhere on screen.   Any thoughts?     I'm not sure that I've setup OpenGL correctly... glViewport and glOrtho are set to the client window size then I draw a GL_QUADS with glTexCoord2i being either 0 or 1 and glVertex2i set to either 0 or screen_size(w/h)   ** attached a debugger and looked at the stack Originally a call to glFinish was on the stack when I commented that out it was then a call to glTexSubImage2D on the stack so is it waiting on that texture somehow? edit:  or is it a coincidence that the debugger breaks in on opengl stuff
  3. aqrit

    bind a bitmap raw data as texture to gl

    I just started with OpenGL... but I wrote this as a demonstration of uploading a image to a texture. http://bitpatch.com/downloads/glTex_example.cpp
  4. the interface gets destoryed but "adapter" is not set to null so the "dangling pointer" gets accessed in cleanUp() I think,,,
  5. I usually just drop it in "programically" #pragma comment(linker, "/ENTRY:\"myEntryPoint\"")reducing exe size: http://www.catch22.net/tuts/reducing-executable-size http://thelegendofrandom.com/blog/archives/2231
  6. aqrit

    PBO to GL_BACK

    Is there any way to upload an image to the back buffer with out an extra copy step? ( other than glDrawPixels )  -- maybe get the handle of the texture the back buffer is using?   edit: glGetFramebufferAttachmentParameteriv doesn't work on the default frame buffer I see some disussion of about this topic http://www.opengl.org/discussion_boards/showthread.php/178863-Lock-the-Default-Framebuffer?p=1241817&viewfull=1#post1241817 http://www.opengl.org/discussion_boards/showthread.php/182610-Request-FBO-can-use-default-color-depth-and-stencil-buffers?p=1254401&viewfull=1#post1254401   that seems to suggest it is currently impossible because the screen size can change without notice ( or something )
  7. aqrit

    Main loop timing

    this article may be of interest to someone: http://randomascii.wordpress.com/2013/04/02/sleep-variation-investigated/
  8. Why is uploading to a texture then rendering a quad recommended over glDrawPixels? edit: looks like glDrawPixels takes twice the time to run as glTexSubImage2D->render quad does in my tests :(     Why does glCopyBufferSubData not work for this? //glDrawPixels( 640, 480, GL_RGB, GL_UNSIGNED_SHORT_5_6_5, 0 ); // works glBindBuffer( GL_COPY_WRITE_BUFFER, GL_BACK_LEFT ) ; glCopyBufferSubData( GL_PIXEL_UNPACK_BUFFER, GL_COPY_WRITE_BUFFER, 0, 0, 256 ); // fails 0x501
  9. you may need to call SetConsoleWindowInfo first...   here is a working c++ snippet for resizing the console... http://sourceforge.net/p/dosbox/code-0/HEAD/tree/dosbox/trunk/src/debug/debug_win32.cpp
  10. aqrit

    Opening file from exe path

    argv[0] ( of GetCommandLine() ) does not always include the full path.   strip the filename from the exe path using PathRemoveFileSpec()
  11. aqrit

    Display screen remotely

    Why would you need to draw a distinction between black and unchanged?   ( assuming black is zero )   previous[3] = { green, black, green }; current[3] = { black, black, green };   encode: ( xor previous with current frame ) green xor black = green black xor black = black green xor green = black   so pak[3] = { green, black, black }   decode: ( xor previous with "packed" frame ) green xor green = black black xor black = black green xor black= green   which is back to current frame   If your doing this for the first frame just use zero filled memory / black as the previous frame.
  12. found what I was looking for (more or less): http://en.wikipedia.org/wiki/Basic_Linear_Algebra_Subprograms
  13. Any brute force Multiply-Add-Shift lib to calculate a perfect hash for ~50 unqiue integers?   I can Multiply-Shift on the CPU but throwing the other unknown in just slows it down too much. gperf works well but I'd like something with fewer lookup tables.   I'm grabbing the Cuda SDK/Thrust tonite. ( sorry if this is in the wrong section )
  14. aqrit

    DirectDrawCreate issues

    DirectDraw (1) which you then use to query for version 2 or 4
  • 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!