~unity-team/nux/nux.reset-texture-area

« back to all changes in this revision

Viewing changes to gputests/texture_copy_blur.cpp

  • Committer: Tarmac
  • Author(s): Eleni Maria Stea
  • Date: 2012-11-29 19:15:01 UTC
  • mfrom: (724.1.1 nux)
  • Revision ID: tarmac-20121129191501-d5psx834ryjgf4oj
* fixed gputests/texture_copy_blur example (swap buffers was missing)
* Removed some printf.

Approved by Jay Taoko.

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
#include "NuxGraphics/GraphicsEngine.h"
27
27
 
28
28
/*
29
 
 * Tests: 
 
29
 * Tests:
30
30
 *  - Frame buffer object
31
31
 *  - Set a texture in the fbo
32
32
 *  - Set fbo as a render target
91
91
      fbo         = graphics_display->GetGpuDevice ()->CreateFrameBufferObject ();
92
92
      texture_rt  = graphics_display->GetGpuDevice ()->CreateSystemCapableDeviceTexture (graphics_display->GetWindowWidth(), graphics_display->GetWindowHeight(), 1, nux::BITFMT_R8G8B8A8);
93
93
      depth_rt    = graphics_display->GetGpuDevice ()->CreateSystemCapableDeviceTexture (graphics_display->GetWindowWidth(), graphics_display->GetWindowHeight(), 1, nux::BITFMT_D24S8);
94
 
      fbo->FormatFrameBufferObject (graphics_display->GetWindowWidth(), graphics_display->GetWindowHeight(), nux::BITFMT_R8G8B8A8);
95
94
    }
96
95
 
 
96
    fbo->FormatFrameBufferObject (graphics_display->GetWindowWidth(), graphics_display->GetWindowHeight(), nux::BITFMT_R8G8B8A8);
 
97
 
97
98
    fbo->SetRenderTarget (0, texture_rt->GetSurfaceLevel (0));
98
99
    fbo->SetDepthSurface (depth_rt->GetSurfaceLevel (0));
99
100
    fbo->Activate();
150
151
    }
151
152
    */
152
153
 
 
154
    graphics_display->SwapBuffer();
153
155
  } while((event.type != nux::NUX_TERMINATE_APP) && (event.GetVirtualKeyState(NUX_VK_ESCAPE) == 0));
154
156
 
155
157
  fbo.Release ();