diff --git a/SwiftProject/SwiftProject.xcodeproj/project.pbxproj b/SwiftProject/SwiftProject.xcodeproj/project.pbxproj
index 379e3bc..cd8bf24 100644
--- a/SwiftProject/SwiftProject.xcodeproj/project.pbxproj
+++ b/SwiftProject/SwiftProject.xcodeproj/project.pbxproj
@@ -841,17 +841,17 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
- CURRENT_PROJECT_VERSION = 1.3;
+ CURRENT_PROJECT_VERSION = 1.4;
DEVELOPMENT_TEAM = 8DQD6BV6H9;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = SwiftProject/Info.plist;
- INFOPLIST_KEY_CFBundleDisplayName = VPro;
+ INFOPLIST_KEY_CFBundleDisplayName = VPCamera;
INFOPLIST_KEY_NSCameraUsageDescription = "Please allow the app to access your camera to capture the pictures, videos, or avatars you want to upload";
INFOPLIST_KEY_NSMicrophoneUsageDescription = "The app requires your consent to access the microphone";
INFOPLIST_KEY_NSPhotoLibraryAddUsageDescription = "Please allow the app to access your photos for selecting photos, setting up avatars, uploading and publishing photos, and more.";
INFOPLIST_KEY_NSPhotoLibraryUsageDescription = "Please allow the app to access your photos for selecting photos, setting up avatars, uploading and publishing photos, and more.";
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
- INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen;
+ INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen.storyboard;
INFOPLIST_KEY_UIMainStoryboardFile = Main;
INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
@@ -882,17 +882,17 @@
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
- CURRENT_PROJECT_VERSION = 1.3;
+ CURRENT_PROJECT_VERSION = 1.4;
DEVELOPMENT_TEAM = 8DQD6BV6H9;
GENERATE_INFOPLIST_FILE = YES;
INFOPLIST_FILE = SwiftProject/Info.plist;
- INFOPLIST_KEY_CFBundleDisplayName = VPro;
+ INFOPLIST_KEY_CFBundleDisplayName = VPCamera;
INFOPLIST_KEY_NSCameraUsageDescription = "Please allow the app to access your camera to capture the pictures, videos, or avatars you want to upload";
INFOPLIST_KEY_NSMicrophoneUsageDescription = "The app requires your consent to access the microphone";
INFOPLIST_KEY_NSPhotoLibraryAddUsageDescription = "Please allow the app to access your photos for selecting photos, setting up avatars, uploading and publishing photos, and more.";
INFOPLIST_KEY_NSPhotoLibraryUsageDescription = "Please allow the app to access your photos for selecting photos, setting up avatars, uploading and publishing photos, and more.";
INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES;
- INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen;
+ INFOPLIST_KEY_UILaunchStoryboardName = LaunchScreen.storyboard;
INFOPLIST_KEY_UIMainStoryboardFile = Main;
INFOPLIST_KEY_UISupportedInterfaceOrientations = UIInterfaceOrientationPortrait;
INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown";
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/Contents.json b/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/Contents.json
index 6065330..6d6ef0a 100644
--- a/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/Contents.json
+++ b/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/Contents.json
@@ -1,7 +1,7 @@
{
"images" : [
{
- "filename" : "iOS App Icon.png",
+ "filename" : "icon@1x.png",
"idiom" : "universal",
"platform" : "ios",
"size" : "1024x1024"
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/iOS App Icon.png b/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/iOS App Icon.png
deleted file mode 100644
index 6dc29f3..0000000
Binary files a/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/iOS App Icon.png and /dev/null differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/icon@1x.png b/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/icon@1x.png
new file mode 100644
index 0000000..45cd00b
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/AppIcon.appiconset/icon@1x.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/Start.imageset/Start.png b/SwiftProject/SwiftProject/Assets.xcassets/Start.imageset/Start.png
deleted file mode 100644
index 70fc80c..0000000
Binary files a/SwiftProject/SwiftProject/Assets.xcassets/Start.imageset/Start.png and /dev/null differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Contents.json b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Contents.json
index 8600baf..01691ab 100644
--- a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Contents.json
+++ b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Contents.json
@@ -5,12 +5,12 @@
"scale" : "1x"
},
{
- "filename" : "Frame_1171276035@2x.png",
+ "filename" : "home@2x.png",
"idiom" : "universal",
"scale" : "2x"
},
{
- "filename" : "Frame_1171276035@3x.png",
+ "filename" : "home@3x.png",
"idiom" : "universal",
"scale" : "3x"
}
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Frame_1171276035@2x.png b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Frame_1171276035@2x.png
deleted file mode 100644
index 7fab7a8..0000000
Binary files a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Frame_1171276035@2x.png and /dev/null differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Frame_1171276035@3x.png b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Frame_1171276035@3x.png
deleted file mode 100644
index e413566..0000000
Binary files a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/Frame_1171276035@3x.png and /dev/null differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/home@2x.png b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/home@2x.png
new file mode 100644
index 0000000..eea274d
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/home@2x.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/home@3x.png b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/home@3x.png
new file mode 100644
index 0000000..ad9a3b1
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/home/Frame_1171276035.imageset/home@3x.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/Contents.json b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/Contents.json
new file mode 100644
index 0000000..fa08b22
--- /dev/null
+++ b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/Contents.json
@@ -0,0 +1,23 @@
+{
+ "images" : [
+ {
+ "filename" : "start3.png",
+ "idiom" : "universal",
+ "scale" : "1x"
+ },
+ {
+ "filename" : "start3 1.png",
+ "idiom" : "universal",
+ "scale" : "2x"
+ },
+ {
+ "filename" : "start3 2.png",
+ "idiom" : "universal",
+ "scale" : "3x"
+ }
+ ],
+ "info" : {
+ "author" : "xcode",
+ "version" : 1
+ }
+}
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3 1.png b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3 1.png
new file mode 100644
index 0000000..79ff79e
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3 1.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3 2.png b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3 2.png
new file mode 100644
index 0000000..79ff79e
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3 2.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3.png b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3.png
new file mode 100644
index 0000000..79ff79e
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/loading.imageset/start3.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/Contents.json b/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/Contents.json
index 5f670ca..e082eff 100644
--- a/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/Contents.json
+++ b/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/Contents.json
@@ -1,7 +1,7 @@
{
"images" : [
{
- "filename" : "logo.png",
+ "filename" : "icon@1x.png",
"idiom" : "universal",
"scale" : "1x"
},
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/icon@1x.png b/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/icon@1x.png
new file mode 100644
index 0000000..45cd00b
Binary files /dev/null and b/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/icon@1x.png differ
diff --git a/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/logo.png b/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/logo.png
deleted file mode 100644
index 503f62f..0000000
Binary files a/SwiftProject/SwiftProject/Assets.xcassets/logo.imageset/logo.png and /dev/null differ
diff --git a/SwiftProject/SwiftProject/Base.lproj/LaunchScreen.storyboard b/SwiftProject/SwiftProject/Base.lproj/LaunchScreen.storyboard
index 876e647..a023a43 100644
--- a/SwiftProject/SwiftProject/Base.lproj/LaunchScreen.storyboard
+++ b/SwiftProject/SwiftProject/Base.lproj/LaunchScreen.storyboard
@@ -16,17 +16,17 @@
-
+
-
-
-
-
+
+
+
+
@@ -36,7 +36,7 @@
-
+
diff --git a/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialPhotoDisplayController.swift b/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialPhotoDisplayController.swift
index 318828b..0ea4536 100644
--- a/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialPhotoDisplayController.swift
+++ b/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialPhotoDisplayController.swift
@@ -25,7 +25,7 @@ class CCSpatialPhotoDisplayController: BaseController {
var player:AVPlayer = AVPlayer()
var outputVideoURL:URL?
-
+ var dvc:UIDocumentViewController?
//图片源数据
var photoOriginalURL:URL?
@@ -142,12 +142,6 @@ class CCSpatialPhotoDisplayController: BaseController {
super.viewDidLoad()
self.view.backgroundColor = UIColor(hexString: "#060507")
- // Do any additional setup after loading the view.
-
-
-
- // let path = Bundle.main.path(forResource: "img3", ofType: "HEIC")
- // photoOriginalURL = URL.init(filePath: path!)
outputVideoURL = URL.documentsDirectory.appending(path:"output11114.jpg")
//获取图片源数据
@@ -168,6 +162,12 @@ class CCSpatialPhotoDisplayController: BaseController {
image = image?.getUpImg()
mImgView.image = image
+// dvc = UIDocumentViewController()
+// self.addChild(dvc!)
+// self.view.addSubview(dvc!.view)
+// var uidc = UIDocument(fileURL: URL(string: "https://nimg.ws.126.net/?url=http%3A%2F%2Fdingyue.ws.126.net%2F2024%2F0208%2F17870067j00s8iidm0066d000xc00mzp.jpg&thumbnail=660x2147483647&quality=80&type=jpg")!)
+// dvc?.document = uidc
+
let isSpatial = isSpatialImage(originalData: originalData!)
if !isSpatial {
print("这不是一张空间图片")
@@ -224,28 +224,15 @@ class CCSpatialPhotoDisplayController: BaseController {
func selectedSpatialType(selectedIndex:Int) {
// 处理分段选择器值改变事件
- /*
- let popData = [/*(icon:"saoyisao",title:"扫一扫"),*/
- (icon:"",title:"单眼2D",isHiden:true),
- (icon:"",title:"平行眼",isHiden:false),
- (icon:"",title:"红蓝立体",isHiden:false),
- (icon:"",title:"交叉眼",isHiden:false)]
-
- */
-
print("选中了第 \(selectedIndex) 个选项")
player.pause()
NotificationCenter.default.removeObserver(self)
mImgView.frame = CGRect.init(x: 0, y: 200, width: self.view.frame.size.width, height: 240)
-
- // guard let imageSource = CGImageSourceCreateWithURL(photoOriginalURL! as CFURL, nil) else {
- // return
- // }
+
guard let imageSource = CGImageSourceCreateWithData(imgData! as CFData, nil) else {
return
}
-
- // print(imageSource)
+
let frameCount = CGImageSourceGetCount(imageSource)
var frames: [CGImage] = []
for index in 0.. Bool {
-
-
//通过data获取
guard let imageSource = CGImageSourceCreateWithData(originalData as CFData, nil) else {
return false
}
//通过url获取
- // guard let imageSource = CGImageSourceCreateWithURL(imageURL as CFURL, nil) else {
- // return false
- // }
guard let properties = CGImageSourceCopyPropertiesAtIndex(imageSource, 1, nil) as? [CFString: Any] else {
return false
}
print(properties)
-
- //这里判断两张图片,gif也可能是两张
- // let frameCount = CGImageSourceGetCount(imageSource)
- // if(frameCount == 1){
- // return false
- // }
return true
}
diff --git a/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialShootController.swift b/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialShootController.swift
index 2a3fd0c..cbec652 100644
--- a/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialShootController.swift
+++ b/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialShootController.swift
@@ -642,10 +642,10 @@ class CCSpatialShootController: BaseController {
@objc func shutterVideoButtonAction(_ sender: UIButton){
if !self.isRecording {
//判断设备方向,如果不是横屏left\right,则不允许录制
- if imageOrientation != .right ||
- imageOrientation != .left {
- return
- }
+// if imageOrientation != .right ||
+// imageOrientation != .left {
+// return
+// }
//录像中
print("录像中...")
@@ -1067,7 +1067,7 @@ extension CCSpatialShootController: AVCaptureFileOutputRecordingDelegate {
let img1:UIImage = imgs[0] as! UIImage
let img2:UIImage = imgs[1] as! UIImage
- let url = URL.documentsDirectory.appending(path:".HEIC")
+ let url = URL.documentsDirectory.appending(path:"aaa12.HEIC")
let destination = CGImageDestinationCreateWithURL(url as CFURL, UTType.heic.identifier as CFString, 2, nil)!
imageCGImagePropertyOrientation = .left
let properties1 = [
diff --git a/SwiftProject/SwiftProject/Project/View/CCMineView.swift b/SwiftProject/SwiftProject/Project/View/CCMineView.swift
index 750a0f1..4334553 100644
--- a/SwiftProject/SwiftProject/Project/View/CCMineView.swift
+++ b/SwiftProject/SwiftProject/Project/View/CCMineView.swift
@@ -53,7 +53,7 @@ class CCMineView: UIView,UITableViewDelegate,UITableViewDataSource{
mLabel!.textColor = UIColor.white
mLabel!.font = UIFont.systemFont(ofSize: 16)
self.addSubview(mLabel!)
- mLabel!.text = "VPro"
+ mLabel!.text = "VPCamera"
mLabel!.sizeToFit()
mLabel!.centerY = mImgView!.centerY
mLabel!.left = mImgView!.right + 15