skip hardware acceleration for small regions, should speed up rendering of small regions in the same way it helped small rects
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16955 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -625,11 +625,13 @@ DrawingEngine::FillRegion(BRegion& r, const RGBColor& color)
|
||||
// gut feeling.
|
||||
// NOTE: region expected to be already clipped correctly!!
|
||||
if (WriteLock()) {
|
||||
fGraphicsCard->HideSoftwareCursor(r.Frame());
|
||||
BRect frame = r.Frame();
|
||||
fGraphicsCard->HideSoftwareCursor(frame);
|
||||
|
||||
bool doInSoftware = true;
|
||||
// try hardware optimized version first
|
||||
if ((fAvailableHWAccleration & HW_ACC_FILL_REGION) != 0) {
|
||||
if ((fAvailableHWAccleration & HW_ACC_FILL_REGION) != 0
|
||||
&& frame.Width() * frame.Height() > 100) {
|
||||
fGraphicsCard->FillRegion(r, color);
|
||||
doInSoftware = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user