11#include " stdafx.h"
22#include " overlay_big_picture_game_grid.h"
33#include " overlay_big_picture_game_details.h"
4- #include " Emu/System.h"
54#include " Emu/system_config.h"
65#include " Utilities/Thread.h"
76
@@ -11,7 +10,7 @@ namespace rsx
1110{
1211 namespace overlays
1312 {
14- big_picture_game_tile::big_picture_game_tile (const big_picture_game_entry & entry, u16 tile_width)
13+ big_picture_game_tile::big_picture_game_tile (const big_picture_game_info & entry, u16 tile_width)
1514 {
1615 pack_padding = 8 ;
1716 back_color.a = 0 .f ;
@@ -22,9 +21,9 @@ namespace rsx
2221 icon->set_size (tile_width, icon_h);
2322 icon->back_color = color4f (1 .f , 1 .f , 1 .f , 0 .08f );
2423
25- if (fs::exists ( entry.icon_path ))
24+ if (auto icon_data = entry.load_icon ( ))
2625 {
27- m_icon_data = std::make_unique<image_info>(entry. icon_path );
26+ m_icon_data = std::move (icon_data );
2827 // The renderer's texture cache is keyed by this object's address, which can be reused by an
2928 // unrelated image after the old one is freed - force a re-upload instead of trusting the cache.
3029 m_icon_data->dirty = true ;
@@ -119,7 +118,7 @@ namespace rsx
119118 m_game_enumeration.remove_duplicates ();
120119
121120 // Parse entries (multithreaded)
122- const std::vector<game_enumeration<big_picture_game_entry >::path_entry>& entries = m_game_enumeration.path_entries ();
121+ const std::vector<game_enumeration<big_picture_game_info >::path_entry>& entries = m_game_enumeration.path_entries ();
123122 usz thread_count = std::min<usz>(utils::get_thread_count (), entries.size ());
124123 map_workload (" BPM Parser " sv, thread_count, entries.size (), [this , &entries](usz index)
125124 {
@@ -131,7 +130,7 @@ namespace rsx
131130 m_game_enumeration.apply_patches ();
132131
133132 // Get final enumerated games
134- for (big_picture_game_entry & game : m_game_enumeration.take_games ())
133+ for (big_picture_game_info & game : m_game_enumeration.take_games ())
135134 {
136135 if (!game.bootable ) continue ; // Let's restrict this to bootable entries
137136
@@ -142,7 +141,7 @@ namespace rsx
142141 m_game_enumeration.clear (true );
143142
144143 // Sort by name
145- std::sort (m_games.begin (), m_games.end (), [](const big_picture_game_entry & a, const big_picture_game_entry & b)
144+ std::sort (m_games.begin (), m_games.end (), [](const big_picture_game_info & a, const big_picture_game_info & b)
146145 {
147146 return a.name < b.name ;
148147 });
@@ -288,7 +287,7 @@ namespace rsx
288287 case big_picture_game_details::result::start:
289288 {
290289 rsx_log.notice (" Big Picture Mode: Start pressed for index=%d" , m_selected_index);
291- const big_picture_game_entry & info = m_games[m_selected_index];
290+ const big_picture_game_info & info = m_games[m_selected_index];
292291 rsx_log.notice (" Big Picture Mode: selected game path='%s' serial='%s'" , info.path , info.serial );
293292 m_details->hide ();
294293 if (m_on_game_selected)
0 commit comments