diff --git a/AppKit/AppKit.xcodeproj/project.pbxproj b/AppKit/AppKit.xcodeproj/project.pbxproj index ca7f1eab..4763a216 100644 --- a/AppKit/AppKit.xcodeproj/project.pbxproj +++ b/AppKit/AppKit.xcodeproj/project.pbxproj @@ -2194,6 +2194,11 @@ FE3C855E108779540018252A /* O2AffineTransform.m in Sources */ = {isa = PBXBuildFile; fileRef = FE3C854E108779540018252A /* O2AffineTransform.m */; }; FE3C855F108779540018252A /* O2Geometry.h in Headers */ = {isa = PBXBuildFile; fileRef = FE3C854F108779540018252A /* O2Geometry.h */; }; FE3C8560108779540018252A /* O2Geometry.m in Sources */ = {isa = PBXBuildFile; fileRef = FE3C8550108779540018252A /* O2Geometry.m */; }; + FE41B85912BEA2C800ED6C10 /* CATransaction.m in Sources */ = {isa = PBXBuildFile; fileRef = FE41B85812BEA2C800ED6C10 /* CATransaction.m */; }; + FE41B85A12BEA2C800ED6C10 /* CATransaction.m in Sources */ = {isa = PBXBuildFile; fileRef = FE41B85812BEA2C800ED6C10 /* CATransaction.m */; }; + FE41B85B12BEA2C800ED6C10 /* CATransaction.m in Sources */ = {isa = PBXBuildFile; fileRef = FE41B85812BEA2C800ED6C10 /* CATransaction.m */; }; + FE41B85C12BEA2C800ED6C10 /* CATransaction.m in Sources */ = {isa = PBXBuildFile; fileRef = FE41B85812BEA2C800ED6C10 /* CATransaction.m */; }; + FE41B85D12BEA2C800ED6C10 /* CATransaction.m in Sources */ = {isa = PBXBuildFile; fileRef = FE41B85812BEA2C800ED6C10 /* CATransaction.m */; }; FE43BE2111FFBAAD00119833 /* O2PDFBlock.h in Headers */ = {isa = PBXBuildFile; fileRef = FE43BE1F11FFBAAC00119833 /* O2PDFBlock.h */; }; FE43BE2211FFBAAD00119833 /* O2PDFBlock.m in Sources */ = {isa = PBXBuildFile; fileRef = FE43BE2011FFBAAC00119833 /* O2PDFBlock.m */; }; FE43BE2311FFBAAD00119833 /* O2PDFBlock.h in Headers */ = {isa = PBXBuildFile; fileRef = FE43BE1F11FFBAAC00119833 /* O2PDFBlock.h */; }; @@ -3272,6 +3277,16 @@ FE71F3CC11FD40B800E6F801 /* O2TTFDecoder.m in Sources */ = {isa = PBXBuildFile; fileRef = FE71F3C411FD40B800E6F801 /* O2TTFDecoder.m */; }; FE71F3CD11FD40B800E6F801 /* O2TTFDecoder.h in Headers */ = {isa = PBXBuildFile; fileRef = FE71F3C311FD40B800E6F801 /* O2TTFDecoder.h */; }; FE71F3CE11FD40B800E6F801 /* O2TTFDecoder.m in Sources */ = {isa = PBXBuildFile; fileRef = FE71F3C411FD40B800E6F801 /* O2TTFDecoder.m */; }; + FE74968812BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */; settings = {ATTRIBUTES = (Private, ); }; }; + FE74968912BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */; }; + FE74968A12BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */; settings = {ATTRIBUTES = (Private, ); }; }; + FE74968B12BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */; }; + FE74968C12BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */; settings = {ATTRIBUTES = (Private, ); }; }; + FE74968D12BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */; }; + FE74968E12BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */; settings = {ATTRIBUTES = (Private, ); }; }; + FE74968F12BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */; }; + FE74969012BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */; settings = {ATTRIBUTES = (Private, ); }; }; + FE74969112BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */ = {isa = PBXBuildFile; fileRef = FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */; }; FE7AA0CD10F9788100FEDD9C /* CAWindowOpenGLContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FE7AA0CB10F9788100FEDD9C /* CAWindowOpenGLContext.h */; }; FE7AA0CE10F9788100FEDD9C /* CAWindowOpenGLContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FE7AA0CC10F9788100FEDD9C /* CAWindowOpenGLContext.m */; }; FE7AA13110F97E3300FEDD9C /* CALayer.m in Sources */ = {isa = PBXBuildFile; fileRef = FED38C3110E13DCA00A2A651 /* CALayer.m */; }; @@ -3964,6 +3979,31 @@ FED56E6B11A2D89900D6D09B /* CARenderer.m in Sources */ = {isa = PBXBuildFile; fileRef = FED38C3210E13DCA00A2A651 /* CARenderer.m */; }; FED56E6C11A2D89E00D6D09B /* CATransform3D.m in Sources */ = {isa = PBXBuildFile; fileRef = FED38C3310E13DCA00A2A651 /* CATransform3D.m */; }; FED56E6D11A2D8A200D6D09B /* CAWindowOpenGLContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FE7AA0CB10F9788100FEDD9C /* CAWindowOpenGLContext.h */; }; + FEDEA8AD12C112E5008E5A59 /* CATransactionGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */; }; + FEDEA8AE12C112E5008E5A59 /* CATransactionGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */; }; + FEDEA8AF12C112E5008E5A59 /* CATransactionGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */; }; + FEDEA8B012C112E5008E5A59 /* CATransactionGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */; }; + FEDEA8B112C112E5008E5A59 /* CATransactionGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */; }; + FEDEA8B312C112EE008E5A59 /* CATransactionGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */; }; + FEDEA8B412C112EE008E5A59 /* CATransactionGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */; }; + FEDEA8B512C112EE008E5A59 /* CATransactionGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */; }; + FEDEA8B612C112EE008E5A59 /* CATransactionGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */; }; + FEDEA8B712C112EE008E5A59 /* CATransactionGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */; }; + FEDEA95412C13368008E5A59 /* CABase.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA95312C13368008E5A59 /* CABase.m */; }; + FEDEA95512C13368008E5A59 /* CABase.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA95312C13368008E5A59 /* CABase.m */; }; + FEDEA95612C13368008E5A59 /* CABase.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA95312C13368008E5A59 /* CABase.m */; }; + FEDEA95712C13368008E5A59 /* CABase.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA95312C13368008E5A59 /* CABase.m */; }; + FEDEA95812C13368008E5A59 /* CABase.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEA95312C13368008E5A59 /* CABase.m */; }; + FEDEAA9912C2639B008E5A59 /* CAValueFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */; }; + FEDEAA9A12C2639B008E5A59 /* CAValueFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */; }; + FEDEAA9B12C2639B008E5A59 /* CAValueFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */; }; + FEDEAA9C12C2639B008E5A59 /* CAValueFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */; }; + FEDEAA9D12C2639B008E5A59 /* CAValueFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */; }; + FEDEABAE12C98F4C008E5A59 /* CALayerContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */; }; + FEDEABAF12C98F4C008E5A59 /* CALayerContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */; }; + FEDEABB012C98F4C008E5A59 /* CALayerContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */; }; + FEDEABB112C98F4C008E5A59 /* CALayerContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */; }; + FEDEABB212C98F4C008E5A59 /* CALayerContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */; }; FEDF951F0CAF43E7009DC96F /* O2PDFContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDF951B0CAF43E7009DC96F /* O2PDFContext.h */; settings = {ATTRIBUTES = (Private, ); }; }; FEDF95200CAF43E7009DC96F /* O2PDFContext.m in Sources */ = {isa = PBXBuildFile; fileRef = FEDF951C0CAF43E7009DC96F /* O2PDFContext.m */; }; FEE36B800F4B20C6005AEBBF /* NSToolbarOverflowArrow.pdf in Resources */ = {isa = PBXBuildFile; fileRef = FEE36B7F0F4B20C5005AEBBF /* NSToolbarOverflowArrow.pdf */; }; @@ -4165,6 +4205,20 @@ remoteGlobalIDString = 8DC2EF4F0486A6940098B216; remoteInfo = "OpenGL-Windows-i386"; }; + FE0DDFBA12BFF7DD008EC2E6 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; + proxyType = 1; + remoteGlobalIDString = FECA819410EBB231003472F1; + remoteInfo = "QuartzCore-Windows-i386"; + }; + FE0DDFBC12BFF7F5008EC2E6 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; + proxyType = 1; + remoteGlobalIDString = 8DC2EF4F0486A6940098B216; + remoteInfo = "QuartzCore-FreeBSD-i386"; + }; FE39C6821203D5E200A80A71 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = FE39C67E1203D5E200A80A71 /* CoreData.xcodeproj */; @@ -4172,6 +4226,27 @@ remoteGlobalIDString = 8DC2EF5B0486A6940098B216; remoteInfo = "CoreData-Windows-i386"; }; + FE41B87512BEA2D900ED6C10 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = 8DC2EF5B0486A6940098B216; + remoteInfo = "QuartzCore-FreeBSD-i386"; + }; + FE41B87712BEA2D900ED6C10 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = FED38C4D10E13E1000A2A651; + remoteInfo = "QuartzCore-Darwin-i386"; + }; + FE41B87912BEA2D900ED6C10 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; + proxyType = 2; + remoteGlobalIDString = FECA81A110EBB231003472F1; + remoteInfo = "QuartzCore-Windows-i386"; + }; FE4404B6106034C700A2AEFE /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 6E46FEBE0A2D2DCF004CD27E /* Foundation.xcodeproj */; @@ -4235,20 +4310,6 @@ remoteGlobalIDString = FE01AAE20C5D9BF900AEA51A; remoteInfo = "ApplicationServices-Windows-i386"; }; - FECA81A410EBB232003472F1 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = FECA81A110EBB231003472F1; - remoteInfo = "QuartzCore-FreeBSD-i386 copy"; - }; - FECA81A810EBB286003472F1 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = FECA819410EBB231003472F1; - remoteInfo = "QuartzCore-Windows-i386"; - }; FECAF4D00DB710EE00BA2A8E /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = FECAF4C80DB710EE00BA2A8E /* ApplicationServices.xcodeproj */; @@ -4256,34 +4317,6 @@ remoteGlobalIDString = FE01AAED0C5D9BF900AEA51A; remoteInfo = "ApplicationServices-Windows-i386"; }; - FED38C3F10E13DDF00A2A651 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = 8DC2EF5B0486A6940098B216; - remoteInfo = "QuartzCore-FreeBSD-i386"; - }; - FED38C4110E13E0800A2A651 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = 8DC2EF4F0486A6940098B216; - remoteInfo = "QuartzCore-FreeBSD-i386"; - }; - FED38C5010E13E2E00A2A651 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; - proxyType = 2; - remoteGlobalIDString = FED38C4D10E13E1000A2A651; - remoteInfo = "QuartzCore-FreeBSD-i386 copy"; - }; - FED38C5510E13E5A00A2A651 /* PBXContainerItemProxy */ = { - isa = PBXContainerItemProxy; - containerPortal = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; - proxyType = 1; - remoteGlobalIDString = FED38C4310E13E1000A2A651; - remoteInfo = "QuartzCore-FreeBSD-i386 copy"; - }; FED5359B0FE061B200F02667 /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 6E46FEBE0A2D2DCF004CD27E /* Foundation.xcodeproj */; @@ -4912,6 +4945,7 @@ FE3C854E108779540018252A /* O2AffineTransform.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = O2AffineTransform.m; sourceTree = ""; }; FE3C854F108779540018252A /* O2Geometry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = O2Geometry.h; sourceTree = ""; }; FE3C8550108779540018252A /* O2Geometry.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = O2Geometry.m; sourceTree = ""; }; + FE41B85812BEA2C800ED6C10 /* CATransaction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CATransaction.m; sourceTree = ""; }; FE43BE1F11FFBAAC00119833 /* O2PDFBlock.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = O2PDFBlock.h; sourceTree = ""; }; FE43BE2011FFBAAC00119833 /* O2PDFBlock.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = O2PDFBlock.m; sourceTree = ""; }; FE4434020BB9833B00411464 /* NSGraphicsStyle_uxtheme.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = NSGraphicsStyle_uxtheme.h; sourceTree = ""; }; @@ -5083,6 +5117,8 @@ FE7247A50C0622F2007CBC51 /* NSTextAttachmentCell.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = NSTextAttachmentCell.m; sourceTree = ""; }; FE72484F0C0676AA007CBC51 /* NSTypesetter_concrete.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = NSTypesetter_concrete.h; sourceTree = ""; }; FE7248500C0676AA007CBC51 /* NSTypesetter_concrete.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = NSTypesetter_concrete.m; sourceTree = ""; }; + FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NSViewBackingLayer.h; sourceTree = ""; }; + FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NSViewBackingLayer.m; sourceTree = ""; }; FE7AA0CB10F9788100FEDD9C /* CAWindowOpenGLContext.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = CAWindowOpenGLContext.h; path = ../QuartzCore/CAWindowOpenGLContext.h; sourceTree = SOURCE_ROOT; }; FE7AA0CC10F9788100FEDD9C /* CAWindowOpenGLContext.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CAWindowOpenGLContext.m; path = ../QuartzCore/CAWindowOpenGLContext.m; sourceTree = SOURCE_ROOT; }; FE7ABEBD0DC2C9BA0060D15B /* CGPDFDocument.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CGPDFDocument.m; sourceTree = ""; }; @@ -5183,9 +5219,14 @@ FED38C3110E13DCA00A2A651 /* CALayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CALayer.m; path = ../QuartzCore/CALayer.m; sourceTree = SOURCE_ROOT; }; FED38C3210E13DCA00A2A651 /* CARenderer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CARenderer.m; path = ../QuartzCore/CARenderer.m; sourceTree = SOURCE_ROOT; }; FED38C3310E13DCA00A2A651 /* CATransform3D.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = CATransform3D.m; path = ../QuartzCore/CATransform3D.m; sourceTree = SOURCE_ROOT; }; - FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = QuartzCore.xcodeproj; path = ../QuartzCore/QuartzCore.xcodeproj; sourceTree = SOURCE_ROOT; }; + FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; path = QuartzCore.xcodeproj; sourceTree = ""; }; FED56E6411A2D87100D6D09B /* CGGradient.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CGGradient.m; sourceTree = ""; }; FEDE655E1210A294003D3EF1 /* CoreData.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreData.framework; path = Cocotron/1.0/Windows/i386/Frameworks/CoreData.framework; sourceTree = SYSTEM_DEVELOPER_DIR; }; + FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CATransactionGroup.m; sourceTree = ""; }; + FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CATransactionGroup.h; sourceTree = ""; }; + FEDEA95312C13368008E5A59 /* CABase.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CABase.m; sourceTree = ""; }; + FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CAValueFunction.m; sourceTree = ""; }; + FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CALayerContext.m; sourceTree = ""; }; FEDF951B0CAF43E7009DC96F /* O2PDFContext.h */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.h; path = O2PDFContext.h; sourceTree = ""; }; FEDF951C0CAF43E7009DC96F /* O2PDFContext.m */ = {isa = PBXFileReference; fileEncoding = 30; lastKnownFileType = sourcecode.c.objc; path = O2PDFContext.m; sourceTree = ""; }; FEE36B7F0F4B20C5005AEBBF /* NSToolbarOverflowArrow.pdf */ = {isa = PBXFileReference; lastKnownFileType = image.pdf; path = NSToolbarOverflowArrow.pdf; sourceTree = ""; }; @@ -5602,6 +5643,8 @@ FEA8A98B0CD2CBC000E1E936 /* NSUserInterfaceValidation.h */, 6E2B54BE0976075300DA0954 /* NSView.h */, 6E2B53DF0976075200DA0954 /* NSView.m */, + FE74968612BB1D4F008DBFCB /* NSViewBackingLayer.h */, + FE74968712BB1D4F008DBFCB /* NSViewBackingLayer.m */, 6E2B54DC0976075300DA0954 /* NSWindow-Drag.h */, 6E2B53F70976075200DA0954 /* NSWindow-Drag.m */, 6E2B54C20976075300DA0954 /* NSWindow-Private.h */, @@ -6211,6 +6254,16 @@ path = CoreData_; sourceTree = ""; }; + FE41B87012BEA2D900ED6C10 /* Products */ = { + isa = PBXGroup; + children = ( + FE41B87612BEA2D900ED6C10 /* QuartzCore.framework */, + FE41B87812BEA2D900ED6C10 /* QuartzCore.framework */, + FE41B87A12BEA2D900ED6C10 /* QuartzCore.framework */, + ); + name = Products; + sourceTree = ""; + }; FE44327B0BB95F4300411464 /* NSInterfacePart */ = { isa = PBXGroup; children = ( @@ -6487,7 +6540,6 @@ FEAE000911E4E43B00CA0912 /* CoreVideo */ = { isa = PBXGroup; children = ( - FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */, FEAE000B11E4E45600CA0912 /* CVDisplayLink.m */, ); name = CoreVideo; @@ -6545,6 +6597,12 @@ FED38C2610E1305700A2A651 /* QuartzCore */ = { isa = PBXGroup; children = ( + FEDEABAD12C98F4C008E5A59 /* CALayerContext.m */, + FEDEAA9812C2639B008E5A59 /* CAValueFunction.m */, + FEDEA95312C13368008E5A59 /* CABase.m */, + FEDEA8B212C112EE008E5A59 /* CATransactionGroup.h */, + FEDEA8AC12C112E5008E5A59 /* CATransactionGroup.m */, + FE41B85812BEA2C800ED6C10 /* CATransaction.m */, FE20C20711892436006F01BA /* CAAnimation.m */, FEF5A7C711E4EB0A009B0041 /* CAAnimationGroup.m */, FEF5A7C811E4EB0A009B0041 /* CABasicAnimation.m */, @@ -6557,30 +6615,21 @@ FE7AA0CB10F9788100FEDD9C /* CAWindowOpenGLContext.h */, FE7AA0CC10F9788100FEDD9C /* CAWindowOpenGLContext.m */, FE20C20811892436006F01BA /* CIAffineTransform.m */, - FE71DA7011F7403200E6F801 /* CIBloom.m */, FE71DA9111F7433000E6F801 /* CIBoxBlur.m */, + FE71DA7011F7403200E6F801 /* CIBloom.m */, FE20C20911892436006F01BA /* CIColor.m */, FE20C20A11892436006F01BA /* CIContext.m */, FE20C20B11892436006F01BA /* CIFilter.m */, FE20C20C11892436006F01BA /* CIImage.m */, FE71DA9211F7433000E6F801 /* CILinearGradient.m */, FE20C20D11892436006F01BA /* CIVector.m */, + FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */, FEAE000911E4E43B00CA0912 /* CoreVideo */, ); name = QuartzCore; path = ../QuartzCore; sourceTree = ""; }; - FED38C3C10E13DDF00A2A651 /* Products */ = { - isa = PBXGroup; - children = ( - FED38C4010E13DDF00A2A651 /* QuartzCore.framework */, - FED38C5110E13E2E00A2A651 /* QuartzCore.framework */, - FECA81A510EBB232003472F1 /* QuartzCore.framework */, - ); - name = Products; - sourceTree = ""; - }; /* End PBXGroup section */ /* Begin PBXHeadersBuildPhase section */ @@ -6981,6 +7030,8 @@ FE58788212694AD2009B9EDF /* O2argb32f.h in Headers */, FE587956126961BD009B9EDF /* O2ClipMask.h in Headers */, FE99DA76128396B6006D789F /* O2Encoder_PNG.h in Headers */, + FE74968A12BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */, + FEDEA8B412C112EE008E5A59 /* CATransactionGroup.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -7380,6 +7431,8 @@ FE58788312694AD2009B9EDF /* O2argb32f.h in Headers */, FE587958126961BD009B9EDF /* O2ClipMask.h in Headers */, FE99DA78128396B6006D789F /* O2Encoder_PNG.h in Headers */, + FE74968C12BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */, + FEDEA8B512C112EE008E5A59 /* CATransactionGroup.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -7776,6 +7829,8 @@ FE587954126961BD009B9EDF /* O2ClipMask.h in Headers */, FE99DA74128396B6006D789F /* O2Encoder_PNG.h in Headers */, FE5F4CA812A860BA00F5F334 /* O2Context_gdi+AppKit.h in Headers */, + FE74968812BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */, + FEDEA8B312C112EE008E5A59 /* CATransactionGroup.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -8177,6 +8232,8 @@ FE58788512694AD2009B9EDF /* O2argb32f.h in Headers */, FE58795C126961BD009B9EDF /* O2ClipMask.h in Headers */, FE99DA7C128396B6006D789F /* O2Encoder_PNG.h in Headers */, + FE74969012BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */, + FEDEA8B712C112EE008E5A59 /* CATransactionGroup.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -8495,6 +8552,8 @@ FE58788412694AD2009B9EDF /* O2argb32f.h in Headers */, FE58795A126961BD009B9EDF /* O2ClipMask.h in Headers */, FE99DA7A128396B6006D789F /* O2Encoder_PNG.h in Headers */, + FE74968E12BB1D4F008DBFCB /* NSViewBackingLayer.h in Headers */, + FEDEA8B612C112EE008E5A59 /* CATransactionGroup.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -8539,7 +8598,6 @@ dependencies = ( C8A2E5760F07EA440054397C /* PBXTargetDependency */, FE07750D0F2D54470074EE75 /* PBXTargetDependency */, - FED38C5610E13E5A00A2A651 /* PBXTargetDependency */, FEE7E14510E2722B004A50F8 /* PBXTargetDependency */, ); name = "AppKit-Darwin-i386"; @@ -8565,7 +8623,7 @@ FE01AACC0C5D9BE700AEA51A /* PBXTargetDependency */, FE6EDEBD0DB7AF94005503A1 /* PBXTargetDependency */, FE0C4EC51041CF3200D8C100 /* PBXTargetDependency */, - FECA81A910EBB286003472F1 /* PBXTargetDependency */, + FE0DDFBB12BFF7DD008EC2E6 /* PBXTargetDependency */, ); name = "AppKit-Windows-i386"; productInstallPath = /Library/Frameworks; @@ -8590,7 +8648,7 @@ FE5A8BE610C6F546005E348A /* PBXTargetDependency */, FE5A8BE810C6F54B005E348A /* PBXTargetDependency */, FE5A8BF610C75AC7005E348A /* PBXTargetDependency */, - FED38C4210E13E0800A2A651 /* PBXTargetDependency */, + FE0DDFBD12BFF7F5008EC2E6 /* PBXTargetDependency */, ); name = "AppKit-FreeBSD-i386"; productInstallPath = /Library/Frameworks; @@ -8654,7 +8712,7 @@ ProjectRef = FE0C4EB81041CF2100D8C100 /* OpenGL.xcodeproj */; }, { - ProductGroup = FED38C3C10E13DDF00A2A651 /* Products */; + ProductGroup = FE41B87012BEA2D900ED6C10 /* Products */; ProjectRef = FED38C3B10E13DDF00A2A651 /* QuartzCore.xcodeproj */; }, ); @@ -8726,6 +8784,27 @@ remoteRef = FE39C6821203D5E200A80A71 /* PBXContainerItemProxy */; sourceTree = BUILT_PRODUCTS_DIR; }; + FE41B87612BEA2D900ED6C10 /* QuartzCore.framework */ = { + isa = PBXReferenceProxy; + fileType = wrapper.framework; + path = QuartzCore.framework; + remoteRef = FE41B87512BEA2D900ED6C10 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; + FE41B87812BEA2D900ED6C10 /* QuartzCore.framework */ = { + isa = PBXReferenceProxy; + fileType = wrapper.framework; + path = QuartzCore.framework; + remoteRef = FE41B87712BEA2D900ED6C10 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; + FE41B87A12BEA2D900ED6C10 /* QuartzCore.framework */ = { + isa = PBXReferenceProxy; + fileType = wrapper.framework; + path = QuartzCore.framework; + remoteRef = FE41B87912BEA2D900ED6C10 /* PBXContainerItemProxy */; + sourceTree = BUILT_PRODUCTS_DIR; + }; FE4404B7106034C700A2AEFE /* Foundation.framework */ = { isa = PBXReferenceProxy; fileType = wrapper.framework; @@ -8761,13 +8840,6 @@ remoteRef = FE65206E0FBE3D3D00464BFD /* PBXContainerItemProxy */; sourceTree = BUILT_PRODUCTS_DIR; }; - FECA81A510EBB232003472F1 /* QuartzCore.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = QuartzCore.framework; - remoteRef = FECA81A410EBB232003472F1 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; FECAF4D10DB710EE00BA2A8E /* ApplicationServices.framework */ = { isa = PBXReferenceProxy; fileType = wrapper.framework; @@ -8775,20 +8847,6 @@ remoteRef = FECAF4D00DB710EE00BA2A8E /* PBXContainerItemProxy */; sourceTree = BUILT_PRODUCTS_DIR; }; - FED38C4010E13DDF00A2A651 /* QuartzCore.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = QuartzCore.framework; - remoteRef = FED38C3F10E13DDF00A2A651 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; - FED38C5110E13E2E00A2A651 /* QuartzCore.framework */ = { - isa = PBXReferenceProxy; - fileType = wrapper.framework; - path = QuartzCore.framework; - remoteRef = FED38C5010E13E2E00A2A651 /* PBXContainerItemProxy */; - sourceTree = BUILT_PRODUCTS_DIR; - }; FED5359C0FE061B200F02667 /* Foundation.framework */ = { isa = PBXReferenceProxy; fileType = wrapper.framework; @@ -9570,6 +9628,12 @@ FE58791612695E21009B9EDF /* O2argb32f.m in Sources */, FE587957126961BD009B9EDF /* O2ClipMask.m in Sources */, FE99DA77128396B6006D789F /* O2Encoder_PNG.m in Sources */, + FE74968B12BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */, + FE41B85A12BEA2C800ED6C10 /* CATransaction.m in Sources */, + FEDEA8AE12C112E5008E5A59 /* CATransactionGroup.m in Sources */, + FEDEA95512C13368008E5A59 /* CABase.m in Sources */, + FEDEAA9A12C2639B008E5A59 /* CAValueFunction.m in Sources */, + FEDEABAF12C98F4C008E5A59 /* CALayerContext.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -9962,6 +10026,12 @@ FE58791712695E21009B9EDF /* O2argb32f.m in Sources */, FE587959126961BD009B9EDF /* O2ClipMask.m in Sources */, FE99DA79128396B6006D789F /* O2Encoder_PNG.m in Sources */, + FE74968D12BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */, + FE41B85B12BEA2C800ED6C10 /* CATransaction.m in Sources */, + FEDEA8AF12C112E5008E5A59 /* CATransactionGroup.m in Sources */, + FEDEA95612C13368008E5A59 /* CABase.m in Sources */, + FEDEAA9B12C2639B008E5A59 /* CAValueFunction.m in Sources */, + FEDEABB012C98F4C008E5A59 /* CALayerContext.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -10385,6 +10455,12 @@ FE587955126961BD009B9EDF /* O2ClipMask.m in Sources */, FE99DA75128396B6006D789F /* O2Encoder_PNG.m in Sources */, FE5F4CA912A860BA00F5F334 /* O2Context_gdi+AppKit.m in Sources */, + FE74968912BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */, + FE41B85912BEA2C800ED6C10 /* CATransaction.m in Sources */, + FEDEA8AD12C112E5008E5A59 /* CATransactionGroup.m in Sources */, + FEDEA95412C13368008E5A59 /* CABase.m in Sources */, + FEDEAA9912C2639B008E5A59 /* CAValueFunction.m in Sources */, + FEDEABAE12C98F4C008E5A59 /* CALayerContext.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -10779,6 +10855,12 @@ FE58791912695E21009B9EDF /* O2argb32f.m in Sources */, FE58795D126961BD009B9EDF /* O2ClipMask.m in Sources */, FE99DA7D128396B6006D789F /* O2Encoder_PNG.m in Sources */, + FE74969112BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */, + FE41B85D12BEA2C800ED6C10 /* CATransaction.m in Sources */, + FEDEA8B112C112E5008E5A59 /* CATransactionGroup.m in Sources */, + FEDEA95812C13368008E5A59 /* CABase.m in Sources */, + FEDEAA9D12C2639B008E5A59 /* CAValueFunction.m in Sources */, + FEDEABB212C98F4C008E5A59 /* CALayerContext.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -11068,6 +11150,12 @@ FE58791812695E21009B9EDF /* O2argb32f.m in Sources */, FE58795B126961BD009B9EDF /* O2ClipMask.m in Sources */, FE99DA7B128396B6006D789F /* O2Encoder_PNG.m in Sources */, + FE74968F12BB1D4F008DBFCB /* NSViewBackingLayer.m in Sources */, + FE41B85C12BEA2C800ED6C10 /* CATransaction.m in Sources */, + FEDEA8B012C112E5008E5A59 /* CATransactionGroup.m in Sources */, + FEDEA95712C13368008E5A59 /* CABase.m in Sources */, + FEDEAA9C12C2639B008E5A59 /* CAValueFunction.m in Sources */, + FEDEABB112C98F4C008E5A59 /* CALayerContext.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -11104,6 +11192,16 @@ name = "OpenGL-Windows-i386"; targetProxy = FE0C4EC41041CF3200D8C100 /* PBXContainerItemProxy */; }; + FE0DDFBB12BFF7DD008EC2E6 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + name = "QuartzCore-Windows-i386"; + targetProxy = FE0DDFBA12BFF7DD008EC2E6 /* PBXContainerItemProxy */; + }; + FE0DDFBD12BFF7F5008EC2E6 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + name = "QuartzCore-FreeBSD-i386"; + targetProxy = FE0DDFBC12BFF7F5008EC2E6 /* PBXContainerItemProxy */; + }; FE5A8BE610C6F546005E348A /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "Foundation-FreeBSD-i386"; @@ -11124,21 +11222,6 @@ name = "ApplicationServices-Windows-i386"; targetProxy = FE6EDEBC0DB7AF94005503A1 /* PBXContainerItemProxy */; }; - FECA81A910EBB286003472F1 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = "QuartzCore-Windows-i386"; - targetProxy = FECA81A810EBB286003472F1 /* PBXContainerItemProxy */; - }; - FED38C4210E13E0800A2A651 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = "QuartzCore-FreeBSD-i386"; - targetProxy = FED38C4110E13E0800A2A651 /* PBXContainerItemProxy */; - }; - FED38C5610E13E5A00A2A651 /* PBXTargetDependency */ = { - isa = PBXTargetDependency; - name = "QuartzCore-FreeBSD-i386 copy"; - targetProxy = FED38C5510E13E5A00A2A651 /* PBXContainerItemProxy */; - }; FEE7E14510E2722B004A50F8 /* PBXTargetDependency */ = { isa = PBXTargetDependency; name = "OpenGL-Darwin-i386"; diff --git a/AppKit/NSView.h b/AppKit/NSView.h index a28b1821..fe769987 100755 --- a/AppKit/NSView.h +++ b/AppKit/NSView.h @@ -15,7 +15,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #import #import -@class NSWindow, NSMenu, NSMenuItem, NSCursor, NSClipView, NSPasteboard, NSTextInputContext, NSImage, NSBitmapImageRep, NSScrollView, NSTrackingArea, NSShadow, NSScreen, CALayer, CIFilter, CGLPixelSurface; +@class NSWindow, NSMenu, NSMenuItem, NSCursor, NSClipView, NSPasteboard, NSTextInputContext, NSImage, NSBitmapImageRep, NSScrollView, NSTrackingArea, NSShadow, NSScreen, CALayer, CIFilter, CGLPixelSurface,CALayerContext; // See Cocoa Event Handling Guide : Using Tracking-Area Objects : Compatibility Issues typedef NSTrackingArea *NSTrackingRectTag; @@ -87,20 +87,27 @@ APPKIT_EXPORT NSString * const NSViewFocusDidChangeNotification; BOOL _needsDisplay; NSUInteger _invalidRectCount; NSRect *_invalidRects; + CGFloat _frameRotation; + CGFloat _boundsRotation; BOOL _validTrackingAreas; BOOL _validTransforms; CGAffineTransform _transformFromWindow; CGAffineTransform _transformToWindow; + CGAffineTransform _transformToLayer; NSRect _visibleRect; NSFocusRingType _focusRingType; BOOL _wantsLayer; - CALayer *_backingLayer; CALayer *_layer; NSArray *_contentFilters; + CIFilter *_compositingFilter; + NSViewLayerContentsPlacement _layerContentsPlacement; + NSViewLayerContentsRedrawPolicy _layerContentsRedrawPolicy; + NSShadow *_shadow; NSDictionary *_animations; + CALayerContext *_layerContext; CGLPixelSurface *_overlay; } diff --git a/AppKit/NSView.m b/AppKit/NSView.m index d8502306..724faf44 100755 --- a/AppKit/NSView.m +++ b/AppKit/NSView.m @@ -29,7 +29,10 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #import #import #import +#import #import +#import +#import NSString * const NSViewFrameDidChangeNotification=@"NSViewFrameDidChangeNotification"; NSString * const NSViewBoundsDidChangeNotification=@"NSViewBoundsDidChangeNotification"; @@ -38,11 +41,18 @@ NSString * const NSViewFocusDidChangeNotification=@"NSViewFocusDidChangeNotifica @interface NSView(NSView_forward) -(CGAffineTransform)transformFromWindow; -(CGAffineTransform)transformToWindow; +-(CGAffineTransform)transformToLayer; -(void)_trackingAreasChanged; @end @implementation NSView +static BOOL NSViewLayersEnabled=NO; + ++(void)initialize { + NSViewLayersEnabled=[[NSUserDefaults standardUserDefaults] boolForKey:@"NSViewLayersEnabled"]; +} + +(NSView *)focusView { return [NSCurrentFocusStack() lastObject]; } @@ -89,13 +99,18 @@ NSString * const NSViewFocusDidChangeNotification=@"NSViewFocusDidChangeNotifica _tag=-1; if([keyed containsValueForKey:@"NSTag"]) _tag=[keyed decodeIntForKey:@"NSTag"]; + [_subviews addObjectsFromArray:[keyed decodeObjectForKey:@"NSSubviews"]]; [_subviews makeObjectsPerformSelector:@selector(_setSuperview:) withObject:self]; + _needsDisplay=YES; _invalidRectCount=0; _invalidRects=NULL; _trackingAreas=[[NSMutableArray alloc] init]; - _wantsLayer=[keyed decodeBoolForKey:@"NSViewIsLayerTreeHost"]; + [self setWantsLayer:[keyed decodeBoolForKey:@"NSViewIsLayerTreeHost"]]; + + _layerContentsRedrawPolicy=[keyed decodeIntegerForKey:@"NSViewLayerContentsRedrawPolicy"]; + _contentFilters=[[keyed decodeObjectForKey:@"NSViewContentFilters"] retain]; } else { @@ -130,6 +145,7 @@ NSString * const NSViewFocusDidChangeNotification=@"NSViewFocusDidChangeNotifica _validTransforms=NO; _transformFromWindow=CGAffineTransformIdentity; _transformToWindow=CGAffineTransformIdentity; + _transformToLayer=CGAffineTransformIdentity; return self; } @@ -150,6 +166,10 @@ NSString * const NSViewFocusDidChangeNotification=@"NSViewFocusDidChangeNotifica if(_invalidRects!=NULL) NSZoneFree(NULL,_invalidRects); + [_layer release]; + + [_layerContext invalidate]; + [_layerContext release]; [_overlay release]; [super dealloc]; @@ -161,6 +181,7 @@ static void invalidateTransform(NSView *self){ for(NSView *check in self->_subviews) invalidateTransform(check); + } static CGAffineTransform concatViewTransform(CGAffineTransform result,NSView *view,NSView *superview,BOOL doFrame,BOOL flip){ @@ -200,6 +221,20 @@ static CGAffineTransform concatViewTransform(CGAffineTransform result,NSView *vi return result; } +-(CGAffineTransform)createTransformToLayer { + CGAffineTransform result=CGAffineTransformIdentity; + NSRect bounds=[self bounds]; + + if([self isFlipped]){ + CGAffineTransform flip=CGAffineTransformMake(1,0,0,-1,0,bounds.size.height); + + result=CGAffineTransformConcat(flip,result); + } + result=CGAffineTransformTranslate(result,-bounds.origin.x,-bounds.origin.y); + + return result; +} + -(NSRect)calculateVisibleRect { if([self isHiddenOrHasHiddenAncestor]) return NSZeroRect; @@ -217,13 +252,36 @@ static CGAffineTransform concatViewTransform(CGAffineTransform result,NSView *vi } } +static inline void configureLayerGeometry(NSView *self){ + CALayer *layer=self->_layer; + + if(layer==nil) + return; + + [CATransaction begin]; + [CATransaction setDisableActions:YES]; + + NSLog(@"disable=%d",[CATransaction disableActions]); + [layer setAnchorPoint:CGPointMake(0,0)]; + + if([layer superlayer]==nil) + [layer setPosition:CGPointMake(0,0)]; + else + [layer setPosition:self->_frame.origin]; + + [layer setBounds:self->_bounds]; + [CATransaction commit]; +} + static inline void buildTransformsIfNeeded(NSView *self) { if(!self->_validTransforms){ self->_transformToWindow=[self createTransformToWindow]; self->_transformFromWindow=CGAffineTransformInvert(self->_transformToWindow); + self->_transformToLayer=[self createTransformToLayer]; self->_validTransforms=YES; self->_visibleRect=[self calculateVisibleRect]; + configureLayerGeometry(self); } } @@ -240,13 +298,18 @@ static inline void buildTransformsIfNeeded(NSView *self) { } +-(CGAffineTransform)transformToLayer { + buildTransformsIfNeeded(self); + + return _transformToLayer; +} + -(NSRect)frame { return _frame; } -(CGFloat)frameRotation { - NSUnimplementedMethod(); - return 0.; + return _frameRotation; } -(CGFloat)frameCenterRotation { @@ -259,8 +322,7 @@ static inline void buildTransformsIfNeeded(NSView *self) { } -(CGFloat)boundsRotation { - NSUnimplementedMethod(); - return 0.; + return _boundsRotation; } -(BOOL)isRotatedFromBase { @@ -278,7 +340,7 @@ static inline void buildTransformsIfNeeded(NSView *self) { } -(void)rotateByAngle:(CGFloat)angle { - NSUnimplementedMethod(); + [self setBoundsRotation:[self boundsRotation]+angle]; } -(BOOL)postsFrameChangedNotifications { @@ -635,7 +697,6 @@ static inline void buildTransformsIfNeeded(NSView *self) { return NSMakeRect(minx,miny,maxx-minx,maxy-miny); } - -(void)setFrame:(NSRect)frame { // Cocoa does not post the notification if the frames are equal // Possible that resizeSubviewsWithOldSize is not called if the sizes are equal @@ -720,6 +781,24 @@ static inline void buildTransformsIfNeeded(NSView *self) { _postsNotificationOnBoundsChange=flag; } +-(void)_setOverlay:(CGLPixelSurface *)overlay { + if(overlay!=_overlay){ + [[[self window] platformWindow] removeOverlay:_overlay]; + + overlay=[overlay retain]; + [_overlay release]; + _overlay=overlay; + + if(_superview==nil) + [_overlay setFrame:[self frame]]; + else + [_overlay setFrame:[_superview convertRect:[self frame] toView:nil]]; + + if(_overlay!=nil) + [[[self window] platformWindow] addOverlay:_overlay]; + } +} + -(void)_setWindow:(NSWindow *)window { [self viewWillMoveToWindow:window]; @@ -766,6 +845,9 @@ static inline void buildTransformsIfNeeded(NSView *self) { invalidateTransform(view); [self setNeedsDisplayInRect:[view frame]]; + + if(_wantsLayer) + [view setWantsLayer:YES]; } -(void)addSubview:(NSView *)view { @@ -1334,37 +1416,127 @@ static inline void buildTransformsIfNeeded(NSView *self) { } -(CALayer *)makeBackingLayer { - NSUnimplementedMethod(); - return nil; + return [NSViewBackingLayer layer]; } --(void)setWantsLayer:(BOOL)value { - _wantsLayer=value; +-(void)_removeLayerFromSuperlayer { + [_layer removeFromSuperlayer]; + [self _setOverlay:nil]; + [_layerContext invalidate]; + [_layerContext release]; + _layerContext=nil; +} + +-(void)_createLayerContextIfNeeded { + if([_superview layer]==nil){ + _layerContext=[[CALayerContext alloc] initWithFrame:[self frame]]; + [_layerContext setLayer:_layer]; + [self _setOverlay:[_layerContext pixelSurface]]; + } +} + +-(void)_addLayerToSuperlayer { + [[_superview layer] addSublayer:_layer]; + [self _createLayerContextIfNeeded]; +} + +/* + When turning off layering, we only turn off layers below us which did not want a layer + Layers which did want a layer are not touched, nor are their children. + */ +-(void)_removeLayerBackedViewsFromTree { + if(_wantsLayer) + [self _createLayerContextIfNeeded]; + else { + [self _removeLayerFromSuperlayer]; + +// A backing layer is removed regardless of whether it was set implicitly or explicitly +// The distinction appears to be based on the layers class, not how it was set (host vs. backing) + if([_layer isKindOfClass:[NSViewBackingLayer class]]){ + [_layer release]; + _layer=nil; + } + + [_subviews makeObjectsPerformSelector:_cmd]; + } +} + +-(void)_createLayersInTreeIfNeeded { + if(!NSViewLayersEnabled) + return; + + if(_layer==nil){ + _layer=[[self makeBackingLayer] retain]; + configureLayerGeometry(self); + } + + [self _addLayerToSuperlayer]; + + [_subviews makeObjectsPerformSelector:_cmd]; +} + +-(void)setWantsLayer:(BOOL)value { + if(!value){ + if(_wantsLayer){ + _wantsLayer=NO; + [self _removeLayerBackedViewsFromTree]; + } + } + else { + if(!_wantsLayer){ + _wantsLayer=YES; + [self _createLayersInTreeIfNeeded]; + } + } } -(void)setLayer:(CALayer *)value { - NSUnimplementedMethod(); -} + if(!NSViewLayersEnabled) + return; + if(value!=_layer){ + [_subviews makeObjectsPerformSelector:@selector(_removeLayerFromSuperlayer)]; + + value=[value retain]; + + if(_layer==nil){ + if(value!=nil){ + _layer=value; + [self _addLayerToSuperlayer]; + } + } + else if(value==nil){ + [self _removeLayerFromSuperlayer]; + [_layer release]; + _layer=nil; + } + else { + [[_superview layer] replaceSublayer:_layer with:value]; + [_layer release]; + _layer=value; + } + + [_subviews makeObjectsPerformSelector:@selector(_addLayerToSuperlayer)]; + } +} -(NSViewLayerContentsPlacement)layerContentsPlacement { - NSUnimplementedMethod(); - return nil; + return _layerContentsPlacement; } --(void)setLayerContentsPlacement:(NSViewLayerContentsPlacement)newPlacement { - NSUnimplementedMethod(); +-(void)setLayerContentsPlacement:(NSViewLayerContentsPlacement)value { + _layerContentsPlacement=value; } -(NSViewLayerContentsRedrawPolicy)layerContentsRedrawPolicy { - NSUnimplementedMethod(); - return nil; + return _layerContentsRedrawPolicy; } --(void)setLayerContentsRedrawPolicy:(NSViewLayerContentsRedrawPolicy)newPolicy { - NSUnimplementedMethod(); +-(void)setLayerContentsRedrawPolicy:(NSViewLayerContentsRedrawPolicy)value { + _layerContentsRedrawPolicy=value; } + -(NSArray *)backgroundFilters { NSUnimplementedMethod(); return nil; @@ -1376,30 +1548,33 @@ static inline void buildTransformsIfNeeded(NSView *self) { } -(NSArray *)contentFilters { - NSUnimplementedMethod(); - return nil; + return _contentFilters; } -(void)setContentFilters:(NSArray *)filters { - NSUnimplementedMethod(); + filters=[filters copy]; + [_contentFilters release]; + _contentFilters=filters; } -(CIFilter *)compositingFilter { - NSUnimplementedMethod(); - return nil; + return _compositingFilter; } -(void)setCompositingFilter:(CIFilter *)filter { - NSUnimplementedMethod(); + filter=[filter copy]; + [_compositingFilter release]; + _compositingFilter=filter; } -(NSShadow *)shadow { - NSUnimplementedMethod(); - return nil; + return _shadow; } -(void)setShadow:(NSShadow *)shadow { - NSUnimplementedMethod(); + shadow=[shadow copy]; + [_shadow release]; + _shadow=shadow; } -(BOOL)needsDisplay { @@ -1508,7 +1683,7 @@ static void clearNeedsDisplay(NSView *self){ } -(void)viewWillDraw { - NSUnimplementedMethod(); + [[self subviews] makeObjectsPerformSelector:_cmd]; } -(void)setCanDrawConcurrently:(BOOL)canDraw { @@ -1516,6 +1691,20 @@ static void clearNeedsDisplay(NSView *self){ } static NSGraphicsContext *graphicsContextForView(NSView *view){ + if(view->_layer!=nil){ + NSRect frame=[view frame]; + size_t width=frame.size.width; + size_t height=frame.size.height; + CGColorSpaceRef colorSpace=CGColorSpaceCreateDeviceRGB(); + CGContextRef context=CGBitmapContextCreate(NULL,width,height,8,0,colorSpace,kCGImageAlphaPremultipliedFirst|kCGBitmapByteOrder32Host); + NSGraphicsContext *result=[NSGraphicsContext graphicsContextWithGraphicsPort:context flipped:NO]; + + CGColorSpaceRelease(colorSpace); + CGContextRelease(context); + + return result; + } + return [[view window] graphicsContext]; } @@ -1529,7 +1718,12 @@ static NSGraphicsContext *graphicsContextForView(NSView *view){ CGContextSaveGState(graphicsPort); CGContextResetClip(graphicsPort); - CGContextSetCTM(graphicsPort,[self transformToWindow]); + + if(_layer!=nil) + CGContextSetCTM(graphicsPort,[self transformToLayer]); + else + CGContextSetCTM(graphicsPort,[self transformToWindow]); + CGContextClipToRect(graphicsPort,[self visibleRect]); [self setUpGState]; @@ -1555,13 +1749,41 @@ static NSGraphicsContext *graphicsContextForView(NSView *view){ return NO; } --(void)unlockFocus { - NSGraphicsContext *context=[NSGraphicsContext currentContext]; - - CGContextRestoreGState([context graphicsPort]); +-(void)_renderLayerInWindow { + if(_layer!=nil){ + NSGraphicsContext *windowContext=[[self window] graphicsContext]; + CGContextRef windowPort=[windowContext graphicsPort]; + + [NSGraphicsContext saveGraphicsState]; + [NSGraphicsContext setCurrentContext:windowContext]; + + CGContextSaveGState(windowPort); + CGContextSetCTM(windowPort,[_superview transformToWindow]); + + CGContextDrawImage(windowPort,[self frame],[_layer contents]); + CGContextRestoreGState(windowPort); + + [NSGraphicsContext restoreGraphicsState]; + NSLog(@"rendered layer"); + } +} - [[context focusStack] removeLastObject]; +-(void)unlockFocus { + NSGraphicsContext *graphicsContext=[NSGraphicsContext currentContext]; + CGContextRef context=[graphicsContext graphicsPort]; + + if(_layer!=nil){ + CGImageRef image=CGBitmapContextCreateImage(context); + + [_layer setContents:image]; + } + + CGContextRestoreGState(context); + + [[graphicsContext focusStack] removeLastObject]; [NSGraphicsContext restoreGraphicsState]; + + // [self _renderLayerInWindow]; } -(BOOL)needsToDrawRect:(NSRect)rect { @@ -1694,6 +1916,8 @@ static NSGraphicsContext *graphicsContextForView(NSView *view){ } } + [_layerContext render]; + /* We do the flushWindow here. If any of the display* methods are being used, you want it to update on screen immediately. If the view hierarchy is being displayed as needed at the end of an event, flushing will be disabled and this will just mark the window as needing flushing which will happen when all the views have finished being displayed */ [[self window] flushWindow]; @@ -2012,23 +2236,5 @@ static NSGraphicsContext *graphicsContextForView(NSView *view){ return [NSString stringWithFormat:@"<%@[0x%lx] frame: %@>", [self class], self, NSStringFromRect(_frame)]; } --(void)_setOverlay:(CGLPixelSurface *)overlay { - if(overlay!=_overlay){ - [[[self window] platformWindow] removeOverlay:_overlay]; - - - overlay=[overlay retain]; - [_overlay release]; - _overlay=overlay; - - if(_superview==nil) - [_overlay setFrame:[self frame]]; - else - [_overlay setFrame:[_superview convertRect:[self frame] toView:nil]]; - - [[[self window] platformWindow] addOverlay:_overlay]; - } -} - @end diff --git a/AppKit/NSViewBackingLayer.h b/AppKit/NSViewBackingLayer.h new file mode 100644 index 00000000..d6f97b9d --- /dev/null +++ b/AppKit/NSViewBackingLayer.h @@ -0,0 +1,5 @@ +#import + +@interface NSViewBackingLayer : CALayer + +@end diff --git a/AppKit/NSViewBackingLayer.m b/AppKit/NSViewBackingLayer.m new file mode 100644 index 00000000..359440f2 --- /dev/null +++ b/AppKit/NSViewBackingLayer.m @@ -0,0 +1,5 @@ +#import + +@implementation NSViewBackingLayer + +@end diff --git a/AppKit/NSWindow-Private.h b/AppKit/NSWindow-Private.h index 042c8d39..609238c5 100755 --- a/AppKit/NSWindow-Private.h +++ b/AppKit/NSWindow-Private.h @@ -37,4 +37,5 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI -(void)undo:sender; -(void)redo:sender; -(BOOL)validateMenuItem:(NSMenuItem *)item; + @end diff --git a/AppKit/NSWindow.h b/AppKit/NSWindow.h index f8d2bb33..bc0006c1 100755 --- a/AppKit/NSWindow.h +++ b/AppKit/NSWindow.h @@ -14,7 +14,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI #import #import -@class NSView, NSEvent, NSColor, NSColorSpace, NSCursor, NSImage, NSScreen, NSText, NSTextView, CGWindow, NSPasteboard, NSSheetContext, NSUndoManager, NSButton, NSButtonCell, NSDrawer, NSDockTile, NSToolbar, NSWindowAnimationContext, NSTrackingArea, NSThemeFrame, NSWindowController, NSMenuItem; +@class NSView, NSEvent, NSColor, NSColorSpace, NSCursor, NSImage, NSScreen, NSText, NSTextView, CGWindow, NSPasteboard, NSSheetContext, NSUndoManager, NSButton, NSButtonCell, NSDrawer, NSDockTile, NSToolbar, NSWindowAnimationContext, NSTrackingArea, NSThemeFrame, NSWindowController, NSMenuItem,CARenderer; enum { NSBorderlessWindowMask=0x00, diff --git a/AppKit/Win32.subproj/CGLContext.m b/AppKit/Win32.subproj/CGLContext.m index d60aac64..d9f91b6b 100644 --- a/AppKit/Win32.subproj/CGLContext.m +++ b/AppKit/Win32.subproj/CGLContext.m @@ -341,9 +341,9 @@ CGLError CGLFlushDrawable(CGLContextObj context) { If we SwapBuffers() and read from the front buffer we get junk because the swapbuffers may not be complete. Read from GL_BACK. */ - CGLSetCurrentContext(context); + CGLSetCurrentContext(context); - [context->overlay flushBuffer]; + [context->overlay flushBuffer]; return kCGLNoError; } diff --git a/AppKit/Win32.subproj/Win32Window.m b/AppKit/Win32.subproj/Win32Window.m index 3f14632a..9b44b6fb 100755 --- a/AppKit/Win32.subproj/Win32Window.m +++ b/AppKit/Win32.subproj/Win32Window.m @@ -577,7 +577,7 @@ i=count; for(CGLPixelSurface *overlay in _overlays){ if([overlay isOpaque]) continue; - + O2Rect overFrame=[overlay frame]; O2Surface_DIBSection *overSurface=[overlay validSurface]; diff --git a/AppKit/nib.subproj/NSCustomView.m b/AppKit/nib.subproj/NSCustomView.m index 28de58eb..c7585e08 100644 --- a/AppKit/nib.subproj/NSCustomView.m +++ b/AppKit/nib.subproj/NSCustomView.m @@ -20,16 +20,15 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI return self; } else { - NSKeyedUnarchiver *keyed=(NSKeyedUnarchiver *)coder; NSRect frame=NSZeroRect; - if([keyed containsValueForKey:@"NSFrame"]) - frame=[keyed decodeRectForKey:@"NSFrame"]; - else if([keyed containsValueForKey:@"NSFrameSize"]) - frame.size=[keyed decodeSizeForKey:@"NSFrameSize"]; + if([coder containsValueForKey:@"NSFrame"]) + frame=[coder decodeRectForKey:@"NSFrame"]; + else if([coder containsValueForKey:@"NSFrameSize"]) + frame.size=[coder decodeSizeForKey:@"NSFrameSize"]; NSView *newView=[[class alloc] initWithFrame:frame]; - if([keyed containsValueForKey:@"NSvFlags"]){ - unsigned vFlags=[keyed decodeIntForKey:@"NSvFlags"]; + if([coder containsValueForKey:@"NSvFlags"]){ + unsigned vFlags=[coder decodeIntForKey:@"NSvFlags"]; newView->_autoresizingMask=vFlags&0x3F; newView->_autoresizesSubviews=(vFlags&0x100)?YES:NO; @@ -38,11 +37,14 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI // Despite the fact it appears _autoresizesSubviews is encoded in the flags, it should always be on newView->_autoresizesSubviews=YES; - if([keyed containsValueForKey:@"NSTag"]) - newView->_tag=[keyed decodeIntForKey:@"NSTag"]; - [newView->_subviews addObjectsFromArray:[keyed decodeObjectForKey:@"NSSubviews"]]; + if([coder containsValueForKey:@"NSTag"]) + newView->_tag=[coder decodeIntForKey:@"NSTag"]; + [newView->_subviews addObjectsFromArray:[coder decodeObjectForKey:@"NSSubviews"]]; [newView->_subviews makeObjectsPerformSelector:@selector(_setSuperview:) withObject:newView]; [_subviews removeAllObjects]; + + [newView setWantsLayer:[coder decodeBoolForKey:@"NSViewIsLayerTreeHost"]]; + [newView setLayerContentsRedrawPolicy:[coder decodeIntegerForKey:@"NSViewLayerContentsRedrawPolicy"]]; [self release]; return newView; } diff --git a/CoreFoundation/CFBase.h b/CoreFoundation/CFBase.h index d3fee6a8..d7f0a2b1 100644 --- a/CoreFoundation/CFBase.h +++ b/CoreFoundation/CFBase.h @@ -82,12 +82,6 @@ typedef struct CGRect { } CGRect; -// FIXME: -#ifndef _MACH_PORT_T -#define _MACH_PORT_T -typedef int mach_port_t; -#endif - typedef unsigned short UniChar; typedef unsigned long UTF32Char; typedef float Float32; @@ -205,6 +199,32 @@ COREFOUNDATION_EXPORT CFStringRef CFCopyTypeIDDescription(CFTypeID typeID); COREFOUNDATION_EXPORT CFStringRef CFCopyDescription(CFTypeRef self); COREFOUNDATION_EXPORT CFTypeRef CFMakeCollectable(CFTypeRef self); +#ifndef MACH + +// mach/mach_types.h + +typedef int kern_return_t; + +#define KERN_SUCCESS 0 +#define KERN_FAILURE 5 + +#ifndef _MACH_PORT_T +#define _MACH_PORT_T +typedef int mach_port_t; +#endif + + +// mach/mach_time.h + +typedef struct mach_timebase_info { + uint32_t numer; + uint32_t denom; +} mach_timebase_info_data_t,*mach_timebase_info_t; + +uint64_t mach_absolute_time(void); +kern_return_t mach_timebase_info(mach_timebase_info_t timebase); +#endif + #ifdef WINDOWS COREFOUNDATION_EXPORT unsigned int sleep(unsigned int seconds); COREFOUNDATION_EXPORT size_t strlcpy(char *dst, const char *src, size_t size); diff --git a/CoreFoundation/CFBase.m b/CoreFoundation/CFBase.m index 2b9c7483..57b34d56 100644 --- a/CoreFoundation/CFBase.m +++ b/CoreFoundation/CFBase.m @@ -6,6 +6,7 @@ #ifdef WINDOWS #import #endif +#import const CFAllocatorRef kCFAllocatorDefault; const CFAllocatorRef kCFAllocatorSystemDefault; @@ -94,6 +95,43 @@ CFTypeRef CFMakeCollectable(CFTypeRef self){ return 0; } +#ifndef MACH + +uint64_t mach_absolute_time(void) { +#ifdef WINDOWS + LARGE_INTEGER value={{0}}; + +// QueryPerformanceCounter() may jump ahead by seconds on old systems +// http://support.microsoft.com/default.aspx?scid=KB;EN-US;Q274323& + + if(!QueryPerformanceCounter(&value)) + return 0; + + return value.QuadPart; +#else + return 0; +#endif +} + +kern_return_t mach_timebase_info(mach_timebase_info_t timebase) { +#ifdef WINDOWS + LARGE_INTEGER value={{0}}; + + if(QueryPerformanceFrequency(&value)){ + timebase->numer=1000000000; + timebase->denom=value.QuadPart; + return KERN_SUCCESS; + } +#endif + + timebase->numer=1; + timebase->denom=1; + return KERN_FAILURE; +} + +#endif + + #ifdef WINDOWS unsigned int sleep(unsigned int seconds) { NSUnimplementedFunction(); diff --git a/CoreGraphics/CGImage.h b/CoreGraphics/CGImage.h index b9b4e87a..f5942a26 100755 --- a/CoreGraphics/CGImage.h +++ b/CoreGraphics/CGImage.h @@ -21,6 +21,7 @@ typedef enum { kCGImageAlphaFirst, kCGImageAlphaNoneSkipLast, kCGImageAlphaNoneSkipFirst, + kCGImageAlphaOnly, } CGImageAlphaInfo; enum { diff --git a/CoreGraphics/CGLPixelSurface.m b/CoreGraphics/CGLPixelSurface.m index bfb5cba9..a7116013 100644 --- a/CoreGraphics/CGLPixelSurface.m +++ b/CoreGraphics/CGLPixelSurface.m @@ -92,7 +92,7 @@ _bufferObjects[i]=0; _readPixels[i]=NULL; _staticPixels[i]=NULL; -} + } // CGLGenBuffers(_numberOfBuffers,_bufferObjects); diff --git a/CoreVideo/CVDisplayLink.m b/CoreVideo/CVDisplayLink.m index cb23b506..d802d8c4 100644 --- a/CoreVideo/CVDisplayLink.m +++ b/CoreVideo/CVDisplayLink.m @@ -1,6 +1,8 @@ #import #import +// FIXME: use only one timer for all the display links, this will reduce run loop overhead + @interface CVDisplayLink : NSObject { NSTimer *_timer; CVDisplayLinkOutputCallback _callback; diff --git a/CoreVideo/CoreVideo.xcodeproj/project.pbxproj b/CoreVideo/CoreVideo.xcodeproj/project.pbxproj index 61098cb3..f0f8568f 100644 --- a/CoreVideo/CoreVideo.xcodeproj/project.pbxproj +++ b/CoreVideo/CoreVideo.xcodeproj/project.pbxproj @@ -32,70 +32,70 @@ isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = FE01A7EC0C5D9B6900AEA51A /* Foundation.framework */; + remoteGlobalIDString = FE01A7EC0C5D9B6900AEA51A; remoteInfo = "Foundation-Windows-i386"; }; 50ACFD4C1275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = 6EA04A7709E57D5F0067589C /* Foundation.framework */; + remoteGlobalIDString = 6EA04A7709E57D5F0067589C; remoteInfo = "Foundation-Linux-i386"; }; 50ACFD4E1275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = 6E4D932B0A2642BD003D335C /* Foundation.framework */; + remoteGlobalIDString = 6E4D932B0A2642BD003D335C; remoteInfo = "Foundation-Solaris-sparc"; }; 50ACFD501275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = FED70A6B0C3B3D2C000CBE5B /* Foundation.framework */; + remoteGlobalIDString = FED70A6B0C3B3D2C000CBE5B; remoteInfo = "Foundation-Darwin-i386"; }; 50ACFD521275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = FED70FB70C3C09C7000CBE5B /* Foundation.framework */; + remoteGlobalIDString = FED70FB70C3C09C7000CBE5B; remoteInfo = "Foundation-Darwin-ppc"; }; 50ACFD541275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = FE651A870FBC844C00464BFD /* Foundation.framework */; + remoteGlobalIDString = FE651A870FBC844C00464BFD; remoteInfo = "Foundation-Darwin-x86_64"; }; 50ACFD561275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = 28D487A90FE04E7100DC03EF /* Foundation.framework */; + remoteGlobalIDString = 28D487A90FE04E7100DC03EF; remoteInfo = "Foundation-Linux-ppc"; }; 50ACFD581275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = 15D921C0105E918000171406 /* Foundation.framework */; + remoteGlobalIDString = 15D921C0105E918000171406; remoteInfo = "Foundation-Linux-arm"; }; 50ACFD5A1275F6F3008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 2; - remoteGlobalIDString = FE30A2FF10C6ED6F00A1BF7F /* Foundation.framework */; + remoteGlobalIDString = FE30A2FF10C6ED6F00A1BF7F; remoteInfo = "Foundation-FreeBSD-i386"; }; 50ACFD5C1275F6F8008BEDDD /* PBXContainerItemProxy */ = { isa = PBXContainerItemProxy; containerPortal = 50ACFD3D1275F6F3008BEDDD /* Foundation.xcodeproj */; proxyType = 1; - remoteGlobalIDString = FE01A5970C5D9B6900AEA51A /* Foundation-Windows-i386 */; + remoteGlobalIDString = FE01A5970C5D9B6900AEA51A; remoteInfo = "Foundation-Windows-i386"; }; /* End PBXContainerItemProxy section */ diff --git a/IOKit/IOTypes.h b/IOKit/IOTypes.h index a4cfee2a..af8a0f95 100644 --- a/IOKit/IOTypes.h +++ b/IOKit/IOTypes.h @@ -1,10 +1,5 @@ #import -typedef int kern_return_t; -#define KERN_SUCCESS 0 -#define KERN_FAILURE 5 - - #ifdef __cplusplus #if defined(__WIN32__) diff --git a/Onyx2D/O2BitmapContext.m b/Onyx2D/O2BitmapContext.m index 23f8d1e7..117d9f1d 100644 --- a/Onyx2D/O2BitmapContext.m +++ b/Onyx2D/O2BitmapContext.m @@ -134,19 +134,8 @@ O2BitmapInfo O2BitmapContextGetBitmapInfo(O2ContextRef selfX) { O2ImageRef O2BitmapContextCreateImage(O2ContextRef selfX) { O2BitmapContextRef self=(O2BitmapContextRef)selfX; -#if 1 -// FIXME: this needs to be either a copy or a copy on write - return [self->_surface retain]; -#else - O2DataProviderRef provider=O2DataProviderCreateWithData(NULL,_data,_pixelsWide*_pixelsHigh*4,NULL); - - O2Image *image=O2ImageCreate(_width,_height,_bitsPerComponent,_bitsPerPixel,_bytesPerRow,_colorSpace, - _bitmapInfo,provider,NULL,NO,kO2RenderingIntentDefault); - - O2DataProviderRelease(provider); - - return image; -#endif + + return O2SurfaceCreateImage(self->_surface); } @end diff --git a/Onyx2D/O2Image.h b/Onyx2D/O2Image.h index 8ad01f09..f6b416b3 100644 --- a/Onyx2D/O2Image.h +++ b/Onyx2D/O2Image.h @@ -49,6 +49,7 @@ typedef enum { kO2ImageAlphaFirst, kO2ImageAlphaNoneSkipLast, kO2ImageAlphaNoneSkipFirst, + kO2ImageAlphaOnly, } O2ImageAlphaInfo; enum { diff --git a/Onyx2D/O2Surface.h b/Onyx2D/O2Surface.h index e969ccc1..1e2dbd36 100644 --- a/Onyx2D/O2Surface.h +++ b/Onyx2D/O2Surface.h @@ -70,6 +70,7 @@ typedef void (*O2SurfaceWriteSpan_argb32f)(O2Surface *self,int x,int y,O2argb32f -(void)setWidth:(size_t)width height:(size_t)height reallocateOnlyIfRequired:(BOOL)roir; +O2ImageRef O2SurfaceCreateImage(O2Surface *surface); BOOL O2SurfaceIsValidFormat(int format); diff --git a/Onyx2D/O2Surface.m b/Onyx2D/O2Surface.m index 1aa461de..ef212090 100644 --- a/Onyx2D/O2Surface.m +++ b/Onyx2D/O2Surface.m @@ -551,6 +551,19 @@ static BOOL initFunctionsForParameters(O2Surface *self,size_t bitsPerComponent,s } } +O2ImageRef O2SurfaceCreateImage(O2Surface *self) { + NSData *data=[[NSData alloc] initWithBytes:self->_pixelBytes length:self->_bytesPerRow*self->_height]; + O2DataProviderRef provider=CGDataProviderCreateWithCFData(data); + + O2Image *result=O2ImageCreate(self->_width,self->_height,self->_bitsPerComponent,self->_bitsPerPixel,self->_bytesPerRow,self->_colorSpace, + self->_bitmapInfo,provider,self->_decode,self->_interpolate,self->_renderingIntent); + + O2DataProviderRelease(provider); + [data release]; + + return result; +} + void O2SurfaceWriteSpan_argb8u_PRE(O2Surface *self,int x,int y,O2argb8u *span,int length) { if(length==0) return; diff --git a/Onyx2D/platform_Windows/O2Context_builtin_gdi.m b/Onyx2D/platform_Windows/O2Context_builtin_gdi.m index 2c98f70e..3bb48527 100644 --- a/Onyx2D/platform_Windows/O2Context_builtin_gdi.m +++ b/Onyx2D/platform_Windows/O2Context_builtin_gdi.m @@ -22,6 +22,10 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI @implementation O2Context_builtin_gdi ++(BOOL)canInitBitmap { + return YES; +} + -initWithSurface:(O2Surface *)surface flipped:(BOOL)flipped { [super initWithSurface:surface flipped:flipped]; /* FIX: we need to also override initWithBytes:... and create an O2Surface_DIBSection for the pixel format. diff --git a/OpenGL/OpenGL.xcodeproj/project.pbxproj b/OpenGL/OpenGL.xcodeproj/project.pbxproj index 6c14ae7d..41c40d97 100644 --- a/OpenGL/OpenGL.xcodeproj/project.pbxproj +++ b/OpenGL/OpenGL.xcodeproj/project.pbxproj @@ -283,7 +283,14 @@ isa = PBXProject; buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "OpenGL" */; compatibilityVersion = "Xcode 2.4"; + developmentRegion = English; hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + ); mainGroup = 0867D691FE84028FC02AAC07 /* OpenGL */; productRefGroup = 034768DFFF38A50411DB9C8B /* Products */; projectDirPath = ""; diff --git a/QuartzCore/CAAction.h b/QuartzCore/CAAction.h new file mode 100644 index 00000000..36e7313b --- /dev/null +++ b/QuartzCore/CAAction.h @@ -0,0 +1,5 @@ +#import + +@protocol CAAction + +@end diff --git a/QuartzCore/CAAnimation.m b/QuartzCore/CAAnimation.m index 830e1d86..44d957ce 100644 --- a/QuartzCore/CAAnimation.m +++ b/QuartzCore/CAAnimation.m @@ -1,4 +1,5 @@ #import +#import #import @implementation CAAnimation @@ -7,6 +8,17 @@ return [[[self alloc] init] autorelease]; } +-init { + _duration=[CATransaction animationDuration]; + _timingFunction=[[CATransaction animationTimingFunction] retain]; + return self; +} + +-(void)dealloc { + [_timingFunction release]; + [super dealloc]; +} + -copyWithZone:(NSZone *)zone { NSUnimplementedMethod(); return nil; diff --git a/QuartzCore/CABase.h b/QuartzCore/CABase.h index 5cba2102..1e522372 100644 --- a/QuartzCore/CABase.h +++ b/QuartzCore/CABase.h @@ -1,3 +1,6 @@ +#import #define CA_EXPORT extern + +CA_EXPORT CFTimeInterval CACurrentMediaTime(void); diff --git a/QuartzCore/CABase.m b/QuartzCore/CABase.m new file mode 100644 index 00000000..b9c23202 --- /dev/null +++ b/QuartzCore/CABase.m @@ -0,0 +1,21 @@ +#import +#import + +static double conversionFactor(){ + struct mach_timebase_info timebase; + kern_return_t error; + + if((mach_timebase_info(&timebase))!=KERN_SUCCESS){ + NSLog(@"mach_timebase_info returned %d",error); + return 1; + } + + return 0.000000001 * ((double)timebase.numer/(double)timebase.denom); +} + +CFTimeInterval CACurrentMediaTime(void) { + uint64_t value=mach_absolute_time(); + + return ((double) value)*conversionFactor(); +} + diff --git a/QuartzCore/CALayer.h b/QuartzCore/CALayer.h index 46567537..9d6b7e69 100644 --- a/QuartzCore/CALayer.h +++ b/QuartzCore/CALayer.h @@ -2,6 +2,9 @@ #import #import #import +#import + +@class CAAnimation,CALayerContext; enum { kCALayerNotSizable = 0x00, @@ -14,10 +17,12 @@ enum { }; @interface CALayer : NSObject { - CALayer *_superLayer; + CALayerContext *_context; + CALayer *_superlayer; NSArray *_sublayers; id _delegate; - CGRect _frame; + CGPoint _anchorPoint; + CGPoint _position; CGRect _bounds; float _opacity; BOOL _opaque; @@ -25,15 +30,18 @@ enum { CATransform3D _transform; CATransform3D _sublayerTransform; BOOL _needsDisplay; + NSMutableDictionary *_animations; } +layer; -@property(readonly) CALayer *superLayer; +@property(readonly) CALayer *superlayer; @property(copy) NSArray *sublayers; @property(assign) id delegate; -@property CGRect frame; +@property CGPoint anchorPoint; +@property CGPoint position; @property CGRect bounds; +@property CGRect frame; @property float opacity; @property BOOL opaque; @property(retain) id contents; @@ -43,6 +51,7 @@ enum { -init; -(void)addSublayer:(CALayer *)layer; +-(void)replaceSublayer:(CALayer *)layer with:(CALayer *)other; -(void)display; -(void)displayIfNeeded; -(void)drawInContext:(CGContextRef)context; @@ -51,6 +60,14 @@ enum { -(void)setNeedsDisplay; -(void)setNeedsDisplayInRect:(CGRect)rect; +-(void)addAnimation:(CAAnimation *)animation forKey:(NSString *)key; +-(CAAnimation *)animationForKey:(NSString *)key; +-(void)removeAllAnimations; +-(void)removeAnimationForKey:(NSString *)key; +-(NSArray *)animationKeys; + +-(id )actionForKey:(NSString *)key; + @end @interface NSObject(CALayerDelegate) diff --git a/QuartzCore/CALayer.m b/QuartzCore/CALayer.m index 25cb1903..72d3ea6e 100644 --- a/QuartzCore/CALayer.m +++ b/QuartzCore/CALayer.m @@ -1,4 +1,8 @@ #import +#import +#import +#import +#import @implementation CALayer @@ -6,8 +10,18 @@ return [[[self alloc] init] autorelease]; } --(CALayer *)superLayer { - return _superLayer; + +-(CALayerContext *)_context { + return _context; +} + +-(void)_setContext:(CALayerContext *)context { + _context=context; + [_sublayers makeObjectsPerformSelector:@selector(_setContext:) withObject:context]; +} + +-(CALayer *)superlayer { + return _superlayer; } -(NSArray *)sublayers { @@ -19,6 +33,7 @@ [_sublayers release]; _sublayers=sublayers; [_sublayers makeObjectsPerformSelector:@selector(_setSuperLayer:) withObject:self]; + [_sublayers makeObjectsPerformSelector:@selector(_setContext:) withObject:_context]; } -(id)delegate { @@ -29,12 +44,29 @@ _delegate=value; } --(CGRect)frame { - return _frame; +-(CGPoint)anchorPoint { + return _anchorPoint; } --(void)setFrame:(CGRect)value { - _frame=value; +-(void)setAnchorPoint:(CGPoint)value { + _anchorPoint=value; +} + +-(CGPoint)position { + return _position; +} + +-(void)setPosition:(CGPoint)value { + CAAnimation *animation=[self animationForKey:@"position"]; + + if(animation==nil && ![CATransaction disableActions]){ + id action=[self actionForKey:@"position"]; + + if(action!=nil) + [self addAnimation:action forKey:@"position"]; + } + + _position=value; } -(CGRect)bounds { @@ -42,14 +74,58 @@ } -(void)setBounds:(CGRect)value { + CAAnimation *animation=[self animationForKey:@"bounds"]; + + if(animation==nil && ![CATransaction disableActions]){ + id action=[self actionForKey:@"bounds"]; + + if(action!=nil) + [self addAnimation:action forKey:@"bounds"]; + } + _bounds=value; } +-(CGRect)frame { + CGRect result; + + result.size=_bounds.size; + result.origin.x=_position.x-result.size.width*_anchorPoint.x; + result.origin.y=_position.y-result.size.height*_anchorPoint.y; + + return result; +} + +-(void)setFrame:(CGRect)value { + + CGPoint position; + + position.x=value.origin.x+value.size.width*_anchorPoint.x; + position.y=value.origin.y+value.size.height*_anchorPoint.y; + + [self setPosition:position]; + + CGRect bounds=_bounds; + + bounds.size=value.size; + + [self setBounds:bounds]; +} + -(float)opacity { return _opacity; } -(void)setOpacity:(float)value { + CAAnimation *animation=[self animationForKey:@"opacity"]; + + if(animation==nil && ![CATransaction disableActions]){ + id action=[self actionForKey:@"opacity"]; + + if(action!=nil) + [self addAnimation:action forKey:@"opacity"]; + } + _opacity=value; } @@ -88,40 +164,76 @@ } -init { - _superLayer=nil; - _sublayers=[NSMutableArray new]; + _superlayer=nil; + _sublayers=[NSArray new]; _delegate=nil; - _frame=CGRectZero; + _anchorPoint=CGPointMake(0.5,0.5); + _position=CGPointZero; _bounds=CGRectZero; _opacity=1.0; _opaque=YES; _contents=nil; _transform=CATransform3DIdentity; _sublayerTransform=CATransform3DIdentity; + _animations=[[NSMutableDictionary alloc] init]; return self; } +-(void)dealloc { + [_sublayers release]; + [_animations release]; + [super dealloc]; +} + -(void)_setSuperLayer:(CALayer *)parent { - _superLayer=parent; + _superlayer=parent; } -(void)_removeSublayer:(CALayer *)child { NSMutableArray *layers=[_sublayers mutableCopy]; [layers removeObjectIdenticalTo:child]; [self setSublayers:layers]; + [layers release]; } -(void)addSublayer:(CALayer *)layer { [self setSublayers:[_sublayers arrayByAddingObject:layer]]; } +-(void)replaceSublayer:(CALayer *)layer with:(CALayer *)other { + NSMutableArray *layers=[_sublayers mutableCopy]; + NSUInteger index=[_sublayers indexOfObjectIdenticalTo:layer]; + + [layers replaceObjectAtIndex:index withObject:other]; + + [self setSublayers:layers]; + [layers release]; + + layer->_superlayer=nil; +} + -(void)display { + if([_delegate respondsToSelector:@selector(displayLayer:)]) + [_delegate displayLayer:self]; + else { +#if 0 + + +#warning create bitmap context + + [self drawInContext:context]; + _contents=image; + [self setContents:image]; +#endif +} } -(void)displayIfNeeded { } -(void)drawInContext:(CGContextRef)context { + if([_delegate respondsToSelector:@selector(drawLayer:inContext:)]) + [_delegate drawLayer:self inContext:context]; } -(BOOL)needsDisplay { @@ -129,8 +241,9 @@ } -(void)removeFromSuperlayer { - [_superLayer _removeSublayer:self]; - _superLayer=nil; + [_superlayer _removeSublayer:self]; + _superlayer=nil; + [self _setContext:nil]; } -(void)setNeedsDisplay { @@ -141,4 +254,48 @@ _needsDisplay=YES; } +-(void)addAnimation:(CAAnimation *)animation forKey:(NSString *)key { + if(_context==nil) + return; + + [_animations setObject:animation forKey:key]; + NSLog(@"context=%@",_context); + [_context startTimerIfNeeded]; +} + +-(CAAnimation *)animationForKey:(NSString *)key { + return [_animations objectForKey:key]; +} + +-(void)removeAllAnimations { + [_animations removeAllObjects]; +} + +-(void)removeAnimationForKey:(NSString *)key { + [_animations removeObjectForKey:key]; +} + +-(NSArray *)animationKeys { + return [_animations allKeys]; +} + +-valueForKey:(NSString *)key { +// FIXME: KVC appears broken for structs + + if([key isEqualToString:@"bounds"]) + return [NSValue valueWithRect:_bounds]; + if([key isEqualToString:@"frame"]) + return [NSValue valueWithRect:[self frame]]; + + return [super valueForKey:key]; +} + +-(id )actionForKey:(NSString *)key { + CABasicAnimation *basic=[CABasicAnimation animationWithKeyPath:key]; + + [basic setFromValue:[self valueForKey:key]]; + + return basic; +} + @end diff --git a/QuartzCore/CALayerContext.h b/QuartzCore/CALayerContext.h new file mode 100644 index 00000000..8d104fd4 --- /dev/null +++ b/QuartzCore/CALayerContext.h @@ -0,0 +1,29 @@ +#import +#import +#import + +@class CARenderer,CALayer,CGLPixelSurface,NSTimer; + +@interface CALayerContext : NSObject { + CGLPixelFormatObj _pixelFormat; + CGLContextObj _glContext; + CGLPixelSurface *_pixelSurface; + CALayer *_layer; + CARenderer *_renderer; + + NSTimer *_timer; +} + +-initWithFrame:(CGRect)rect; + +-(CGLPixelSurface *)pixelSurface; +-(void)setFrame:(CGRect)value; +-(void)setLayer:(CALayer *)layer; + +-(void)invalidate; + +-(void)render; + +-(void)startTimerIfNeeded; + +@end diff --git a/QuartzCore/CALayerContext.m b/QuartzCore/CALayerContext.m new file mode 100644 index 00000000..a5fd5570 --- /dev/null +++ b/QuartzCore/CALayerContext.m @@ -0,0 +1,111 @@ +#import +#import +#import +#import +#import + +@interface CALayer(private) +-(void)_setContext:(CALayerContext *)context; +@end + +@implementation CALayerContext + +-initWithFrame:(CGRect)rect { + CGLError error; + + CGLPixelFormatAttribute attributes[1]={ + 0, + }; + GLint numberOfVirtualScreens; + + CGLChoosePixelFormat(attributes,&_pixelFormat,&numberOfVirtualScreens); + + if((error=CGLCreateContext(_pixelFormat,NULL,&_glContext))!=kCGLNoError) + NSLog(@"CGLCreateContext failed with %d in %s %d",error,__FILE__,__LINE__); + + GLint width=rect.size.width; + GLint height=rect.size.height; + + GLint backingSize[2]={width,height}; + + CGLSetParameter(_glContext,kCGLCPSurfaceBackingSize,backingSize); + + _pixelSurface=[[CGLPixelSurface alloc] initWithFrame:O2RectMake(0,0,width,height)]; + [_pixelSurface setOpaque:NO]; + + _renderer=[[CARenderer rendererWithCGLContext:_glContext options:nil] retain]; + + return self; +} + +-(void)dealloc { + [_timer invalidate]; + [_timer release]; + [super dealloc]; +} + +-(CGLPixelSurface *)pixelSurface { + return _pixelSurface; +} + +-(void)setFrame:(CGRect)rect { + GLint width=rect.size.width; + GLint height=rect.size.height; + + GLint backingSize[2]={width,height}; + + CGLSetParameter(_glContext,kCGLCPSurfaceBackingSize,backingSize); + + [_pixelSurface setFrame:rect]; +} + +-(void)setLayer:(CALayer *)layer { + layer=[layer retain]; + [_layer release]; + _layer=layer; + + [_layer _setContext:self]; + [_renderer setLayer:layer]; +} + +-(void)invalidate { +} + +-(void)renderLayer:(CALayer *)layer intoSurface:(CGLPixelSurface *)pixelSurface { + CGLSetCurrentContext(_glContext); + + glEnable(GL_DEPTH_TEST); + glShadeModel(GL_SMOOTH); + + CGRect frame=[_pixelSurface frame]; + GLint width=frame.size.width; + GLint height=frame.size.height; + + glViewport(0,0,width,height); + glMatrixMode(GL_PROJECTION); + glLoadIdentity(); + glOrtho (0, width, 0, height, -1, 1); + + [_renderer render]; + + [pixelSurface flushBuffer]; +} + +-(void)render { + [self renderLayer:_layer intoSurface:_pixelSurface]; +} + +-(void)timer:(NSTimer *)timer { + [_renderer beginFrameAtTime:CACurrentMediaTime() timeStamp:NULL]; + + [self render]; + + [_renderer endFrame]; +} + +-(void)startTimerIfNeeded { + if(_timer==nil) + _timer=[[NSTimer scheduledTimerWithTimeInterval:1.0/60.0 target:self selector:@selector(timer:) userInfo:nil repeats:YES] retain]; +} + +@end diff --git a/QuartzCore/CAMediaTimingFunction.m b/QuartzCore/CAMediaTimingFunction.m index 9c285ce8..eb489a57 100644 --- a/QuartzCore/CAMediaTimingFunction.m +++ b/QuartzCore/CAMediaTimingFunction.m @@ -23,12 +23,46 @@ NSString * const kCAMediaTimingFunctionDefault=@"kCAMediaTimingFunctionDefault"; } +functionWithName:(NSString *)name { - NSUnimplementedMethod(); + if([name isEqualToString:kCAMediaTimingFunctionLinear]) + return [self functionWithControlPoints:0:0:1:1]; + if([name isEqualToString:kCAMediaTimingFunctionEaseIn]) + return [self functionWithControlPoints:0.5:0:1:1]; + if([name isEqualToString:kCAMediaTimingFunctionEaseOut]) + return [self functionWithControlPoints:0:0:0.5:1]; + if([name isEqualToString:kCAMediaTimingFunctionEaseInEaseOut]) + return [self functionWithControlPoints:0.5:0:0.5:1]; + if([name isEqualToString:kCAMediaTimingFunctionDefault]) + return [self functionWithControlPoints:0.25:0.1:0.25:1]; + return nil; } -(void)getControlPointAtIndex:(size_t)index values:(float[2])ptr { - NSUnimplementedMethod(); + + switch(index){ + + default: + case 0: + ptr[0]=0; + ptr[1]=0; + break; + + case 1: + ptr[0]=_c1x; + ptr[1]=_c1y; + break; + + case 2: + ptr[0]=_c2x; + ptr[1]=_c2y; + break; + + case 3: + ptr[0]=1; + ptr[1]=1; + break; + + } } @end diff --git a/QuartzCore/CARenderer.h b/QuartzCore/CARenderer.h index e0bd4e74..62b07172 100644 --- a/QuartzCore/CARenderer.h +++ b/QuartzCore/CARenderer.h @@ -1,5 +1,6 @@ #import #import +#import @class CALayer,O2Surface; @@ -14,6 +15,10 @@ +(CARenderer *)rendererWithCGLContext:(void *)cglContext options:(NSDictionary *)options; +-(void)beginFrameAtTime:(CFTimeInterval)currentTime timeStamp:(CVTimeStamp *)timeStamp; + -(void)render; +-(void)endFrame; + @end diff --git a/QuartzCore/CARenderer.m b/QuartzCore/CARenderer.m index f5514d70..cabae330 100644 --- a/QuartzCore/CARenderer.m +++ b/QuartzCore/CARenderer.m @@ -1,4 +1,8 @@ #import +#import +#import +#import +#import #import #import @@ -25,7 +29,293 @@ return [[[self alloc] initWithCGLContext:cglContext options:options] autorelease]; } +static void startAnimationsInLayer(CALayer *layer,CFTimeInterval currentTime){ + NSArray *keys=[layer animationKeys]; + + for(NSString *key in keys){ + CAAnimation *check=[layer animationForKey:key]; + + if([check beginTime]==0.0) + [check setBeginTime:currentTime]; + if(currentTime>[check beginTime]+[check duration]){ + [layer removeAnimationForKey:key]; + } + + } + + for(CALayer *child in layer.sublayers) + startAnimationsInLayer(child,currentTime); +} + +-(void)beginFrameAtTime:(CFTimeInterval)currentTime timeStamp:(CVTimeStamp *)timeStamp { + startAnimationsInLayer(_rootLayer,currentTime); +} + +static inline float cubed(float value){ + return value*value*value; +} + +static inline float squared(float value){ + return value*value; +} + +static float applyMediaTimingFunction(CAMediaTimingFunction *function,float t){ + float result; + float cp1[2]; + float cp2[2]; + + [function getControlPointAtIndex:1 values:cp1]; + [function getControlPointAtIndex:2 values:cp2]; + + double x=cubed(1.0-t)*0.0+3*squared(1-t)*t*cp1[0]+3*(1-t)*squared(t)*cp2[0]+cubed(t)*1.0; + double y=cubed(1.0-t)*0.0+3*squared(1-t)*t*cp1[1]+3*(1-t)*squared(t)*cp2[1]+cubed(t)*1.0; + +// this is wrong + return y; +} + +static float mediaTimingScale(CAAnimation *animation,CFTimeInterval currentTime){ + CFTimeInterval begin=[animation beginTime]; + CFTimeInterval duration=[animation duration]; + CFTimeInterval delta=currentTime-begin; + double zeroToOne=delta/duration; + CAMediaTimingFunction *function=[animation timingFunction]; + + if(function==nil) + function=[CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionDefault]; + + return applyMediaTimingFunction(function,zeroToOne); +} + +static float interpolateFloatInLayerKey(CALayer *layer,NSString *key,CFTimeInterval currentTime){ + CAAnimation *animation=[layer animationForKey:key]; + + if(animation==nil) + return [[layer valueForKey:key] floatValue]; + + if([animation isKindOfClass:[CABasicAnimation class]]){ + CABasicAnimation *basic=(CABasicAnimation *)animation; + + id fromValue=[basic fromValue]; + id toValue=[basic toValue]; + + if(toValue==nil) + toValue=[layer valueForKey:key]; + + float fromFloat=[fromValue floatValue]; + float toFloat=[toValue floatValue]; + + float resultFloat; + double timingScale=mediaTimingScale(animation,currentTime); + + resultFloat=fromFloat+(toFloat-fromFloat)*timingScale; + + return resultFloat; + } + + return 0; +} + +static CGPoint interpolatePointInLayerKey(CALayer *layer,NSString *key,CFTimeInterval currentTime){ + CAAnimation *animation=[layer animationForKey:key]; + + if(animation==nil) + return [[layer valueForKey:key] pointValue]; + + if([animation isKindOfClass:[CABasicAnimation class]]){ + CABasicAnimation *basic=(CABasicAnimation *)animation; + + id fromValue=[basic fromValue]; + id toValue=[basic toValue]; + + if(toValue==nil) + toValue=[layer valueForKey:key]; + + CGPoint fromPoint=[fromValue pointValue]; + CGPoint toPoint=[toValue pointValue]; + + CGPoint resultPoint; + double timingScale=mediaTimingScale(animation,currentTime); + + resultPoint.x=fromPoint.x+(toPoint.x-fromPoint.x)*timingScale; + resultPoint.y=fromPoint.y+(toPoint.y-fromPoint.y)*timingScale; + + return resultPoint; + } + + return CGPointMake(0,0); +} + +static CGRect interpolateRectInLayerKey(CALayer *layer,NSString *key,CFTimeInterval currentTime){ + CAAnimation *animation=[layer animationForKey:key]; + + if(animation==nil){ + return [[layer valueForKey:key] rectValue]; + } + + if([animation isKindOfClass:[CABasicAnimation class]]){ + CABasicAnimation *basic=(CABasicAnimation *)animation; + + id fromValue=[basic fromValue]; + id toValue=[basic toValue]; + + if(toValue==nil) + toValue=[layer valueForKey:key]; + + CGRect fromRect=[fromValue rectValue]; + CGRect toRect=[toValue rectValue]; + + double timingScale=mediaTimingScale(animation,currentTime); + + CGRect resultRect; + + resultRect.origin.x=fromRect.origin.x+(toRect.origin.x-fromRect.origin.x)*timingScale; + resultRect.origin.y=fromRect.origin.y+(toRect.origin.y-fromRect.origin.y)*timingScale; + resultRect.size.width=fromRect.size.width+(toRect.size.width-fromRect.size.width)*timingScale; + resultRect.size.height=fromRect.size.height+(toRect.size.height-fromRect.size.height)*timingScale; + + return resultRect; + } + + return CGRectMake(0,0,0,0); +} + +-(void)_renderLayer:(CALayer *)layer z:(float)z currentTime:(CFTimeInterval)currentTime { + CGImageRef image=layer.contents; + + size_t imageWidth=CGImageGetWidth(image); + size_t imageHeight=CGImageGetHeight(image); + CGBitmapInfo bitmapInfo=CGImageGetBitmapInfo(image); + + CGDataProviderRef provider=CGImageGetDataProvider(image); + CFDataRef data=CGDataProviderCopyData(provider); + const void *pixelBytes=CFDataGetBytePtr(data); + + + GLenum glFormat=GL_BGRA; + GLenum glType=GL_UNSIGNED_INT_8_8_8_8_REV; + + CGImageAlphaInfo alphaInfo=bitmapInfo&kCGBitmapAlphaInfoMask; + CGBitmapInfo byteOrder=bitmapInfo&kCGBitmapByteOrderMask; + + switch(alphaInfo){ + + case kCGImageAlphaNone: + break; + + case kCGImageAlphaPremultipliedLast: + if(byteOrder==kO2BitmapByteOrder32Big){ + glFormat=GL_RGBA; + glType=GL_UNSIGNED_INT_8_8_8_8_REV; + } + + break; + + case kCGImageAlphaPremultipliedFirst: // ARGB + if(byteOrder==kCGBitmapByteOrder32Little){ + glFormat=GL_BGRA; + glType=GL_UNSIGNED_INT_8_8_8_8_REV; + } + break; + + case kCGImageAlphaLast: + break; + + case kCGImageAlphaFirst: + break; + + case kCGImageAlphaNoneSkipLast: + break; + + case kCGImageAlphaNoneSkipFirst: + break; + + case kCGImageAlphaOnly: + break; + } + + + glTexImage2D(GL_TEXTURE_2D,0,GL_RGBA8,imageWidth,imageHeight,0,glFormat,glType,pixelBytes); + + glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_NEAREST); + glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_NEAREST); + glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_S,GL_REPEAT); + glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_WRAP_T,GL_REPEAT); + + CGPoint anchorPoint=interpolatePointInLayerKey(layer,@"anchorPoint",currentTime); + CGPoint position=interpolatePointInLayerKey(layer,@"position",currentTime); + CGRect bounds=interpolateRectInLayerKey(layer,@"bounds",currentTime); + float opacity=interpolateFloatInLayerKey(layer,@"opacity",currentTime); + + GLfloat texture[4*2]; + GLfloat vertices[4*3]; + + texture[0]=0; + texture[1]=1; + texture[2]=1; + texture[3]=1; + texture[4]=0; + texture[5]=0; + texture[6]=1; + texture[7]=0; + + vertices[0]=0; + vertices[1]=0; + vertices[2]=z; + + vertices[3]=bounds.size.width; + vertices[4]=0; + vertices[5]=z; + + vertices[6]=0; + vertices[7]=bounds.size.height; + vertices[8]=z; + + vertices[9]=bounds.size.width; + vertices[10]=bounds.size.height; + vertices[11]=z; + + + glPushMatrix(); + // glTranslatef(width/2,height/2,0); + glTexCoordPointer(2, GL_FLOAT, 0, texture); + glVertexPointer(3, GL_FLOAT, 0, vertices); + + + glTranslatef(position.x-(bounds.size.width*anchorPoint.x),position.y-(bounds.size.height*anchorPoint.y),0); + // glTranslatef(position.x,position.y,0); + // glScalef(bounds.size.width,bounds.size.height,1); + + // glRotatef(1,0,0,1); + glColor4f(opacity,opacity,opacity,opacity); + glDrawArrays(GL_TRIANGLE_STRIP, 0, 4); + + for(CALayer *child in layer.sublayers) + [self _renderLayer:child z:z+1 currentTime:currentTime]; + + glPopMatrix(); +} + -(void)render { + glMatrixMode(GL_MODELVIEW); + glLoadIdentity(); + + glClearColor(1, 0, 0, 1); + glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); + + glEnable( GL_TEXTURE_2D ); + glEnableClientState(GL_VERTEX_ARRAY); + glEnableClientState(GL_TEXTURE_COORD_ARRAY); + + glEnable (GL_BLEND); + glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA); + + [self _renderLayer:_rootLayer z:0 currentTime:CACurrentMediaTime()]; + + glFlush(); +} + +-(void)endFrame { } @end diff --git a/QuartzCore/CATransaction.h b/QuartzCore/CATransaction.h index b0598d78..7172c1ea 100644 --- a/QuartzCore/CATransaction.h +++ b/QuartzCore/CATransaction.h @@ -1,6 +1,8 @@ #import #import +@class CAMediaTimingFunction; + CA_EXPORT NSString * const kCATransactionAnimationDuration; CA_EXPORT NSString * const kCATransactionDisableActions; CA_EXPORT NSString * const kCATransactionAnimationTimingFunction; @@ -11,12 +13,12 @@ CA_EXPORT NSString * const kCATransactionCompletionBlock; +(BOOL)disableActions; +(CFTimeInterval)animationDuration; +(CAMediaTimingFunction *)animationTimingFunction; -+(void)completionBlock; +//+(void (^)(void))completionBlock; +valueForKey:(NSString *)key; +(void)setAnimationDuration:(CFTimeInterval)value; +(void)setAnimationTimingFunction:(CAMediaTimingFunction *)value; -+(void)setCompletionBlock:(void (^)(void))value; +//+(void)setCompletionBlock:(void (^)(void))value; +(void)setDisableActions:(BOOL)value; +(void)setValue:value forKey:(NSString *)key; diff --git a/QuartzCore/CATransaction.m b/QuartzCore/CATransaction.m index e69de29b..10890249 100644 --- a/QuartzCore/CATransaction.m +++ b/QuartzCore/CATransaction.m @@ -0,0 +1,108 @@ +#import +#import +#import +#import +#import +#import +#import "CATransactionGroup.h" + +NSString * const kCATransactionAnimationDuration=@"kCATransactionAnimationDuration"; +NSString * const kCATransactionDisableActions=@"kCATransactionDisableActions"; +NSString * const kCATransactionAnimationTimingFunction=@"kCATransactionAnimationTimingFunction"; +NSString * const kCATransactionCompletionBlock=@"kCATransactionCompletionBlock"; + +@implementation CATransaction + +static NSMutableArray *transactionStack(){ + NSMutableDictionary *shared=[NSCurrentThread() sharedDictionary]; + id stack=[shared objectForKey:@"CATransactionStack"]; + + if(stack==nil){ + stack=[NSMutableArray array]; + [shared setObject:stack forKey:@"CATransactionStack"]; + } + + return stack; +} + +static CATransactionGroup *currentTransactionGroup(){ + id stack=transactionStack(); + + CATransactionGroup *result=[stack lastObject]; + + return result; +} + +static CATransactionGroup *createImplicitTransactionGroupIfNeeded(){ + CATransactionGroup *check=currentTransactionGroup(); + + if(check==nil){ + check=[[CATransactionGroup alloc] init]; + + [transactionStack() addObject:check]; + [[NSRunLoop currentRunLoop] performSelector:@selector(commit) target:[CATransaction class] argument:nil order:0 modes:[NSArray arrayWithObject:NSDefaultRunLoopMode]]; + } + + return check; +} + + ++(BOOL)disableActions { + return [[self valueForKey:kCATransactionDisableActions] boolValue]; +} + ++(CFTimeInterval)animationDuration { + return [[self valueForKey:kCATransactionAnimationDuration] doubleValue]; +} + ++(CAMediaTimingFunction *)animationTimingFunction { + return [self valueForKey:kCATransactionAnimationTimingFunction]; +} + +//+(void (^)(void))completionBlock; + ++valueForKey:(NSString *)key { + CATransactionGroup *group=createImplicitTransactionGroupIfNeeded(); + + return [group valueForKey:key]; +} + ++(void)setAnimationDuration:(CFTimeInterval)value { + [self setValue:[NSNumber numberWithDouble:value] forKey:kCATransactionAnimationDuration]; +} + ++(void)setAnimationTimingFunction:(CAMediaTimingFunction *)value { + [self setValue:value forKey:kCATransactionAnimationDuration]; +} + +//+(void)setCompletionBlock:(void (^)(void))value; ++(void)setDisableActions:(BOOL)value { + [self setValue:[NSNumber numberWithBool:value] forKey:kCATransactionDisableActions]; +} + ++(void)setValue:value forKey:(NSString *)key { + CATransactionGroup *group=createImplicitTransactionGroupIfNeeded(); + + [group setValue:value forKey:key]; +} + ++(void)begin { + CATransactionGroup *group=[[CATransactionGroup alloc] init]; + + [transactionStack() addObject:group]; +} + ++(void)commit { + [transactionStack() removeLastObject]; +} + ++(void)flush { +} + ++(void)lock { +} + ++(void)unlock { +} + +@end diff --git a/QuartzCore/CATransactionGroup.h b/QuartzCore/CATransactionGroup.h new file mode 100644 index 00000000..feae3bb7 --- /dev/null +++ b/QuartzCore/CATransactionGroup.h @@ -0,0 +1,12 @@ +#import + +@class NSMutableDictionary; + +@interface CATransactionGroup : NSObject { + NSMutableDictionary *_values; +} + +-valueForKey:(NSString *)key; +-(void)setValue:value forKey:(NSString *)key; + +@end diff --git a/QuartzCore/CATransactionGroup.m b/QuartzCore/CATransactionGroup.m new file mode 100644 index 00000000..acc450f3 --- /dev/null +++ b/QuartzCore/CATransactionGroup.m @@ -0,0 +1,25 @@ +#import "CATransactionGroup.h" +#import +#import +#import + +@implementation CATransactionGroup + +-init { + _values=[[NSMutableDictionary alloc] init]; + [_values setObject:[NSNumber numberWithFloat:0.25] forKey:kCATransactionAnimationDuration]; + [_values setObject:[NSNumber numberWithBool:NO] forKey:kCATransactionDisableActions]; + // kCATransactionAnimationTimingFunction default is nil + // kCATransactionCompletionBlock default is nil + return self; +} + +-valueForKey:(NSString *)key { + return [_values objectForKey:key]; +} + +-(void)setValue:value forKey:(NSString *)key { + [_values setObject:value forKey:key]; +} + +@end diff --git a/QuartzCore/CAValueFunction.h b/QuartzCore/CAValueFunction.h new file mode 100644 index 00000000..9ddec6c1 --- /dev/null +++ b/QuartzCore/CAValueFunction.h @@ -0,0 +1,27 @@ +#import +#import + +CA_EXPORT NSString * const kCAValueFunctionTranslate; +CA_EXPORT NSString * const kCAValueFunctionTranslateX; +CA_EXPORT NSString * const kCAValueFunctionTranslateY; +CA_EXPORT NSString * const kCAValueFunctionTranslateZ; + +CA_EXPORT NSString * const kCAValueFunctionScale; +CA_EXPORT NSString * const kCAValueFunctionScaleX; +CA_EXPORT NSString * const kCAValueFunctionScaleY; +CA_EXPORT NSString * const kCAValueFunctionScaleZ; + +CA_EXPORT NSString * const kCAValueFunctionRotateX; +CA_EXPORT NSString * const kCAValueFunctionRotateY; +CA_EXPORT NSString * const kCAValueFunctionRotateZ; + + +@interface CAValueFunction : NSObject { + NSString *_name; +} + ++functionWithName:(NSString *)name; + +@property(readonly) NSString *name; + +@end diff --git a/QuartzCore/CAValueFunction.m b/QuartzCore/CAValueFunction.m new file mode 100644 index 00000000..755cea37 --- /dev/null +++ b/QuartzCore/CAValueFunction.m @@ -0,0 +1,38 @@ +#import +#import + +NSString * const kCAValueFunctionTranslate=@"kCAValueFunctionTranslate"; +NSString * const kCAValueFunctionTranslateX=@"kCAValueFunctionTranslateX"; +NSString * const kCAValueFunctionTranslateY=@"kCAValueFunctionTranslateY"; +NSString * const kCAValueFunctionTranslateZ=@"kCAValueFunctionTranslateZ"; + +NSString * const kCAValueFunctionScale=@"kCAValueFunctionScale"; +NSString * const kCAValueFunctionScaleX=@"kCAValueFunctionScaleX"; +NSString * const kCAValueFunctionScaleY=@"kCAValueFunctionScaleY"; +NSString * const kCAValueFunctionScaleZ=@"kCAValueFunctionScaleZ"; + +NSString * const kCAValueFunctionRotateX=@"kCAValueFunctionRotateX"; +NSString * const kCAValueFunctionRotateY=@"kCAValueFunctionRotateY"; +NSString * const kCAValueFunctionRotateZ=@"kCAValueFunctionRotateZ"; + +@implementation CAValueFunction + +-initWithName:(NSString *)name { + _name=[name copy]; + return self; +} + +-(void)dealloc { + [_name release]; + [super dealloc]; +} + ++functionWithName:(NSString *)name { + return [[[self alloc] initWithName:name] autorelease]; +} + +-(NSString *)name { + return _name; +} + +@end diff --git a/QuartzCore/CoreAnimation.h b/QuartzCore/CoreAnimation.h index 81ff0a0b..bcea91b7 100644 --- a/QuartzCore/CoreAnimation.h +++ b/QuartzCore/CoreAnimation.h @@ -2,3 +2,4 @@ #import #import #import +#import diff --git a/QuartzCore/QuartzCore.xcodeproj/project.pbxproj b/QuartzCore/QuartzCore.xcodeproj/project.pbxproj index 7c544e78..32721ec8 100644 --- a/QuartzCore/QuartzCore.xcodeproj/project.pbxproj +++ b/QuartzCore/QuartzCore.xcodeproj/project.pbxproj @@ -25,6 +25,9 @@ FE0FB9C710F9815300EBA597 /* CIImage.h in Headers */ = {isa = PBXBuildFile; fileRef = FE0FB9B610F9815300EBA597 /* CIImage.h */; settings = {ATTRIBUTES = (Public, ); }; }; FE0FB9C810F9815300EBA597 /* CIVector.h in Headers */ = {isa = PBXBuildFile; fileRef = FE0FB9B810F9815300EBA597 /* CIVector.h */; settings = {ATTRIBUTES = (Public, ); }; }; FE255FF210F10397005CE23E /* CoreImage.h in Headers */ = {isa = PBXBuildFile; fileRef = FE255FEF10F10397005CE23E /* CoreImage.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FE41B88912BEA2EE00ED6C10 /* CATransaction.h in Headers */ = {isa = PBXBuildFile; fileRef = FE41B88812BEA2EE00ED6C10 /* CATransaction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FE41B88A12BEA2EE00ED6C10 /* CATransaction.h in Headers */ = {isa = PBXBuildFile; fileRef = FE41B88812BEA2EE00ED6C10 /* CATransaction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FE41B88B12BEA2EE00ED6C10 /* CATransaction.h in Headers */ = {isa = PBXBuildFile; fileRef = FE41B88812BEA2EE00ED6C10 /* CATransaction.h */; settings = {ATTRIBUTES = (Public, ); }; }; FE4301AC11E255A500EBDD56 /* CoreVideo.h in Headers */ = {isa = PBXBuildFile; fileRef = FE4301AB11E255A500EBDD56 /* CoreVideo.h */; settings = {ATTRIBUTES = (Public, ); }; }; FE4301AD11E255A500EBDD56 /* CoreVideo.h in Headers */ = {isa = PBXBuildFile; fileRef = FE4301AB11E255A500EBDD56 /* CoreVideo.h */; settings = {ATTRIBUTES = (Public, ); }; }; FE4301AE11E255A500EBDD56 /* CoreVideo.h in Headers */ = {isa = PBXBuildFile; fileRef = FE4301AB11E255A500EBDD56 /* CoreVideo.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -36,23 +39,13 @@ FEA3F2141133089500690AA2 /* CIAffineTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = FEA3F2121133089500690AA2 /* CIAffineTransform.h */; settings = {ATTRIBUTES = (Private, ); }; }; FEA3F2151133089500690AA2 /* CIAffineTransform.h in Headers */ = {isa = PBXBuildFile; fileRef = FEA3F2121133089500690AA2 /* CIAffineTransform.h */; settings = {ATTRIBUTES = (Private, ); }; }; FEAEF7E911E3AAD000CA0912 /* CAAnimationGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E011E3AAD000CA0912 /* CAAnimationGroup.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7EA11E3AAD000CA0912 /* CAAnimationGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E111E3AAD000CA0912 /* CAAnimationGroup.m */; }; FEAEF7EB11E3AAD000CA0912 /* CABasicAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E211E3AAD000CA0912 /* CABasicAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7EC11E3AAD000CA0912 /* CABasicAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E311E3AAD000CA0912 /* CABasicAnimation.m */; }; FEAEF7ED11E3AAD000CA0912 /* CAPropertyAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E411E3AAD000CA0912 /* CAPropertyAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7EE11E3AAD000CA0912 /* CAPropertyAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E511E3AAD000CA0912 /* CAPropertyAnimation.m */; }; FEAEF7EF11E3AAD000CA0912 /* CATransition.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E611E3AAD000CA0912 /* CATransition.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7F011E3AAD000CA0912 /* CATransition.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E711E3AAD000CA0912 /* CATransition.m */; }; - FEAEF7F111E3AAD000CA0912 /* CIAffineTransform.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E811E3AAD000CA0912 /* CIAffineTransform.m */; }; FEAEF7F211E3AAD000CA0912 /* CAAnimationGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E011E3AAD000CA0912 /* CAAnimationGroup.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7F311E3AAD000CA0912 /* CAAnimationGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E111E3AAD000CA0912 /* CAAnimationGroup.m */; }; FEAEF7F411E3AAD000CA0912 /* CABasicAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E211E3AAD000CA0912 /* CABasicAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7F511E3AAD000CA0912 /* CABasicAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E311E3AAD000CA0912 /* CABasicAnimation.m */; }; FEAEF7F611E3AAD000CA0912 /* CAPropertyAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E411E3AAD000CA0912 /* CAPropertyAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7F711E3AAD000CA0912 /* CAPropertyAnimation.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E511E3AAD000CA0912 /* CAPropertyAnimation.m */; }; FEAEF7F811E3AAD000CA0912 /* CATransition.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E611E3AAD000CA0912 /* CATransition.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF7F911E3AAD000CA0912 /* CATransition.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E711E3AAD000CA0912 /* CATransition.m */; }; - FEAEF7FA11E3AAD000CA0912 /* CIAffineTransform.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF7E811E3AAD000CA0912 /* CIAffineTransform.m */; }; FEAEF7FB11E3AAD000CA0912 /* CAAnimationGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E011E3AAD000CA0912 /* CAAnimationGroup.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEAEF7FD11E3AAD000CA0912 /* CABasicAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E211E3AAD000CA0912 /* CABasicAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEAEF7FF11E3AAD000CA0912 /* CAPropertyAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF7E411E3AAD000CA0912 /* CAPropertyAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -64,9 +57,7 @@ FEAEF85F11E3AFEF00CA0912 /* CAMediaTiming.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF85D11E3AFEF00CA0912 /* CAMediaTiming.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEAEF86011E3AFEF00CA0912 /* CAMediaTiming.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF85D11E3AFEF00CA0912 /* CAMediaTiming.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEAEF8C311E3B3FF00CA0912 /* CAMediaTimingFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF8C111E3B3FF00CA0912 /* CAMediaTimingFunction.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF8C411E3B3FF00CA0912 /* CAMediaTimingFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF8C211E3B3FF00CA0912 /* CAMediaTimingFunction.m */; }; FEAEF8C511E3B3FF00CA0912 /* CAMediaTimingFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF8C111E3B3FF00CA0912 /* CAMediaTimingFunction.h */; settings = {ATTRIBUTES = (Public, ); }; }; - FEAEF8C611E3B3FF00CA0912 /* CAMediaTimingFunction.m in Sources */ = {isa = PBXBuildFile; fileRef = FEAEF8C211E3B3FF00CA0912 /* CAMediaTimingFunction.m */; }; FEAEF8C711E3B3FF00CA0912 /* CAMediaTimingFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEAEF8C111E3B3FF00CA0912 /* CAMediaTimingFunction.h */; settings = {ATTRIBUTES = (Public, ); }; }; FECA819810EBB231003472F1 /* CAAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEF88C2B100CC45B00B15FD7 /* CAAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; FECA819910EBB231003472F1 /* CALayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FEF88C2C100CC45B00B15FD7 /* CALayer.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -82,6 +73,15 @@ FED38C4910E13E1000A2A651 /* CARenderer.h in Headers */ = {isa = PBXBuildFile; fileRef = FED38BEA10E12BAB00A2A651 /* CARenderer.h */; settings = {ATTRIBUTES = (Public, ); }; }; FED38C8E10E13FCC00A2A651 /* CABase.h in Headers */ = {isa = PBXBuildFile; fileRef = FED38C8D10E13FCC00A2A651 /* CABase.h */; settings = {ATTRIBUTES = (Public, ); }; }; FED38C8F10E13FCC00A2A651 /* CABase.h in Headers */ = {isa = PBXBuildFile; fileRef = FED38C8D10E13FCC00A2A651 /* CABase.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FEDEAA6812C2608F008E5A59 /* CAValueFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEAA6612C2608F008E5A59 /* CAValueFunction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FEDEAA6A12C2608F008E5A59 /* CAValueFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEAA6612C2608F008E5A59 /* CAValueFunction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FEDEAA6C12C2608F008E5A59 /* CAValueFunction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEAA6612C2608F008E5A59 /* CAValueFunction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FEDEABC112C98F59008E5A59 /* CALayerContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEABC012C98F59008E5A59 /* CALayerContext.h */; }; + FEDEABC212C98F59008E5A59 /* CALayerContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEABC012C98F59008E5A59 /* CALayerContext.h */; }; + FEDEABC312C98F59008E5A59 /* CALayerContext.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEABC012C98F59008E5A59 /* CALayerContext.h */; settings = {ATTRIBUTES = (Private, ); }; }; + FEDEB74012D2378C008E5A59 /* CAAction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEB73F12D2378C008E5A59 /* CAAction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FEDEB74112D2378C008E5A59 /* CAAction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEB73F12D2378C008E5A59 /* CAAction.h */; settings = {ATTRIBUTES = (Public, ); }; }; + FEDEB74212D2378C008E5A59 /* CAAction.h in Headers */ = {isa = PBXBuildFile; fileRef = FEDEB73F12D2378C008E5A59 /* CAAction.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEF88C2E100CC45B00B15FD7 /* CAAnimation.h in Headers */ = {isa = PBXBuildFile; fileRef = FEF88C2B100CC45B00B15FD7 /* CAAnimation.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEF88C2F100CC45B00B15FD7 /* CALayer.h in Headers */ = {isa = PBXBuildFile; fileRef = FEF88C2C100CC45B00B15FD7 /* CALayer.h */; settings = {ATTRIBUTES = (Public, ); }; }; FEF88C30100CC45B00B15FD7 /* CATransform3D.h in Headers */ = {isa = PBXBuildFile; fileRef = FEF88C2D100CC45B00B15FD7 /* CATransform3D.h */; settings = {ATTRIBUTES = (Public, ); }; }; @@ -196,6 +196,7 @@ FE0FB9B810F9815300EBA597 /* CIVector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CIVector.h; sourceTree = ""; }; FE0FB9B910F9815300EBA597 /* CIVector.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CIVector.m; sourceTree = ""; }; FE255FEF10F10397005CE23E /* CoreImage.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CoreImage.h; sourceTree = ""; }; + FE41B88812BEA2EE00ED6C10 /* CATransaction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CATransaction.h; sourceTree = ""; }; FE43019D11E2556B00EBDD56 /* CoreVideo.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = CoreVideo.xcodeproj; path = ../CoreVideo/CoreVideo.xcodeproj; sourceTree = SOURCE_ROOT; }; FE4301AB11E255A500EBDD56 /* CoreVideo.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CoreVideo.h; sourceTree = ""; }; FE4477BF1039EECB00ECD6A6 /* QuartzCore.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = QuartzCore.h; sourceTree = ""; }; @@ -220,6 +221,10 @@ FED38BEA10E12BAB00A2A651 /* CARenderer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CARenderer.h; sourceTree = ""; }; FED38C4D10E13E1000A2A651 /* QuartzCore.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = QuartzCore.framework; sourceTree = BUILT_PRODUCTS_DIR; }; FED38C8D10E13FCC00A2A651 /* CABase.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CABase.h; sourceTree = ""; }; + FEDEAA6612C2608F008E5A59 /* CAValueFunction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CAValueFunction.h; sourceTree = ""; }; + FEDEAA6712C2608F008E5A59 /* CAValueFunction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = CAValueFunction.m; sourceTree = ""; }; + FEDEABC012C98F59008E5A59 /* CALayerContext.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CALayerContext.h; sourceTree = ""; }; + FEDEB73F12D2378C008E5A59 /* CAAction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CAAction.h; sourceTree = ""; }; FEF88C1D100CC41C00B15FD7 /* CoreGraphics.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = CoreGraphics.xcodeproj; path = ../CoreGraphics/CoreGraphics.xcodeproj; sourceTree = SOURCE_ROOT; }; FEF88C2B100CC45B00B15FD7 /* CAAnimation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CAAnimation.h; sourceTree = ""; }; FEF88C2C100CC45B00B15FD7 /* CALayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CALayer.h; sourceTree = ""; }; @@ -267,6 +272,11 @@ 0867D691FE84028FC02AAC07 /* QuartzCore */ = { isa = PBXGroup; children = ( + FEDEB73F12D2378C008E5A59 /* CAAction.h */, + FEDEABC012C98F59008E5A59 /* CALayerContext.h */, + FEDEAA6612C2608F008E5A59 /* CAValueFunction.h */, + FEDEAA6712C2608F008E5A59 /* CAValueFunction.m */, + FE41B88812BEA2EE00ED6C10 /* CATransaction.h */, FEAEF8C111E3B3FF00CA0912 /* CAMediaTimingFunction.h */, FEAEF8C211E3B3FF00CA0912 /* CAMediaTimingFunction.m */, FEF88C2B100CC45B00B15FD7 /* CAAnimation.h */, @@ -411,6 +421,10 @@ FEAEF82311E3AB6A00CA0912 /* CoreAnimation.h in Headers */, FEAEF85E11E3AFEF00CA0912 /* CAMediaTiming.h in Headers */, FEAEF8C311E3B3FF00CA0912 /* CAMediaTimingFunction.h in Headers */, + FE41B88912BEA2EE00ED6C10 /* CATransaction.h in Headers */, + FEDEAA6812C2608F008E5A59 /* CAValueFunction.h in Headers */, + FEDEABC112C98F59008E5A59 /* CALayerContext.h in Headers */, + FEDEB74012D2378C008E5A59 /* CAAction.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -440,6 +454,10 @@ FEAEF82511E3AB6A00CA0912 /* CoreAnimation.h in Headers */, FEAEF86011E3AFEF00CA0912 /* CAMediaTiming.h in Headers */, FEAEF8C711E3B3FF00CA0912 /* CAMediaTimingFunction.h in Headers */, + FE41B88B12BEA2EE00ED6C10 /* CATransaction.h in Headers */, + FEDEAA6C12C2608F008E5A59 /* CAValueFunction.h in Headers */, + FEDEABC312C98F59008E5A59 /* CALayerContext.h in Headers */, + FEDEB74212D2378C008E5A59 /* CAAction.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -469,6 +487,10 @@ FEAEF82411E3AB6A00CA0912 /* CoreAnimation.h in Headers */, FEAEF85F11E3AFEF00CA0912 /* CAMediaTiming.h in Headers */, FEAEF8C511E3B3FF00CA0912 /* CAMediaTimingFunction.h in Headers */, + FE41B88A12BEA2EE00ED6C10 /* CATransaction.h in Headers */, + FEDEAA6A12C2608F008E5A59 /* CAValueFunction.h in Headers */, + FEDEABC212C98F59008E5A59 /* CALayerContext.h in Headers */, + FEDEB74112D2378C008E5A59 /* CAAction.h in Headers */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -546,7 +568,14 @@ isa = PBXProject; buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "QuartzCore" */; compatibilityVersion = "Xcode 3.1"; + developmentRegion = English; hasScannedForEncodings = 1; + knownRegions = ( + English, + Japanese, + French, + German, + ); mainGroup = 0867D691FE84028FC02AAC07 /* QuartzCore */; productRefGroup = 034768DFFF38A50411DB9C8B /* Products */; projectDirPath = ""; @@ -636,12 +665,6 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - FEAEF7EA11E3AAD000CA0912 /* CAAnimationGroup.m in Sources */, - FEAEF7EC11E3AAD000CA0912 /* CABasicAnimation.m in Sources */, - FEAEF7EE11E3AAD000CA0912 /* CAPropertyAnimation.m in Sources */, - FEAEF7F011E3AAD000CA0912 /* CATransition.m in Sources */, - FEAEF7F111E3AAD000CA0912 /* CIAffineTransform.m in Sources */, - FEAEF8C411E3B3FF00CA0912 /* CAMediaTimingFunction.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -649,12 +672,6 @@ isa = PBXSourcesBuildPhase; buildActionMask = 2147483647; files = ( - FEAEF7F311E3AAD000CA0912 /* CAAnimationGroup.m in Sources */, - FEAEF7F511E3AAD000CA0912 /* CABasicAnimation.m in Sources */, - FEAEF7F711E3AAD000CA0912 /* CAPropertyAnimation.m in Sources */, - FEAEF7F911E3AAD000CA0912 /* CATransition.m in Sources */, - FEAEF7FA11E3AAD000CA0912 /* CIAffineTransform.m in Sources */, - FEAEF8C611E3B3FF00CA0912 /* CAMediaTimingFunction.m in Sources */, ); runOnlyForDeploymentPostprocessing = 0; };