I hacked together something to see how fast the BitBlt is, and it's pretty disappointing .
Code:
// sstest.cpp : Defines the entry point for the console application.
//
#include <Windows.h>
#include <iostream>
#include <time.h>
#include "stdafx.h"
static const int WIDTH = 1920;
static const int HEIGHT = 1080;
int _tmain(int argc, _TCHAR* argv[])
{
HDC hdcScreen = GetDC(NULL);
HDC hdcTarget = CreateCompatibleDC(hdcScreen);
HBITMAP bmp = CreateCompatibleBitmap(hdcScreen, WIDTH, HEIGHT);
SelectObject(hdcTarget, bmp);
BITMAPINFO bminfo;
time_t begin = time(0);
for (int i = 0; i < 100; ++i)
{
BitBlt(hdcTarget, 0, 0, WIDTH, HEIGHT, hdcScreen, 0, 0, SRCCOPY | CAPTUREBLT);
}
time_t end = time(0);
std::cout << "Frame rate: " << (100.0 / static_cast<double>(end - begin)) << std::endl;
}
I'm getting 30 fps idle on my laptop (low end Quadro + 2.7 GHz i7), and 10 fps with just a youtube video playing.
Am I doing it wrong? Or is there something with a little higher performance?