Added preview indicator for synth parts.

This commit is contained in:
Leonardo Zide 2021-03-21 13:29:04 -07:00
parent e6e1ee70a6
commit e9040c8332
3 changed files with 9 additions and 0 deletions

View file

@ -436,6 +436,14 @@ void lcPartSelectionListModel::DrawPreview(int InfoIndex)
QImage Image = mView->GetRenderFramebufferImage().convertToFormat(QImage::Format_ARGB32);
if (Info->GetSynthInfo())
{
QPainter Painter(&Image);
QImage Icon = QImage(":/resources/flexible.png");
Painter.drawImage(QPoint(0, 0), Icon);
Painter.end();
}
mParts[InfoIndex].second = QPixmap::fromImage(Image).scaled(mIconSize, mIconSize, Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
lcGetPiecesLibrary()->ReleasePieceInfo(Info);

View file

@ -135,5 +135,6 @@
<file>resources/shaders/unlit_view_sphere_ps.glsl</file>
<file>resources/shaders/unlit_view_sphere_vs.glsl</file>
<file>resources/gear_in.png</file>
<file>resources/flexible.png</file>
</qresource>
</RCC>

BIN
resources/flexible.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 444 B