mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 23:55:38 +00:00
Merge pull request #225 from jrassa/carousel-fix-single-system
properly render carousel for system configured with only 1 system
This commit is contained in:
commit
0b0e0adce6
|
@ -466,8 +466,15 @@ void SystemView::renderCarousel(const Eigen::Affine3f& trans)
|
|||
|
||||
// Adding texture loading buffers depending on scrolling speed and status
|
||||
int bufferIndex = getScrollingVelocity() + 1;
|
||||
int bufferLeft = logoBuffersLeft[bufferIndex];
|
||||
int bufferRight = logoBuffersRight[bufferIndex];
|
||||
if (logoCount == 1)
|
||||
{
|
||||
bufferLeft = 0;
|
||||
bufferRight = 0;
|
||||
}
|
||||
|
||||
for (int i = center - logoCount / 2 + logoBuffersLeft[bufferIndex]; i <= center + logoCount / 2 + logoBuffersRight[bufferIndex]; i++)
|
||||
for (int i = center - logoCount / 2 + bufferLeft; i <= center + logoCount / 2 + bufferRight; i++)
|
||||
{
|
||||
int index = i;
|
||||
while (index < 0)
|
||||
|
|
Loading…
Reference in a new issue