MCPcopy Create free account
hub / github.com/MusicPlayerDaemon/MPD / SidplayGlobal

Method SidplayGlobal

src/decoder/plugins/SidplayDecoderPlugin.cxx:90–124  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

88}
89
90inline
91SidplayGlobal::SidplayGlobal(const ConfigBlock &block)
92{
93 /* read the songlengths database file */
94 const auto database_path = block.GetPath("songlength_database");
95 if (!database_path.IsNull())
96 songlength_database = sidplay_load_songlength_db(database_path);
97
98 default_songlength = block.GetPositiveValue("default_songlength", 0U);
99
100 default_genre = block.GetBlockValue("default_genre", "");
101
102 all_files_are_containers =
103 block.GetBlockValue("all_files_are_containers", true);
104
105#if LIBSIDPLAYFP_VERSION_MAJ < 3
106 filter_setting = block.GetBlockValue("filter", true);
107#endif
108
109 /* read kernal rom dump file */
110 const auto kernal_path = block.GetPath("kernal");
111 if (!kernal_path.IsNull())
112 {
113 kernal = std::make_unique_for_overwrite<uint8_t[]>(rom_size);
114 loadRom(kernal_path, kernal.get());
115 }
116
117 /* read basic rom dump file */
118 const auto basic_path = block.GetPath("basic");
119 if (!basic_path.IsNull())
120 {
121 basic = std::make_unique_for_overwrite<uint8_t[]>(rom_size);
122 loadRom(basic_path, basic.get());
123 }
124}
125
126static bool
127sidplay_init(const ConfigBlock &block)

Callers

nothing calls this directly

Calls 6

loadRomFunction · 0.85
GetPositiveValueMethod · 0.80
GetBlockValueMethod · 0.80
getMethod · 0.80
GetPathMethod · 0.45

Tested by

no test coverage detected