steventroughtonsmith / cartool Goto Github PK
View Code? Open in Web Editor NEWExport images from OS X / iOS .car CoreUI archives
Export images from OS X / iOS .car CoreUI archives
[catalog setValue:facet forKey:@"_storageRef"];
2018-10-26 14:11:43.054192+0800 cartool[7230:406857] -[__NSTaggedDate unsignedLongLongValue]: unrecognized selector sent to instance 0x1
2018-10-26 14:11:43.054852+0800 cartool[7230:406857] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[__NSTaggedDate unsignedLongLongValue]: unrecognized selector sent to instance 0x1'
*** First throw call stack:
(
0 CoreFoundation 0x00007fff3563443d __exceptionPreprocess + 256
1 libobjc.A.dylib 0x00007fff61545720 objc_exception_throw + 48
2 CoreFoundation 0x00007fff356b1255 -[NSObject(NSObject) __retain_OA] + 0
3 CoreFoundation 0x00007fff355d3ad0 forwarding + 1486
4 CoreFoundation 0x00007fff355d3478 _CF_forwarding_prep_0 + 120
5 Foundation 0x00007fff3791fb1a _NSSetUnsignedLongLongValueForKeyInIvar + 37
6 Foundation 0x00007fff37936580 -[NSObject(NSKeyValueCoding) setValue:forKey:] + 331
7 cartool 0x0000000100001871 exportCarFileAtPath + 433
8 cartool 0x00000001000025f4 main + 260
9 cartool 0x0000000100000f64 start + 52
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Assertion failed:
(tokenCount < maxCountIncludingZeroTerminator - 1), function CUIRenditionKeySetValueForAttribute, file /BuildRoot/Library/Caches/com.apple.xbs/Sources/CoreUI/CoreUI-366.1/CoreTheme/ThemeStorage/CUIThemeRendition_Support.m, line 228
Any idea how @3x assets are stored? It seems naively looking for assets with a scale factor of 3.0 for the .kCoreThemeIdiomPhone
does not work: mono0926@427dbd8
Create brew recipe to make installation easier
I'm trying to extract my Assets.car here. The tool gives me the following output but does not generate any data on disk. Shouldn't I find the contents in my "tmp" folder?
The assets file is from a tvOS project, in case that matters. If you'd like to have it for analysis, I can send it to you.
iMacRR:tmp rene$ cartool Assets.car /Users/rene/Documents/tmp
App Icon - Large/Back/Content
App Icon - Large/Front/Content
App Icon - Large/Middle/Content
App Icon - Small
App Icon - Small/Back/Content
App Icon - Small/Front/Content
App Icon - Small/Middle/Content
Brand Assets
Leaderboard/Poster
Leaderboard/Poster/Front/Content
Leaderboard/Poster/Middle/Content
Error when running command to extract .car contents to folder
i can't extract all pictures from assets.car which is packaged by xcode 9
Create brew recipe to make installation easier
some 3x picture not have
This tool can't extract AppIcon
.
Instead of:
for (NSNumber *scaleFactor in @[@1, @2, @3])
{
CUINamedImage *image = [catalog imageWithName:key scaleFactor:scaleFactor.doubleValue];
if (image && image.scale == scaleFactor.floatValue) [images addObject:image];
}
I tried simply:
[images addObjectsFromArray:[catalog imagesWithName:key]];
In my one test, this added 23 images to the array, which are of type CUINamedMultisizeImageSet.h
, which doesn't respond to -size
, and therefore crashes on CGSizeEqualToSize(image.size, CGSizeZero)
. Looks like this type is new in iOS 11 (it's not present in the iOS 10 runtime headers).
So if we want to make this work we'll have to add support for this type.
I'd like to submit a pull request but I can only do that if this project is licensed under a license with few restrictions such as Apache2 or MIT
Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '[<CUICatalog 0x1028412c0> setNilValueForKey]: could not set nil as the value for the key _storageRef.'
At first run :cartool[37635:515969] [framework] CUIThemeStore: No theme registered with id=18442823884578500406
run second:2019-02-28 10:19:23.211861+0800 cartool[37645:516265] -[NSTaggedPointerString unsignedLongLongValue]: unrecognized selector sent to instance 0x1
2019-02-28 10:19:23.212488+0800 cartool[37645:516265] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[NSTaggedPointerString unsignedLongLongValue]: unrecognized selector sent to instance 0x1'
*** First throw call stack:
(
0 CoreFoundation 0x00007fff4c3a8ded __exceptionPreprocess + 256
1 libobjc.A.dylib 0x00007fff78474720 objc_exception_throw + 48
2 CoreFoundation 0x00007fff4c426195 -[NSObject(NSObject) __retain_OA] + 0
3 CoreFoundation 0x00007fff4c34aa60 forwarding + 1486
4 CoreFoundation 0x00007fff4c34a408 _CF_forwarding_prep_0 + 120
5 Foundation 0x00007fff4e69c9ea _NSSetUnsignedLongLongValueForKeyInIvar + 37
6 Foundation 0x00007fff4e6b3450 -[NSObject(NSKeyValueCoding) setValue:forKey:] + 331
7 cartool 0x0000000100002373 exportCarFileAtPath + 435
8 cartool 0x00000001000030df main + 223
9 libdyld.dylib 0x00007fff79542ed9 start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
(lldb)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.