mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
Gold linker, CCache, Stats, LGTM
- Increases linker performance under Linux builds by using Gold linker, if available - ccache is used if available - removed statistic class (Stats.cpp) from project due to the missing result (sorry @Brindosch) - add LGTM bandges for code analysis overview Signed-off-by: Paulchen-Panther <Paulchen-Panter@protonmail.com>
This commit is contained in:
@@ -41,7 +41,7 @@ void QtGrabber::freeResources()
|
||||
}
|
||||
}
|
||||
|
||||
const bool QtGrabber::setupDisplay()
|
||||
bool QtGrabber::setupDisplay()
|
||||
{
|
||||
// cleanup last screen
|
||||
freeResources();
|
||||
@@ -105,7 +105,7 @@ int QtGrabber::grabFrame(Image<ColorRgb> & image)
|
||||
QPixmap originalPixmap = _screen->grabWindow(0, _src_x, _src_y, _src_x_max, _src_y_max);
|
||||
QPixmap resizedPixmap = originalPixmap.scaled(_width,_height);
|
||||
QImage img = resizedPixmap.toImage().convertToFormat( QImage::Format_RGB888);
|
||||
memcpy(image.memptr(), img.bits(),_width*_height*3);
|
||||
memcpy(image.memptr(), img.bits(),(size_t) _width*_height*3);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@@ -54,7 +54,7 @@ void X11Grabber::setupResources()
|
||||
if(_XShmAvailable)
|
||||
{
|
||||
_xImage = XShmCreateImage(_x11Display, _windowAttr.visual, _windowAttr.depth, ZPixmap, NULL, &_shminfo, _width, _height);
|
||||
_shminfo.shmid = shmget(IPC_PRIVATE, _xImage->bytes_per_line * _xImage->height, IPC_CREAT|0777);
|
||||
_shminfo.shmid = shmget(IPC_PRIVATE, (size_t) _xImage->bytes_per_line * _xImage->height, IPC_CREAT|0777);
|
||||
_xImage->data = (char*)shmat(_shminfo.shmid,0,0);
|
||||
_shminfo.shmaddr = _xImage->data;
|
||||
_shminfo.readOnly = False;
|
||||
|
Reference in New Issue
Block a user