CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7
  1. #1
    Join Date
    Sep 2004
    Posts
    244

    really fast drawing

    hi, how is it possible to have very fast 2d drawing for UI like in gecko or aol's boxely? boxely does not use directx or gdiplus, does anyone know how to do similarly?

  2. #2

    Re: really fast drawing

    Quote Originally Posted by inbugable
    hi, how is it possible to have very fast 2d drawing for UI like in gecko or aol's boxely? boxely does not use directx or gdiplus, does anyone know how to do similarly?
    DirectDraw? Combined with GetDC member of IDirectDraw7 interface so you can still use GDI functions.

    DirectDraw public support stopped after version 7. However, you can still use IDirectDraw7. Microsoft pushes Direct3D and never makes much mention of DirectDraw. You can still use the older DirectDraw interfaces. If DD still exists as newer releases of DX, then they are private interfaces not documented by MS.

  3. #3
    Join Date
    Mar 2007
    Location
    Montreal, Quebec, Canada
    Posts
    185

    Re: really fast drawing

    You can use OpenGL too. Or, try downloading the source for Gecko and take a peek at that.

  4. #4
    Join Date
    Sep 2004
    Posts
    244

    Re: really fast drawing

    boxely doesnt use any of those, how to be done? i think it uses createdibsection but then to draw, must use asm for fast?

  5. #5
    Join Date
    Mar 2007
    Location
    Montreal, Quebec, Canada
    Posts
    185

    Re: really fast drawing

    I think you're going about this the wrong way. There are usually several ways to solve a given problem. By wasting a lot of time trying to figure out how somebody else did it, why not just do it your own way with other resources at your disposal?

    You probably COULD go into assembly to do it, but unless you're a **** good assembly programmer, the C compiler will make faster assembly than you will. I'd recommend just doing it with C or C++. Using OpenGL or Direct3D probably won't be any slower.

    If you don't want to go into a 3D library, you can try SDL and just put pixels to the window. This will be super-fast, and a heck of a lot easier than using assembly for your program.

  6. #6
    Join Date
    Sep 2004
    Posts
    244

    Re: really fast drawing

    I want to do like boxely, boxely is so fast

  7. #7
    Join Date
    Mar 2007
    Location
    Montreal, Quebec, Canada
    Posts
    185

    Re: really fast drawing

    Then I'd recommend going with C and some library, be it DirectX, OpenGL, SDL, or whatever. They probably either used one of those, bought a commercial library to use, or rolled their own. I doubt you'll want to do the second or third options.

    If you want extra fast, DirectX or OpenGL have hardware acceleration, so you can do cool things like rotations and fading really quickly.

    Like I said before, you have to be really good at assembly in order to actually get assembly code faster than C, since the compilers have gotten really good at optimizing code. Assembly is only faster if you're an expert, otherwise it'll likely be slower.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured