comparison foosdk/sdk/foobar2000/SDK/chapterizer.cpp @ 1:20d02a178406 default tip

*: check in everything else yay
author Paper <paper@tflc.us>
date Mon, 05 Jan 2026 02:15:46 -0500
parents
children
comparison
equal deleted inserted replaced
0:e9bb126753e7 1:20d02a178406
1 #include "foobar2000-sdk-pch.h"
2 #include "chapterizer.h"
3
4 void chapter_list::copy(const chapter_list & p_source)
5 {
6 t_size n, count = p_source.get_chapter_count();
7 set_chapter_count(count);
8 for(n=0;n<count;n++) set_info(n,p_source.get_info(n));
9 set_pregap(p_source.get_pregap());
10 }
11
12 #ifdef FOOBAR2000_HAVE_CHAPTERIZER
13
14 // {3F489088-6179-434e-A9DB-3A14A1B081AC}
15 FOOGUIDDECL const GUID chapterizer::class_guid=
16 { 0x3f489088, 0x6179, 0x434e, { 0xa9, 0xdb, 0x3a, 0x14, 0xa1, 0xb0, 0x81, 0xac } };
17
18 bool chapterizer::g_find(service_ptr_t<chapterizer> & p_out,const char * p_path)
19 {
20 for (auto ptr : enumerate()) {
21 if (ptr->is_our_path(p_path)) {
22 p_out = ptr;
23 return true;
24 }
25 }
26 return false;
27 }
28
29 bool chapterizer::g_is_pregap_capable(const char * p_path) {
30 for (auto ptr : enumerate()) {
31 if (ptr->supports_pregaps() && ptr->is_our_path(p_path)) {
32 return true;
33 }
34 }
35 return false;
36 }
37
38 #endif
39