Skip to content

Commit

Permalink
CDImage: Add support for loading PBP images
Browse files Browse the repository at this point in the history
  • Loading branch information
ggrtk committed Mar 16, 2021
1 parent a34f0d5 commit 46ff2b5
Show file tree
Hide file tree
Showing 12 changed files with 882 additions and 6 deletions.
4 changes: 3 additions & 1 deletion src/common/CMakeLists.txt
Expand Up @@ -18,6 +18,7 @@ add_library(common
cd_image_hasher.h
cd_image_memory.cpp
cd_image_mds.cpp
cd_image_pbp.cpp
cd_subchannel_replacement.cpp
cd_subchannel_replacement.h
cd_xa.cpp
Expand Down Expand Up @@ -62,9 +63,10 @@ add_library(common
memory_arena.h
page_fault_handler.cpp
page_fault_handler.h
rectangle.h
pbp_types.h
progress_callback.cpp
progress_callback.h
rectangle.h
scope_guard.h
shiftjis.cpp
shiftjis.h
Expand Down
4 changes: 4 additions & 0 deletions src/common/cd_image.cpp
Expand Up @@ -50,6 +50,10 @@ std::unique_ptr<CDImage> CDImage::Open(const char* filename)
{
return OpenMdsImage(filename);
}
else if (CASE_COMPARE(extension, ".pbp") == 0)
{
return OpenPBPImage(filename);
}

#undef CASE_COMPARE

Expand Down
1 change: 1 addition & 0 deletions src/common/cd_image.h
Expand Up @@ -197,6 +197,7 @@ class CDImage
static std::unique_ptr<CDImage> OpenCHDImage(const char* filename);
static std::unique_ptr<CDImage> OpenEcmImage(const char* filename);
static std::unique_ptr<CDImage> OpenMdsImage(const char* filename);
static std::unique_ptr<CDImage> OpenPBPImage(const char* filename);
static std::unique_ptr<CDImage>
CreateMemoryImage(CDImage* image, ProgressCallback* progress = ProgressCallback::NullProgressCallback);

Expand Down

0 comments on commit 46ff2b5

Please sign in to comment.