diff --git a/beatygril/beatygril.xcodeproj/project.pbxproj b/FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj/project.pbxproj similarity index 86% rename from beatygril/beatygril.xcodeproj/project.pbxproj rename to FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj/project.pbxproj index d372a9b..61780d1 100644 --- a/beatygril/beatygril.xcodeproj/project.pbxproj +++ b/FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj/project.pbxproj @@ -8,7 +8,7 @@ /* Begin PBXBuildFile section */ 6945FC8F3088B7220013E108 /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6945FC8E3088B7220013E108 /* Cocoa.framework */; }; - 6945FC973088B7220013E108 /* beatygril XPC Service.pluginkit in Embed PlugIns */ = {isa = PBXBuildFile; fileRef = 6945FC963088B7220013E108 /* beatygril XPC Service.pluginkit */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; + 6945FC973088B7220013E108 /* FCP-BeautyGirl XPC Service.pluginkit in Embed PlugIns */ = {isa = PBXBuildFile; fileRef = 6945FC963088B7220013E108 /* FCP-BeautyGirl XPC Service.pluginkit */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; 6945FC9B3088B7220013E108 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6945FC9A3088B7220013E108 /* Foundation.framework */; }; 6945FC9D3088B7220013E108 /* AppKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6945FC9C3088B7220013E108 /* AppKit.framework */; }; 6945FC9F3088B7220013E108 /* Accelerate.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6945FC9E3088B7220013E108 /* Accelerate.framework */; }; @@ -39,16 +39,16 @@ dstPath = ""; dstSubfolder = PlugIns; files = ( - 6945FC973088B7220013E108 /* beatygril XPC Service.pluginkit in Embed PlugIns */, + 6945FC973088B7220013E108 /* FCP-BeautyGirl XPC Service.pluginkit in Embed PlugIns */, ); name = "Embed PlugIns"; }; /* End PBXCopyFilesBuildPhase section */ /* Begin PBXFileReference section */ - 6945FC8B3088B7220013E108 /* beatygril.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = beatygril.app; sourceTree = BUILT_PRODUCTS_DIR; }; + 6945FC8B3088B7220013E108 /* FCP-BeautyGirl.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = FCP-BeautyGirl.app; sourceTree = BUILT_PRODUCTS_DIR; }; 6945FC8E3088B7220013E108 /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; }; - 6945FC963088B7220013E108 /* beatygril XPC Service.pluginkit */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "beatygril XPC Service.pluginkit"; sourceTree = BUILT_PRODUCTS_DIR; }; + 6945FC963088B7220013E108 /* FCP-BeautyGirl XPC Service.pluginkit */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "FCP-BeautyGirl XPC Service.pluginkit"; sourceTree = BUILT_PRODUCTS_DIR; }; 6945FC9A3088B7220013E108 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; }; 6945FC9C3088B7220013E108 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = System/Library/Frameworks/AppKit.framework; sourceTree = SDKROOT; }; 6945FC9E3088B7220013E108 /* Accelerate.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Accelerate.framework; path = System/Library/Frameworks/Accelerate.framework; sourceTree = SDKROOT; }; @@ -57,12 +57,12 @@ /* End PBXFileReference section */ /* Begin PBXFileSystemSynchronizedBuildFileExceptionSet section */ - 6945FCCB3088B7220013E108 /* Exceptions for "beatygril" folder in "Wrapper Application" target */ = { + 6945FCCB3088B7220013E108 /* Exceptions for "FCP-BeautyGirl" folder in "Wrapper Application" target */ = { isa = PBXFileSystemSynchronizedBuildFileExceptionSet; membershipExceptions = ( "/Localized: Plugin/InfoPlist.strings", "/Localized: Plugin/Localizable.strings", - Plugin/beatygrilPlugIn.m, + Plugin/FCPBeautyGirlPlugIn.m, Plugin/Info.plist, Plugin/main.m, Plugin/PGBeautyRenderer.m, @@ -74,7 +74,7 @@ ); target = 6945FC8A3088B7220013E108 /* Wrapper Application */; }; - 6945FCD33088B7220013E108 /* Exceptions for "beatygril" folder in "XPC Service" target */ = { + 6945FCD33088B7220013E108 /* Exceptions for "FCP-BeautyGirl" folder in "XPC Service" target */ = { isa = PBXFileSystemSynchronizedBuildFileExceptionSet; membershipExceptions = ( "/Localized: Wrapper Application/Credits.rtf", @@ -91,13 +91,13 @@ /* End PBXFileSystemSynchronizedBuildFileExceptionSet section */ /* Begin PBXFileSystemSynchronizedRootGroup section */ - 6945FCA63088B7220013E108 /* beatygril */ = { + 6945FCA63088B7220013E108 /* FCP-BeautyGirl */ = { isa = PBXFileSystemSynchronizedRootGroup; exceptions = ( - 6945FCCB3088B7220013E108 /* Exceptions for "beatygril" folder in "Wrapper Application" target */, - 6945FCD33088B7220013E108 /* Exceptions for "beatygril" folder in "XPC Service" target */, + 6945FCCB3088B7220013E108 /* Exceptions for "FCP-BeautyGirl" folder in "Wrapper Application" target */, + 6945FCD33088B7220013E108 /* Exceptions for "FCP-BeautyGirl" folder in "XPC Service" target */, ); - path = beatygril; + path = FCP-BeautyGirl; sourceTree = ""; }; /* End PBXFileSystemSynchronizedRootGroup section */ @@ -125,7 +125,7 @@ 6945FC823088B7220013E108 = { isa = PBXGroup; children = ( - 6945FCA63088B7220013E108 /* beatygril */, + 6945FCA63088B7220013E108 /* FCP-BeautyGirl */, 6945FC8D3088B7220013E108 /* Frameworks */, 6945FC8C3088B7220013E108 /* Products */, ); @@ -134,8 +134,8 @@ 6945FC8C3088B7220013E108 /* Products */ = { isa = PBXGroup; children = ( - 6945FC8B3088B7220013E108 /* beatygril.app */, - 6945FC963088B7220013E108 /* beatygril XPC Service.pluginkit */, + 6945FC8B3088B7220013E108 /* FCP-BeautyGirl.app */, + 6945FC963088B7220013E108 /* FCP-BeautyGirl XPC Service.pluginkit */, ); name = Products; sourceTree = ""; @@ -172,11 +172,11 @@ 6945FCA53088B7220013E108 /* PBXTargetDependency */, ); fileSystemSynchronizedGroups = ( - 6945FCA63088B7220013E108 /* beatygril */, + 6945FCA63088B7220013E108 /* FCP-BeautyGirl */, ); name = "Wrapper Application"; productName = "Wrapper Application"; - productReference = 6945FC8B3088B7220013E108 /* beatygril.app */; + productReference = 6945FC8B3088B7220013E108 /* FCP-BeautyGirl.app */; productType = "com.apple.product-type.application"; }; 6945FC953088B7220013E108 /* XPC Service */ = { @@ -192,11 +192,11 @@ buildRules = ( ); fileSystemSynchronizedGroups = ( - 6945FCA63088B7220013E108 /* beatygril */, + 6945FCA63088B7220013E108 /* FCP-BeautyGirl */, ); name = "XPC Service"; productName = "XPC Service"; - productReference = 6945FC963088B7220013E108 /* beatygril XPC Service.pluginkit */; + productReference = 6945FC963088B7220013E108 /* FCP-BeautyGirl XPC Service.pluginkit */; productType = "com.apple.product-type.bundle"; }; /* End PBXNativeTarget section */ @@ -216,7 +216,7 @@ }; }; }; - buildConfigurationList = 6945FC863088B7220013E108 /* Build configuration list for PBXProject "beatygril" */; + buildConfigurationList = 6945FC863088B7220013E108 /* Build configuration list for PBXProject "FCP-BeautyGirl" */; developmentRegion = en; hasScannedForEncodings = 0; knownRegions = ( @@ -316,15 +316,15 @@ ENABLE_HARDENED_RUNTIME = YES; ENABLE_USER_SCRIPT_SANDBOXING = NO; GCC_PRECOMPILE_PREFIX_HEADER = YES; - INFOPLIST_FILE = beatygril/Plugin/Info.plist; + INFOPLIST_FILE = FCP-BeautyGirl/Plugin/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@loader_path/../Frameworks", ); MACH_O_TYPE = mh_execute; - PRODUCT_BUNDLE_IDENTIFIER = com.dayu.beatygril.fxplug; - PRODUCT_NAME = "beatygril $(TARGET_NAME)"; - SWIFT_OBJC_BRIDGING_HEADER = "beatygril/Plugin/XPC Service-Bridging-Header.h"; + PRODUCT_BUNDLE_IDENTIFIER = com.dayu.fcpbeautygirl.fxplug; + PRODUCT_NAME = "FCP-BeautyGirl $(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "FCP-BeautyGirl/Plugin/XPC Service-Bridging-Header.h"; WRAPPER_EXTENSION = pluginkit; }; name = Debug; @@ -339,15 +339,15 @@ ENABLE_HARDENED_RUNTIME = YES; ENABLE_USER_SCRIPT_SANDBOXING = NO; GCC_PRECOMPILE_PREFIX_HEADER = YES; - INFOPLIST_FILE = beatygril/Plugin/Info.plist; + INFOPLIST_FILE = FCP-BeautyGirl/Plugin/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( "$(inherited)", "@loader_path/../Frameworks", ); MACH_O_TYPE = mh_execute; - PRODUCT_BUNDLE_IDENTIFIER = com.dayu.beatygril.fxplug; - PRODUCT_NAME = "beatygril $(TARGET_NAME)"; - SWIFT_OBJC_BRIDGING_HEADER = "beatygril/Plugin/XPC Service-Bridging-Header.h"; + PRODUCT_BUNDLE_IDENTIFIER = com.dayu.fcpbeautygirl.fxplug; + PRODUCT_NAME = "FCP-BeautyGirl $(TARGET_NAME)"; + SWIFT_OBJC_BRIDGING_HEADER = "FCP-BeautyGirl/Plugin/XPC Service-Bridging-Header.h"; WRAPPER_EXTENSION = pluginkit; }; name = Release; @@ -355,7 +355,7 @@ 6945FCD13088B7220013E108 /* Debug configuration for PBXNativeTarget "Wrapper Application" */ = { isa = XCBuildConfiguration; buildSettings = { - CODE_SIGN_ENTITLEMENTS = "beatygril/Wrapper Application/SandboxEntitlements.entitlements"; + CODE_SIGN_ENTITLEMENTS = "FCP-BeautyGirl/Wrapper Application/SandboxEntitlements.entitlements"; OTHER_LDFLAGS = ("$(inherited)", "-framework", CoreServices, ); CODE_SIGN_IDENTITY = "Developer ID Application"; CODE_SIGN_INJECT_BASE_ENTITLEMENTS = NO; @@ -363,17 +363,17 @@ DEVELOPMENT_TEAM = B3W25FX5H5; ENABLE_HARDENED_RUNTIME = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; - INFOPLIST_FILE = "beatygril/Wrapper Application/Info.plist"; - PRODUCT_BUNDLE_IDENTIFIER = com.dayu.beatygril; - PRODUCT_NAME = beatygril; - SWIFT_OBJC_BRIDGING_HEADER = "beatygril/Wrapper Application/Wrapper Application-Bridging-Header.h"; + INFOPLIST_FILE = "FCP-BeautyGirl/Wrapper Application/Info.plist"; + PRODUCT_BUNDLE_IDENTIFIER = com.dayu.fcpbeautygirl; + PRODUCT_NAME = FCP-BeautyGirl; + SWIFT_OBJC_BRIDGING_HEADER = "FCP-BeautyGirl/Wrapper Application/Wrapper Application-Bridging-Header.h"; }; name = Debug; }; 6945FCD23088B7220013E108 /* Release configuration for PBXNativeTarget "Wrapper Application" */ = { isa = XCBuildConfiguration; buildSettings = { - CODE_SIGN_ENTITLEMENTS = "beatygril/Wrapper Application/SandboxEntitlements.entitlements"; + CODE_SIGN_ENTITLEMENTS = "FCP-BeautyGirl/Wrapper Application/SandboxEntitlements.entitlements"; OTHER_LDFLAGS = ("$(inherited)", "-framework", CoreServices, ); CODE_SIGN_IDENTITY = "Developer ID Application"; CODE_SIGN_INJECT_BASE_ENTITLEMENTS = NO; @@ -381,14 +381,14 @@ DEVELOPMENT_TEAM = B3W25FX5H5; ENABLE_HARDENED_RUNTIME = YES; GCC_PRECOMPILE_PREFIX_HEADER = YES; - INFOPLIST_FILE = "beatygril/Wrapper Application/Info.plist"; - PRODUCT_BUNDLE_IDENTIFIER = com.dayu.beatygril; - PRODUCT_NAME = beatygril; - SWIFT_OBJC_BRIDGING_HEADER = "beatygril/Wrapper Application/Wrapper Application-Bridging-Header.h"; + INFOPLIST_FILE = "FCP-BeautyGirl/Wrapper Application/Info.plist"; + PRODUCT_BUNDLE_IDENTIFIER = com.dayu.fcpbeautygirl; + PRODUCT_NAME = FCP-BeautyGirl; + SWIFT_OBJC_BRIDGING_HEADER = "FCP-BeautyGirl/Wrapper Application/Wrapper Application-Bridging-Header.h"; }; name = Release; }; - 6945FCD43088B7220013E108 /* Debug configuration for PBXProject "beatygril" */ = { + 6945FCD43088B7220013E108 /* Debug configuration for PBXProject "FCP-BeautyGirl" */ = { isa = XCBuildConfiguration; buildSettings = { ADDITIONAL_SDKS = /Library/Developer/SDKs/FxPlug.sdk; @@ -461,7 +461,7 @@ }; name = Debug; }; - 6945FCD53088B7220013E108 /* Release configuration for PBXProject "beatygril" */ = { + 6945FCD53088B7220013E108 /* Release configuration for PBXProject "FCP-BeautyGirl" */ = { isa = XCBuildConfiguration; buildSettings = { ADDITIONAL_SDKS = /Library/Developer/SDKs/FxPlug.sdk; @@ -531,11 +531,11 @@ /* End XCBuildConfiguration section */ /* Begin XCConfigurationList section */ - 6945FC863088B7220013E108 /* Build configuration list for PBXProject "beatygril" */ = { + 6945FC863088B7220013E108 /* Build configuration list for PBXProject "FCP-BeautyGirl" */ = { isa = XCConfigurationList; buildConfigurations = ( - 6945FCD43088B7220013E108 /* Debug configuration for PBXProject "beatygril" */, - 6945FCD53088B7220013E108 /* Release configuration for PBXProject "beatygril" */, + 6945FCD43088B7220013E108 /* Debug configuration for PBXProject "FCP-BeautyGirl" */, + 6945FCD53088B7220013E108 /* Release configuration for PBXProject "FCP-BeautyGirl" */, ); defaultConfigurationName = Release; }; diff --git a/beatygril/beatygril.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj/project.xcworkspace/contents.xcworkspacedata similarity index 100% rename from beatygril/beatygril.xcodeproj/project.xcworkspace/contents.xcworkspacedata rename to FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj/project.xcworkspace/contents.xcworkspacedata diff --git a/beatygril/beatygril/Plugin/beatygrilPlugIn.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/FCPBeautyGirlPlugIn.h similarity index 72% rename from beatygril/beatygril/Plugin/beatygrilPlugIn.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/FCPBeautyGirlPlugIn.h index 83e3d22..2ab900f 100644 --- a/beatygril/beatygril/Plugin/beatygrilPlugIn.h +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/FCPBeautyGirlPlugIn.h @@ -2,7 +2,7 @@ #import #import "PGBeautyTypes.h" -@interface beatygrilPlugIn : NSObject +@interface FCPBeautyGirlPlugIn : NSObject @property (nonatomic, assign) id apiManager; - (PGBeautySettings)settingsAtTime:(CMTime)time; - (void)analyzeForward; diff --git a/beatygril/beatygril/Plugin/beatygrilPlugIn.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/FCPBeautyGirlPlugIn.m similarity index 99% rename from beatygril/beatygril/Plugin/beatygrilPlugIn.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/FCPBeautyGirlPlugIn.m index a106434..882d66e 100644 --- a/beatygril/beatygril/Plugin/beatygrilPlugIn.m +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/FCPBeautyGirlPlugIn.m @@ -1,4 +1,4 @@ -#import "beatygrilPlugIn.h" +#import "FCPBeautyGirlPlugIn.h" #import "PGParameterIDs.h" #import "PGBeautyRenderer.h" #import "PGFaceProcessor.h" @@ -12,7 +12,7 @@ static os_log_t PGRenderLog(void) { static os_log_t log; static dispatch_once_t once; - dispatch_once(&once, ^{ log=os_log_create("com.dayu.beatygril", "render"); }); + dispatch_once(&once, ^{ log=os_log_create("com.dayu.fcpbeautygirl", "render"); }); return log; } @@ -84,7 +84,7 @@ static CIImage *PGImageFromTile(FxImageTile *tile) { return [image imageByApplyingTransform:CGAffineTransformMakeTranslation(b.left,b.bottom)]; } -@interface beatygrilPlugIn () +@interface FCPBeautyGirlPlugIn () @property (strong) PGBeautyRenderer *beautyRenderer; @property (strong) PGFaceProcessor *faceProcessor; @property (strong) PGFaceProcessor *analysisFaceProcessor; @@ -99,7 +99,7 @@ static CIImage *PGImageFromTile(FxImageTile *tile) { @property (strong) NSHashTable *inspectorViews; @end -@implementation beatygrilPlugIn +@implementation FCPBeautyGirlPlugIn - (instancetype)initWithAPIManager:(id)manager { if ((self=[super init])) { _apiManager=manager; diff --git a/beatygril/beatygril/Plugin/Info.plist b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/Info.plist similarity index 95% rename from beatygril/beatygril/Plugin/Info.plist rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/Info.plist index 8f064d5..842a2e0 100644 --- a/beatygril/beatygril/Plugin/Info.plist +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/Info.plist @@ -17,9 +17,9 @@ CFBundlePackageType XPC! CFBundleShortVersionString - 1.3.1 + 1.3.2 CFBundleVersion - 16 + 17 NSHumanReadableCopyright PlugInKit @@ -57,7 +57,7 @@ className - beatygrilPlugIn + FCPBeautyGirlPlugIn displayName 大鱼人像美化 group @@ -72,7 +72,7 @@ uuid FB14B0E6-59B2-4836-916F-CD0C559E9241 version - 1.3.1 + 1.3.2 className @@ -84,7 +84,7 @@ uuid E0E432C8-3D71-4ABA-B006-E7F519E06C87 version - 1.3.1 + 1.3.2 protocolNames FxOnScreenControl diff --git a/beatygril/beatygril/Plugin/PGBeautyRenderer.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGBeautyRenderer.h similarity index 100% rename from beatygril/beatygril/Plugin/PGBeautyRenderer.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGBeautyRenderer.h diff --git a/beatygril/beatygril/Plugin/PGBeautyRenderer.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGBeautyRenderer.m similarity index 100% rename from beatygril/beatygril/Plugin/PGBeautyRenderer.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGBeautyRenderer.m diff --git a/beatygril/beatygril/Plugin/PGBeautyTypes.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGBeautyTypes.h similarity index 100% rename from beatygril/beatygril/Plugin/PGBeautyTypes.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGBeautyTypes.h diff --git a/beatygril/beatygril/Plugin/PGFaceProcessor.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceProcessor.h similarity index 100% rename from beatygril/beatygril/Plugin/PGFaceProcessor.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceProcessor.h diff --git a/beatygril/beatygril/Plugin/PGFaceProcessor.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceProcessor.m similarity index 99% rename from beatygril/beatygril/Plugin/PGFaceProcessor.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceProcessor.m index 8e5dd9f..ba9841a 100644 --- a/beatygril/beatygril/Plugin/PGFaceProcessor.m +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceProcessor.m @@ -5,7 +5,7 @@ #include #include -static NSString * const PGFaceErrorDomain = @"media.dayu.PaintFCP.Face"; +static NSString * const PGFaceErrorDomain = @"com.dayu.fcpbeautygirl.face"; // Contour origin / internal anchor, in the reference's recovered pin order. // The unused middle entry of each reference triplet is intentionally omitted. static const uint8_t PGThinPins[17][2] = { diff --git a/beatygril/beatygril/Plugin/PGFaceSelectOSC.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceSelectOSC.m similarity index 100% rename from beatygril/beatygril/Plugin/PGFaceSelectOSC.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGFaceSelectOSC.m diff --git a/beatygril/beatygril/Plugin/PGInspectorState.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorState.h similarity index 100% rename from beatygril/beatygril/Plugin/PGInspectorState.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorState.h diff --git a/beatygril/beatygril/Plugin/PGInspectorState.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorState.m similarity index 100% rename from beatygril/beatygril/Plugin/PGInspectorState.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorState.m diff --git a/beatygril/beatygril/Plugin/PGInspectorView.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorView.h similarity index 100% rename from beatygril/beatygril/Plugin/PGInspectorView.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorView.h diff --git a/beatygril/beatygril/Plugin/PGInspectorView.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorView.m similarity index 100% rename from beatygril/beatygril/Plugin/PGInspectorView.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGInspectorView.m diff --git a/beatygril/beatygril/Plugin/PGParameterIDs.h b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGParameterIDs.h similarity index 100% rename from beatygril/beatygril/Plugin/PGParameterIDs.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/PGParameterIDs.h diff --git a/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/en.lproj/InfoPlist.strings b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/en.lproj/InfoPlist.strings new file mode 100644 index 0000000..3240d19 --- /dev/null +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/en.lproj/InfoPlist.strings @@ -0,0 +1 @@ +"FCP-BeautyGirl::FxPlug Name" = "大鱼人像美化"; diff --git a/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/en.lproj/Localizable.strings b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/en.lproj/Localizable.strings new file mode 100644 index 0000000..76ac49e --- /dev/null +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/en.lproj/Localizable.strings @@ -0,0 +1 @@ +"FCP-BeautyGirl::FxPlug Description" = "Portrait smoothing, skin tone, face shaping and automatic face tracking."; diff --git a/beatygril/beatygril/Plugin/main.m b/FCP-BeautyGirl/FCP-BeautyGirl/Plugin/main.m similarity index 100% rename from beatygril/beatygril/Plugin/main.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Plugin/main.m diff --git a/beatygril/beatygril/Wrapper Application/AppDelegate.h b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/AppDelegate.h similarity index 88% rename from beatygril/beatygril/Wrapper Application/AppDelegate.h rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/AppDelegate.h index f3f8e19..fc68790 100644 --- a/beatygril/beatygril/Wrapper Application/AppDelegate.h +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/AppDelegate.h @@ -1,6 +1,6 @@ // // AppDelegate.h -// beatygril +// FCP-BeautyGirl // // Created by dayu on 2026/10/21. // diff --git a/beatygril/beatygril/Wrapper Application/AppDelegate.m b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/AppDelegate.m similarity index 97% rename from beatygril/beatygril/Wrapper Application/AppDelegate.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/AppDelegate.m index 1526898..84e0bfd 100644 --- a/beatygril/beatygril/Wrapper Application/AppDelegate.m +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/AppDelegate.m @@ -8,7 +8,7 @@ @implementation AppDelegate - (void)applicationDidFinishLaunching:(NSNotification *)notification { - self.window.title = @"大鱼人像美化 · 免费开源"; + self.window.title = @"FCP-BeautyGirl · 大鱼人像美化"; [self.window setContentSize:NSMakeSize(800, 450)]; self.window.styleMask &= ~NSWindowStyleMaskResizable; self.window.backgroundColor = [NSColor colorWithRed:0.94 green:0.92 blue:0.85 alpha:1]; diff --git a/beatygril/beatygril/Wrapper Application/Base.lproj/MainMenu.xib b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Base.lproj/MainMenu.xib similarity index 98% rename from beatygril/beatygril/Wrapper Application/Base.lproj/MainMenu.xib rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Base.lproj/MainMenu.xib index 57d03a5..513b23c 100644 --- a/beatygril/beatygril/Wrapper Application/Base.lproj/MainMenu.xib +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Base.lproj/MainMenu.xib @@ -20,11 +20,11 @@ - + - + - + @@ -38,7 +38,7 @@ - + @@ -56,7 +56,7 @@ - + @@ -669,7 +669,7 @@ - + @@ -679,7 +679,7 @@ - + diff --git a/beatygril/beatygril/Wrapper Application/Info.plist b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Info.plist similarity index 88% rename from beatygril/beatygril/Wrapper Application/Info.plist rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Info.plist index b1b98bc..ad6ec01 100644 --- a/beatygril/beatygril/Wrapper Application/Info.plist +++ b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Info.plist @@ -4,6 +4,8 @@ CFBundleDevelopmentRegion $(DEVELOPMENT_LANGUAGE) + CFBundleDisplayName + FCP-BeautyGirl · 大鱼人像美化 CFBundleExecutable $(EXECUTABLE_NAME) CFBundleIconFile @@ -17,9 +19,9 @@ CFBundlePackageType APPL CFBundleShortVersionString - 1.3.1 + 1.3.2 CFBundleVersion - 16 + 17 LSMinimumSystemVersion $(MACOSX_DEPLOYMENT_TARGET) NSHumanReadableCopyright diff --git a/beatygril/beatygril/Wrapper Application/Resources/LauncherInfo.png b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Resources/LauncherInfo.png similarity index 100% rename from beatygril/beatygril/Wrapper Application/Resources/LauncherInfo.png rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Resources/LauncherInfo.png diff --git a/beatygril/beatygril/Wrapper Application/SandboxEntitlements.entitlements b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/SandboxEntitlements.entitlements similarity index 100% rename from beatygril/beatygril/Wrapper Application/SandboxEntitlements.entitlements rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/SandboxEntitlements.entitlements diff --git a/beatygril/beatygril/Wrapper Application/en.lproj/Credits.rtf b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/en.lproj/Credits.rtf similarity index 100% rename from beatygril/beatygril/Wrapper Application/en.lproj/Credits.rtf rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/en.lproj/Credits.rtf diff --git a/beatygril/beatygril/Wrapper Application/en.lproj/InfoPlist.strings b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/en.lproj/InfoPlist.strings similarity index 100% rename from beatygril/beatygril/Wrapper Application/en.lproj/InfoPlist.strings rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/en.lproj/InfoPlist.strings diff --git a/beatygril/beatygril/Wrapper Application/main.m b/FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/main.m similarity index 100% rename from beatygril/beatygril/Wrapper Application/main.m rename to FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/main.m diff --git a/beatygril/beatygril/Plugin/en.lproj/InfoPlist.strings b/beatygril/beatygril/Plugin/en.lproj/InfoPlist.strings deleted file mode 100644 index 9a5f273..0000000 --- a/beatygril/beatygril/Plugin/en.lproj/InfoPlist.strings +++ /dev/null @@ -1,3 +0,0 @@ -/* Localized versions of Info.plist keys */ - -"beatygril::FxPlug Name" = "beatygril"; diff --git a/beatygril/beatygril/Plugin/en.lproj/Localizable.strings b/beatygril/beatygril/Plugin/en.lproj/Localizable.strings deleted file mode 100644 index 7f52f3d..0000000 --- a/beatygril/beatygril/Plugin/en.lproj/Localizable.strings +++ /dev/null @@ -1,4 +0,0 @@ -/* Localized versions of Info.plist keys */ - -"beatygril::FxPlug Description" = "A helpful description of\nwhat this plugin does."; - diff --git a/product.json b/product.json new file mode 100644 index 0000000..c138aa4 --- /dev/null +++ b/product.json @@ -0,0 +1,25 @@ +{ + "name": "FCP-BeautyGirl", + "version": "1.3.2", + "build": "17", + "bundleIdentifier": "com.dayu.fcpbeautygirl", + "pluginName": "FCP-BeautyGirl XPC Service.pluginkit", + "pluginBundleIdentifier": "com.dayu.fcpbeautygirl.fxplug", + "pluginClass": "FCPBeautyGirlPlugIn", + "sourceRoot": "FCP-BeautyGirl", + "sourceDirectory": "FCP-BeautyGirl/FCP-BeautyGirl", + "xcodeProject": "FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj", + "scheme": "Wrapper Application", + "installationPath": "/Library/Plug-Ins/FxPlug/FCP-BeautyGirl.app", + "filterUUID": "FB14B0E6-59B2-4836-916F-CD0C559E9241", + "teamIdentifier": "B3W25FX5H5", + "legacyProducts": [ + { + "name": "beatygril", + "bundleIdentifier": "com.dayu.beatygril", + "pluginName": "beatygril XPC Service.pluginkit", + "pluginBundleIdentifier": "com.dayu.beatygril.fxplug", + "installationPath": "/Library/Plug-Ins/FxPlug/beatygril.app" + } + ] +} diff --git a/scripts/deliver.py b/scripts/deliver.py index b3d04d6..3a2facd 100755 --- a/scripts/deliver.py +++ b/scripts/deliver.py @@ -9,7 +9,7 @@ parser.add_argument('--wait-for-hosts',action='store_true',help='After notarizat parser.add_argument('--user-tests',action='store_true',help='After non-UI installed-app verification, record native effect QA as pending user testing and clean known generated copies without the interactive validation prompt.') parser.add_argument('--resume-prepared',action='store_true',help='Resume an already Accepted and stapled staged app after checking its recorded signature, version and unchanged product source.') args=parser.parse_args() -bundle_id='com.dayu.beatygril' +bundle_id='com.dayu.fcpbeautygirl' lock=pathlib.Path('/Users/dayu/.codex/app-delivery-locks')/(bundle_id+'.lock') lock.parent.mkdir(parents=True,exist_ok=True) try:lock.mkdir() @@ -17,12 +17,12 @@ except FileExistsError:raise SystemExit('Delivery lock occupied; inspect owner.j (lock/'owner.json').write_text(json.dumps({'pid':os.getpid(),'cwd':str(root),'bundle_id':bundle_id})) staging=pathlib.Path('/tmp/paintfcp-build-20261021') logs=root/'build'/'delivery';logs.mkdir(parents=True,exist_ok=True) -app=staging/'Build/Products/Release/beatygril.app' -installed=pathlib.Path('/Library/Plug-Ins/FxPlug/beatygril.app') +app=staging/'Build/Products/Release/FCP-BeautyGirl.app' +installed=pathlib.Path('/Library/Plug-Ins/FxPlug/FCP-BeautyGirl.app') archive=logs/'notarization.zip' identity='Developer ID Application: zhong luo (B3W25FX5H5)' keychain='/Users/dayu/Library/Keychains/login.keychain-db' -previous=logs/'previous-beatygril.app' +previous=logs/'previous-FCP-BeautyGirl.app' receipt_path=logs/'delivery-receipt.json' receipt={'status':'preparing','bundleIdentifier':bundle_id,'installationPath':str(installed), 'options':{'waitForHosts':args.wait_for_hosts,'userTests':args.user_tests}, @@ -80,7 +80,7 @@ def cleanup_known_products(): try: delivery_source={'commit':run(['git','rev-parse','HEAD']).strip(), 'trackedWorktreeChanges':run(['git','status','--porcelain','--untracked-files=no']).splitlines()} - plugin=app/'Contents/PlugIns/beatygril XPC Service.pluginkit' + plugin=app/'Contents/PlugIns/FCP-BeautyGirl XPC Service.pluginkit' if args.resume_prepared: old_receipt=json.loads(receipt_path.read_text()) result=old_receipt.get('notarization',{}) @@ -94,7 +94,7 @@ try: if not expected or not actual or expected.group(1)!=actual.group(1):raise RuntimeError('Prepared signature hash changed') if info.get('CFBundleShortVersionString')!=old_receipt.get('version') or info.get('CFBundleVersion')!=old_receipt.get('build'):raise RuntimeError('Prepared version changed') source_commit=old_receipt.get('source',{}).get('commit') - if not source_commit or run(['git','diff',source_commit,'--','beatygril']).strip():raise RuntimeError('Product source changed since prepared build') + if not source_commit or run(['git','diff',source_commit,'--','FCP-BeautyGirl']).strip():raise RuntimeError('Product source changed since prepared build') receipt.update(old_receipt);receipt.pop('failure',None) receipt['resumedBy']=delivery_source receipt['options']={'waitForHosts':args.wait_for_hosts,'userTests':args.user_tests,'resumePrepared':True} @@ -107,14 +107,14 @@ try: identities=run(['security','find-identity','-v','-p','codesigning',keychain]) if identity not in identities:raise RuntimeError('Valid Developer ID Application identity is unavailable') print('Building universal Release…',flush=True) - run(['xcodebuild','-project','beatygril/beatygril.xcodeproj','-scheme','Wrapper Application','-configuration','Release','-derivedDataPath',str(staging),'-destination','generic/platform=macOS','build'],logs/'build.log') + run(['xcodebuild','-project','FCP-BeautyGirl/FCP-BeautyGirl.xcodeproj','-scheme','Wrapper Application','-configuration','Release','-derivedDataPath',str(staging),'-destination','generic/platform=macOS','build'],logs/'build.log') # Xcode can register a fresh build. Remove this known generated path before # lengthy signing/notarization while a user may still be testing the old app. unregister_generated_plugin(plugin) for framework in sorted((plugin/'Contents/Frameworks').glob('*.framework')): run(['codesign','--force','--timestamp','--options','runtime','--sign',identity,str(framework)]) run(['codesign','--force','--timestamp','--options','runtime','--sign',identity,str(plugin)]) - run(['codesign','--force','--timestamp','--options','runtime','--entitlements',str(root/'beatygril/beatygril/Wrapper Application/SandboxEntitlements.entitlements'),'--sign',identity,str(app)]) + run(['codesign','--force','--timestamp','--options','runtime','--entitlements',str(root/'FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/SandboxEntitlements.entitlements'),'--sign',identity,str(app)]) run(['codesign','--verify','--deep','--strict',str(app)]) info=require_product(app) receipt['version']=info.get('CFBundleShortVersionString');receipt['build']=info.get('CFBundleVersion') @@ -156,11 +156,11 @@ try: signature=subprocess.run(['codesign','-dvvv',str(installed)],capture_output=True,text=True,check=True).stderr if info.get('CFBundleIdentifier')!=bundle_id or 'TeamIdentifier=B3W25FX5H5' not in signature:raise RuntimeError('Installed app identity mismatch') (logs/'installed-signature.txt').write_text(signature) - run(['pluginkit','-a',str(installed/'Contents/PlugIns/beatygril XPC Service.pluginkit')]) + run(['pluginkit','-a',str(installed/'Contents/PlugIns/FCP-BeautyGirl XPC Service.pluginkit')]) # Xcode may register its build product. Only the installed plugin should # be discoverable while native host validation is in progress. unregister_generated_plugin(plugin) - installed_plugin=installed/'Contents/PlugIns/beatygril XPC Service.pluginkit' + installed_plugin=installed/'Contents/PlugIns/FCP-BeautyGirl XPC Service.pluginkit' plugin_info=plistlib.loads((installed_plugin/'Contents/Info.plist').read_bytes()) discovered=run(['pluginkit','-m','-A','-D','-v','-i',plugin_info['CFBundleIdentifier']]) if str(installed_plugin) not in discovered:raise RuntimeError('PluginKit did not report the formal installed plug-in path') diff --git a/scripts/publish-release.py b/scripts/publish-release.py index f80d91c..525a1db 100644 --- a/scripts/publish-release.py +++ b/scripts/publish-release.py @@ -38,7 +38,7 @@ with zipfile.ZipFile(source_zip) as z: assert z.testzip() is None and any(n.endswith('/Wrapper Application/AppDelegate.m') for n in z.namelist()) status=request('/dayu-publisher/v1/status');assert status['can_publish'] and status['can_upload'] and 'seo' in status['fields'] source=upload('source',ROOT/'build/Dayu-Portrait-1.2.0-source.zip','application/zip') -card=upload('card',ROOT/'beatygril/beatygril/Wrapper Application/Resources/LauncherInfo.png','image/png') +card=upload('card',ROOT/'FCP-BeautyGirl/FCP-BeautyGirl/Wrapper Application/Resources/LauncherInfo.png','image/png') content=(ROOT/'releases/1.2.0/article.html').read_text().replace('{{source_url}}',html.escape(source['url'],quote=True)).replace('{{card_url}}',html.escape(card['url'],quote=True)) seo={ 'title':{'enabled':True,'value':'大鱼人像美化 1.2.0|FCP / Motion 免费开源自动美颜插件'}, diff --git a/scripts/test-host.sh b/scripts/test-host.sh index 4964af9..15c484b 100755 --- a/scripts/test-host.sh +++ b/scripts/test-host.sh @@ -1,13 +1,13 @@ #!/bin/zsh set -euo pipefail cd "${0:A:h:h}" -output_dir=$(mktemp -d /tmp/paintfcp-host-tests.XXXXXX) +output_dir=$(mktemp -d /tmp/fcp-beautygirl-host-tests.XXXXXX) trap 'rm -rf "$output_dir"' EXIT -plugin_dir="$PWD/beatygril/beatygril/Plugin" +plugin_dir="$PWD/FCP-BeautyGirl/FCP-BeautyGirl/Plugin" sdk_frameworks=/Library/Developer/SDKs/FxPlug.sdk/Library/Frameworks runtime_frameworks=/Library/Developer/Frameworks compiler_extra=() -if [[ "${PAINTFCP_HOST_ASAN:-0}" == 1 ]]; then +if [[ "${FCP_BEAUTYGIRL_HOST_ASAN:-0}" == 1 ]]; then compiler_extra=(-fsanitize=address -g) fi xcrun clang "${compiler_extra[@]}" -fobjc-arc -fmodules -Wall -Wextra -Wno-unused-parameter \ @@ -16,7 +16,7 @@ xcrun clang "${compiler_extra[@]}" -fobjc-arc -fmodules -Wall -Wextra -Wno-unuse -Wl,-rpath,"$runtime_frameworks" \ "$plugin_dir/PGBeautyRenderer.m" "$plugin_dir/PGFaceProcessor.m" \ "$plugin_dir/PGInspectorState.m" "$plugin_dir/PGInspectorView.m" \ - "$plugin_dir/beatygrilPlugIn.m" tests/host_adapter_tests.m \ + "$plugin_dir/FCPBeautyGirlPlugIn.m" tests/host_adapter_tests.m \ -framework Foundation -framework AppKit -framework CoreImage -framework CoreGraphics \ -framework CoreMedia -framework CoreVideo -framework IOSurface -framework Metal \ -framework Vision -framework ImageIO -framework FxPlug -framework PluginManager \ diff --git a/scripts/test-inspector.sh b/scripts/test-inspector.sh index b439277..d23d4f2 100755 --- a/scripts/test-inspector.sh +++ b/scripts/test-inspector.sh @@ -1,11 +1,11 @@ #!/bin/zsh set -euo pipefail cd "${0:A:h:h}" -output_dir=$(mktemp -d /tmp/paintfcp-inspector-tests.XXXXXX) +output_dir=$(mktemp -d /tmp/fcp-beautygirl-inspector-tests.XXXXXX) trap 'rm -rf "$output_dir"' EXIT -plugin_dir="$PWD/beatygril/beatygril/Plugin" +plugin_dir="$PWD/FCP-BeautyGirl/FCP-BeautyGirl/Plugin" compiler_extra=() -if [[ "${PAINTFCP_INSPECTOR_ASAN:-0}" == 1 ]]; then +if [[ "${FCP_BEAUTYGIRL_INSPECTOR_ASAN:-0}" == 1 ]]; then compiler_extra=(-fsanitize=address -g) fi python3 scripts/inspector-template.py audit 'Templates/大鱼人像美化/大鱼人像美化.moef' \ @@ -16,7 +16,7 @@ xcrun clang "${compiler_extra[@]}" -fobjc-arc -fmodules -Wall -Wextra -Wno-unuse -Wl,-rpath,/Library/Developer/Frameworks \ "$plugin_dir/PGBeautyRenderer.m" "$plugin_dir/PGFaceProcessor.m" \ "$plugin_dir/PGInspectorState.m" "$plugin_dir/PGInspectorView.m" \ - "$plugin_dir/beatygrilPlugIn.m" tests/inspector_tests.m \ + "$plugin_dir/FCPBeautyGirlPlugIn.m" tests/inspector_tests.m \ -framework Foundation -framework AppKit -framework CoreImage -framework CoreGraphics \ -framework CoreMedia -framework CoreVideo -framework IOSurface -framework Metal \ -framework Vision -framework ImageIO -framework FxPlug -framework PluginManager \ diff --git a/scripts/test-osc.sh b/scripts/test-osc.sh index ffaed0b..56d3e47 100755 --- a/scripts/test-osc.sh +++ b/scripts/test-osc.sh @@ -1,13 +1,13 @@ #!/bin/zsh set -euo pipefail cd "${0:A:h:h}" -output_dir=$(mktemp -d /tmp/paintfcp-osc-tests.XXXXXX) +output_dir=$(mktemp -d /tmp/fcp-beautygirl-osc-tests.XXXXXX) trap 'rm -rf "$output_dir"' EXIT -plugin_dir="$PWD/beatygril/beatygril/Plugin" +plugin_dir="$PWD/FCP-BeautyGirl/FCP-BeautyGirl/Plugin" sdk_frameworks=/Library/Developer/SDKs/FxPlug.sdk/Library/Frameworks runtime_frameworks=/Library/Developer/Frameworks compiler_extra=() -if [[ "${PAINTFCP_OSC_ASAN:-0}" == 1 ]]; then +if [[ "${FCP_BEAUTYGIRL_OSC_ASAN:-0}" == 1 ]]; then compiler_extra=(-fsanitize=address -g) fi xcrun clang "${compiler_extra[@]}" -fobjc-arc -fmodules -Wall -Wextra -Wno-unused-parameter \ diff --git a/scripts/test.sh b/scripts/test.sh index f13ba65..5e0706d 100755 --- a/scripts/test.sh +++ b/scripts/test.sh @@ -1,9 +1,9 @@ #!/bin/zsh set -euo pipefail cd "${0:A:h:h}" -output_dir=$(mktemp -d /tmp/paintfcp-tests.XXXXXX) +output_dir=$(mktemp -d /tmp/fcp-beautygirl-tests.XXXXXX) trap 'rm -rf "$output_dir"' EXIT -plugin_dir="$PWD/beatygril/beatygril/Plugin" +plugin_dir="$PWD/FCP-BeautyGirl/FCP-BeautyGirl/Plugin" common=(-fobjc-arc -fmodules -Wall -Wextra -Wno-unused-parameter -DCI_SILENCE_GL_DEPRECATION -mmacosx-version-min=13.0 -I "$plugin_dir" -framework Foundation -framework CoreImage -framework CoreGraphics -framework CoreMedia -framework Metal -framework Vision -framework ImageIO) xcrun clang "${common[@]}" "$plugin_dir/PGBeautyRenderer.m" tests/beauty_render_tests.m -o "$output_dir/beauty-tests" "$output_dir/beauty-tests" diff --git a/scripts/verify-release-package.py b/scripts/verify-release-package.py index f188b89..b181059 100644 --- a/scripts/verify-release-package.py +++ b/scripts/verify-release-package.py @@ -10,7 +10,7 @@ parser.add_argument('--expanded',default='build/pkg-expanded') parser.add_argument('--fixture',default='build/pkg-isolation') args=parser.parse_args() expanded=root/args.expanded/'Payload.pkg';payload=expanded/'Payload' -formal=Path('/Library/Plug-Ins/FxPlug/beatygril.app');packed=payload/'Library/Plug-Ins/FxPlug/beatygril.app' +formal=Path('/Library/Plug-Ins/FxPlug/FCP-BeautyGirl.app');packed=payload/'Library/Plug-Ins/FxPlug/FCP-BeautyGirl.app' sha=lambda p:hashlib.sha256(p.read_bytes()).hexdigest() def files(p): return {str(x.relative_to(p)):('symlink:'+os.readlink(x) if x.is_symlink() else sha(x)) for x in p.rglob('*') if x.is_file() or x.is_symlink()} @@ -33,7 +33,7 @@ base=root/args.fixture;base.mkdir(exist_ok=False) volume=base/'volume';home=base/'user';home.mkdir() start=post.index('CURRENT_ACTIVE=0') isolated='#!/bin/zsh\nset -eu\nTARGET_VOLUME="'+str(volume)+'"\nCONSOLE_USER="'+os.getlogin()+'"\nCONSOLE_UID="'+str(os.getuid())+'"\nCONSOLE_GROUP="staff"\nUSER_HOME="'+str(home)+'"\n'+post[start:] -isolated=isolated[:isolated.index('fx_verify_app "${TARGET_VOLUME%/}/Library/Plug-Ins/FxPlug/beatygril.app"')]+'exit 0\n' +isolated=isolated[:isolated.index('fx_verify_app "${TARGET_VOLUME%/}/Library/Plug-Ins/FxPlug/FCP-BeautyGirl.app"')]+'exit 0\n' isolated=isolated.replace('/usr/sbin/chown -R','/usr/bin/true') new_copy=next(l for l in isolated.splitlines() if l.startswith('/usr/bin/ditto "${TARGET_VOLUME%/}')) def refill(): diff --git a/tests/host_adapter_tests.m b/tests/host_adapter_tests.m index e151260..4f30131 100644 --- a/tests/host_adapter_tests.m +++ b/tests/host_adapter_tests.m @@ -5,7 +5,7 @@ #import #import #import -#import "beatygrilPlugIn.h" +#import "FCPBeautyGirlPlugIn.h" #import "PGParameterIDs.h" #import "PGFaceProcessor.h" #import "PGBeautyRenderer.h" @@ -209,19 +209,19 @@ static NSData *ExpectedCrop(PGHostTile *source, NSUInteger x, NSUInteger y, NSUI } return result; } -static NSData *Snapshot(beatygrilPlugIn *plugin, CMTime time) { +static NSData *Snapshot(FCPBeautyGirlPlugIn *plugin, CMTime time) { NSData *state = nil; NSError *error = nil; Check([plugin pluginState:&state atTime:time quality:kFxQuality_HIGH error:&error] && state.length > 0 && !error, @"plugin snapshot serializes through host parameter API"); return state; } -static BOOL Render(beatygrilPlugIn *plugin, PGHostTile *destination, NSArray *sources, NSData *state, CMTime time, NSError **error, BOOL *escaped) { +static BOOL Render(FCPBeautyGirlPlugIn *plugin, PGHostTile *destination, NSArray *sources, NSData *state, CMTime time, NSError **error, BOOL *escaped) { @try { return [plugin renderDestinationImage:destination sourceImages:sources pluginState:state atTime:time error:error]; } @catch (NSException *exception) { if (escaped) *escaped = YES; fprintf(stderr, "EXCEPTION: %s\n", exception.reason.UTF8String); return NO; } } -static void RejectState(beatygrilPlugIn *plugin, PGHostTile *destination, PGHostTile *source, NSData *state, NSString *description) { +static void RejectState(FCPBeautyGirlPlugIn *plugin, PGHostTile *destination, PGHostTile *source, NSData *state, NSString *description) { NSError *error = nil; BOOL escaped = NO; BOOL rendered = Render(plugin, destination, @[source], state, kCMTimeZero, &error, &escaped); Check(!rendered && !escaped && error != nil, description); @@ -353,7 +353,7 @@ static void PortraitAnatomyTests(NSString *fixture, CIImage *portrait) { NSData *originBaseline = nil; for (NSUInteger sourceTop = 0; sourceTop < 2; sourceTop++) for (NSUInteger destinationTop = 0; destinationTop < 2; destinationTop++) { @autoreleasepool { - PGHostAPI *api = [PGHostAPI new]; beatygrilPlugIn *plugin = [[beatygrilPlugIn alloc] initWithAPIManager:api]; + PGHostAPI *api = [PGHostAPI new]; FCPBeautyGirlPlugIn *plugin = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:api]; Check([plugin addParametersWithError:nil], @"anatomy case creates the real plugin parameters"); if (effect) api.values[@(controls[effect])] = @(values[effect]); PGHostTile *input = Tile(width, height, 37, -21, sourceTop ? kFxImageOrigin_TOP_LEFT : kFxImageOrigin_BOTTOM_LEFT); @@ -406,7 +406,7 @@ static void TrackingCoordinateTests(NSDictionary *archive, NSDictionary *hostVal values[@(PGTarget)] = @2; values[@(PGTrackEnabled)] = @YES; values[@(PGBigEye)] = @1; values[@(PGChin)] = @1; values[@(PGTrackData3)] = legacyString; PGHostAPI *legacyAPI = [PGHostAPI new]; legacyAPI.hostTime = time; - beatygrilPlugIn *legacy = [[beatygrilPlugIn alloc] initWithAPIManager:legacyAPI]; [legacy addParametersWithError:nil]; legacyAPI.values = [values mutableCopy]; + FCPBeautyGirlPlugIn *legacy = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:legacyAPI]; [legacy addParametersWithError:nil]; legacyAPI.values = [values mutableCopy]; PGHostTile *output = Tile(512,512,0,0,kFxImageOrigin_TOP_LEFT); Check(Render(legacy, output, @[source], Snapshot(legacy,time), time, nil, NULL), @"unmarked old coordinate archive renders through the real adapter"); NSData *legacyBytes = SurfaceBytes(output); @@ -420,7 +420,7 @@ static void TrackingCoordinateTests(NSDictionary *archive, NSDictionary *hostVal forged[@"hostCoordinateSpace"] = @"iosurface-ci-y-up-v1"; NSData *trustedTrack = PlistState(forged); PGHostAPI *trustedAPI = [PGHostAPI new]; trustedAPI.hostTime = time; - beatygrilPlugIn *trusted = [[beatygrilPlugIn alloc] initWithAPIManager:trustedAPI]; [trusted addParametersWithError:nil]; + FCPBeautyGirlPlugIn *trusted = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:trustedAPI]; [trusted addParametersWithError:nil]; trustedAPI.values = [values mutableCopy]; trustedAPI.values[@(PGTrackData3)] = [trustedTrack base64EncodedStringWithOptions:0]; Check(Render(trusted, output, @[source], Snapshot(trusted,time), time, nil, NULL), @"fresh plugin accepts a snapshot with marked legacy analysis data"); NSData *trustedBytes = SurfaceBytes(output); @@ -465,7 +465,7 @@ static BOOL Preview(PGHostTile *before, PGHostTile *after, NSString *path) { int main(int argc, const char *argv[]) { setbuf(stdout, NULL); @autoreleasepool { - PGHostAPI *api = [PGHostAPI new]; beatygrilPlugIn *plugin = [[beatygrilPlugIn alloc] initWithAPIManager:api]; + PGHostAPI *api = [PGHostAPI new]; FCPBeautyGirlPlugIn *plugin = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:api]; NSError *error = nil; Check([plugin addParametersWithError:&error] && !error, @"host creates complete parameter set"); UInt32 identifiers[] = {PGAmount,PGBrightness,PGRadius,PGSharpness,PGMix,PGThreshold,PGSoftness,PGEdgeProtect,PGShowMask,PGMidtone,PGHue,PGSaturation,PGHighPass,PGThin,PGFaceBoxes,PGSingleFace,PGSelection,PGShort,PGNarrow,PGChin,PGVFace,PGJaw,PGCheekbone,PGSmallHead,PGSmallHeadRange,PGFeatureProtect,PGTeeth,PGEyeBright,PGBigEye,PGTrackBoxes,PGFastMulti,PGJumpGuard,PGEvenTone,PGTonePreset,PGInvertMask,PGDebugChannel,PGTrackEnabled,PGTarget,PGAnalyzeForward,PGAnalyzeBackward,PGClearTrack,PGStatus,PGTrackData1,PGTrackData2,PGTrackData3,PGSmoothingEnabled,PGColorEnabled,PGShapeEnabled,PGDetailEnabled,PGInspectorPanel}; @@ -589,7 +589,7 @@ int main(int argc, const char *argv[]) { TrackingCoordinateTests(trackingArchive,api.values,portraitSource,portrait,api.hostTime); Check([api.values[@(PGTrackEnabled)] boolValue] && CMTimeCompare(api.lastSetBoolTime, api.hostTime) == 0, @"analysis enables saved target at host seed time"); NSData *trackedState = Snapshot(plugin, api.hostTime); - beatygrilPlugIn *restoredPlugin = [[beatygrilPlugIn alloc] initWithAPIManager:api]; + FCPBeautyGirlPlugIn *restoredPlugin = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:api]; Check(Render(restoredPlugin, portraitOutput, @[portraitSource], trackedState, api.hostTime, &error, NULL), @"fresh plugin instance uses automatic follow despite serialized legacy analysis settings"); [plugin analyzeBackward]; Check(api.backwardRequests == 1, @"backward analyze button calls host API"); @@ -598,7 +598,7 @@ int main(int argc, const char *argv[]) { [plugin setupAnalysisForTimeRange:desired frameDuration:CMTimeMake(1, 24) error:&error]; [plugin cleanupAnalysis:&error]; [plugin clearTracking]; Check([api.values[@(PGTrackData3)] length] == 0, @"clear button uses current host target"); PGHostAPI *writeFailureAPI = [PGHostAPI new]; - beatygrilPlugIn *writeFailurePlugin = [[beatygrilPlugIn alloc] initWithAPIManager:writeFailureAPI]; + FCPBeautyGirlPlugIn *writeFailurePlugin = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:writeFailureAPI]; [writeFailurePlugin addParametersWithError:&error]; [writeFailurePlugin analyzeForward]; [writeFailurePlugin setupAnalysisForTimeRange:clip frameDuration:CMTimeMake(1, 24) error:&error]; [writeFailurePlugin analyzeFrame:portraitSource atTime:writeFailureAPI.hostTime error:&error]; @@ -608,7 +608,7 @@ int main(int argc, const char *argv[]) { [writeFailurePlugin analyzeForward]; Check(writeFailureAPI.forwardRequests == 2, @"persistence failure releases analysis busy state for retry"); PGHostAPI *unavailable = [PGHostAPI new]; [unavailable.disabledAPIs addObject:@"FxParameterCreationAPI_v5"]; - beatygrilPlugIn *missingPlugin = [[beatygrilPlugIn alloc] initWithAPIManager:unavailable]; + FCPBeautyGirlPlugIn *missingPlugin = [[FCPBeautyGirlPlugIn alloc] initWithAPIManager:unavailable]; error = nil; Check(![missingPlugin addParametersWithError:&error] && error != nil, @"missing host creation API reports error"); [unavailable.disabledAPIs removeAllObjects]; unavailable.rejectedParameter = PGThin; error = nil; Check(![missingPlugin addParametersWithError:&error] && error != nil, @"host rejecting one control fails complete parameter creation"); diff --git a/tests/inspector_tests.m b/tests/inspector_tests.m index 96c56ae..ea9cee9 100644 --- a/tests/inspector_tests.m +++ b/tests/inspector_tests.m @@ -56,7 +56,7 @@ static PGInspectorState *State(NSDictionary *values,NSSet *disabled) { return [PGInspectorState stateWithValues:values disabledParameters:disabled?:[NSSet set] hasEdits:YES]; } static void RegistrationTests(void) { - PGHostAPI *api=[PGHostAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGHostAPI *api=[PGHostAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; NSUInteger visible=0;for(NSNumber *key in api.definitions){NSDictionary *d=api.definitions[key];if(!([d[@"flags"]unsignedIntValue]&kFxParameterFlag_HIDDEN)){visible++;Check(key.unsignedIntValue==PGInspectorPanel,@"only the custom panel is visible in the native parameter list");}} Check(visible==1,@"all duplicate standard controls and manual-analysis groups are hidden"); FxParameterFlags flags=[api.definitions[@(PGInspectorPanel)][@"flags"]unsignedIntValue]; @@ -136,7 +136,7 @@ static void ModelTests(void) { Check(s.faceChin==0 && s.faceBigEye==0 && s.skinBrightness==0 && s.skinTonePreset==0 && s.midtoneDetail==0 && s.highPassDetail==0 && s.showTrackBox==0,@"card eye switches bypass the complete associated effect group"); } static void ControllerTests(void) { - PGInspectorTestAPI *api=[PGInspectorTestAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGInspectorTestAPI *api=[PGInspectorTestAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; api.values[@(PGMidtone)]=@.5; PGInspectorController *c=[[PGInspectorController alloc]initWithAPIManager:api];[c refresh]; Check(c.available && Near([c.state valueForParameter:PGMidtone],.5) && !c.state.hasEdits,@"initial UI reads the current legacy/template values instead of replacing them"); @@ -169,7 +169,7 @@ static void ControllerTests(void) { [c setValue:.1 forParameter:PGBrightness];Check(Near([c.state valueForParameter:PGChin],-.8),@"new-time edits preserve the other controls from that time instead of a stale prior frame"); api.values=[api.undoValues mutableCopy];[c documentDidChange]; Check(Near([c.state valueForParameter:PGBrightness],[seekValues[@(PGBrightness)]doubleValue]),@"a host undo notification refreshes same-time state immediately without a timed wait"); - PGHostAPI *legacy=[PGHostAPI new];beatygrilPlugIn *legacyPlugin=[[beatygrilPlugIn alloc]initWithAPIManager:legacy];[legacyPlugin addParametersWithError:nil]; + PGHostAPI *legacy=[PGHostAPI new];FCPBeautyGirlPlugIn *legacyPlugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:legacy];[legacyPlugin addParametersWithError:nil]; legacy.values[@(PGDetailEnabled)]=@NO;legacy.values[@(PGHighPass)]=@.6;legacy.values[@(PGSharpness)]=@.4; PGInspectorController *imported=[[PGInspectorController alloc]initWithAPIManager:legacy];[imported refresh];[imported setValue:.3 forParameter:PGBrightness]; PGBeautySettings migrated=PGSettingsWithInspectorState(PGBeautyDefaults(),imported.state); @@ -185,7 +185,7 @@ static void ControllerTests(void) { Check(!offline.available && ![offline setValue:.2 forParameter:PGChin],@"missing host actions disable editing instead of unsafe parameter access"); } static void ViewInteractionTests(void) { - PGHostAPI *api=[PGHostAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGHostAPI *api=[PGHostAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; PGInspectorView *view=(PGInspectorView *)[plugin createViewForParameterID:PGInspectorPanel];[view refreshFromHost]; NSSlider *chin=(NSSlider *)FindControl(view,NSSlider.class,@"下巴");Check(chin!=nil && chin.enabled,@"custom view exposes an accessible native chin slider"); chin.doubleValue=-.75;Fire(chin);PGInspectorState *s=api.values[@(PGInspectorPanel)]; @@ -238,7 +238,7 @@ static void ViewInteractionTests(void) { } } static void BeautyControlInteractionTests(void) { - PGInspectorTestAPI *api=[PGInspectorTestAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGInspectorTestAPI *api=[PGInspectorTestAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; api.values[@(PGFeatureProtectionAmount)]=@.37;api.values[@(PGHighPass)]=@.63;api.values[@(PGHue)]=@12;api.values[@(PGBrightness)]=@.3; PGInspectorView *view=(PGInspectorView *)[plugin createViewForParameterID:PGInspectorPanel];[view refreshFromHost]; Check(Near([view.controller.state valueForParameter:PGFeatureProtectionAmount],.37) && !view.controller.state.hasEdits,@"an untouched inspector preserves native fractional protection when the legacy boolean is enabled"); @@ -276,7 +276,7 @@ static void BeautyControlInteractionTests(void) { Check(api.actionDepth==0 && api.actionStarts==api.actionEnds && api.accessViolations==0,@"all new numeric, bypass, reset and master interactions use balanced host actions"); } static void HostHandshakeTests(void) { - PGInspectorTestAPI *api=[PGInspectorTestAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGInspectorTestAPI *api=[PGInspectorTestAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; api.values[@(PGMidtone)]=@.5; api.parameterAPIsRequireAction=YES;api.actionRequiresView=YES; PGInspectorView *view=(PGInspectorView *)[plugin createViewForParameterID:PGInspectorPanel];[view refreshFromHost]; @@ -293,7 +293,7 @@ static void HostHandshakeTests(void) { Check(api.accessViolations==0 && api.actionDepth==0 && api.actionStarts==api.actionEnds,@"action-scoped connection, edits, failure and reconnection remain balanced"); } static void ContinuousPreviewTests(void) { - PGInspectorTestAPI *api=[PGInspectorTestAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGInspectorTestAPI *api=[PGInspectorTestAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; api.parameterAPIsRequireAction=YES;api.actionRequiresView=YES; PGInspectorView *view=(PGInspectorView *)[plugin createViewForParameterID:PGInspectorPanel];[view refreshFromHost]; NSArray *names=@[@"短脸",@"五官保护",@"非肤色区保护",@"微细锐化"],*ids=@[@(PGShort),@(PGFeatureProtectionAmount),@(PGNonSkinProtection),@(PGMicroDetail)]; @@ -319,7 +319,7 @@ static void ContinuousPreviewTests(void) { static void OptionalInspectorPreview(void) { NSString *path=NSProcessInfo.processInfo.environment[@"PAINTFCP_INSPECTOR_PNG"]; if(!path.length)return; - PGHostAPI *api=[PGHostAPI new];beatygrilPlugIn *plugin=[[beatygrilPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; + PGHostAPI *api=[PGHostAPI new];FCPBeautyGirlPlugIn *plugin=[[FCPBeautyGirlPlugIn alloc]initWithAPIManager:api];[plugin addParametersWithError:nil]; api.values[@(PGMidtone)]=@.4; PGInspectorView *view=(PGInspectorView *)[plugin createViewForParameterID:PGInspectorPanel];[view refreshFromHost]; [view setFrameSize:NSMakeSize(380,20)];