注释无效代码和调整部分逻辑,浏览图片
This commit is contained in:
parent
b176c459c2
commit
c2268c7228
Binary file not shown.
@ -14,8 +14,8 @@
|
||||
filePath = "SwiftProject/Project/Controller/CCHomeController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "584"
|
||||
endingLineNumber = "584"
|
||||
startingLineNumber = "593"
|
||||
endingLineNumber = "593"
|
||||
landmarkName = "imagePickerController(_:didFinishPickingMediaWithInfo:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@ -30,8 +30,8 @@
|
||||
filePath = "SwiftProject/Project/Controller/CCHomeController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "576"
|
||||
endingLineNumber = "576"
|
||||
startingLineNumber = "585"
|
||||
endingLineNumber = "585"
|
||||
landmarkName = "imagePickerController(_:didFinishPickingMediaWithInfo:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@ -94,8 +94,8 @@
|
||||
filePath = "SwiftProject/Project/Controller/CCHomeController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "540"
|
||||
endingLineNumber = "540"
|
||||
startingLineNumber = "549"
|
||||
endingLineNumber = "549"
|
||||
landmarkName = "photoLibrary()"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@ -339,8 +339,8 @@
|
||||
filePath = "SwiftProject/Project/View/Album/CCSpaceAlbumFliterPopView/CCSpaceAlbumFilterPopView2.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "365"
|
||||
endingLineNumber = "365"
|
||||
startingLineNumber = "366"
|
||||
endingLineNumber = "366"
|
||||
landmarkName = "loadMoreData(offset:)"
|
||||
landmarkType = "7">
|
||||
<Locations>
|
||||
@ -393,84 +393,6 @@
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
uuid = "742F2A13-D3B1-41EF-8BDA-BE012155DB3C"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "SwiftProject/Project/Util/ZZHImageExtension.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "90"
|
||||
endingLineNumber = "90"
|
||||
landmarkName = "getRotateFrom(_:)"
|
||||
landmarkType = "7">
|
||||
<Locations>
|
||||
<Location
|
||||
uuid = "742F2A13-D3B1-41EF-8BDA-BE012155DB3C - bb01223bea0e003"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
symbolName = "__C.UIImage.getRotateFrom(__C.UIImageOrientation) -> CoreGraphics.CGFloat"
|
||||
moduleName = "SwiftProject"
|
||||
usesParentBreakpointCondition = "Yes"
|
||||
urlString = "file:///Users/aaa/Documents/IOS%20Dev/VR/SwiftProject/SwiftProject/Project/Util/ZZHImageExtension.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "81"
|
||||
endingLineNumber = "81"
|
||||
offsetFromSymbolStart = "636">
|
||||
</Location>
|
||||
<Location
|
||||
uuid = "742F2A13-D3B1-41EF-8BDA-BE012155DB3C - bb01223bea0e003"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
symbolName = "__C.UIImage.getRotateFrom(__C.UIImageOrientation) -> CoreGraphics.CGFloat"
|
||||
moduleName = "SwiftProject"
|
||||
usesParentBreakpointCondition = "Yes"
|
||||
urlString = "file:///Users/aaa/Documents/IOS%20Dev/VR/SwiftProject/SwiftProject/Project/Util/ZZHImageExtension.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "81"
|
||||
endingLineNumber = "81"
|
||||
offsetFromSymbolStart = "616">
|
||||
</Location>
|
||||
<Location
|
||||
uuid = "742F2A13-D3B1-41EF-8BDA-BE012155DB3C - bb01223bea0e145"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
symbolName = "__C.UIImage.getRotateFrom(__C.UIImageOrientation) -> CoreGraphics.CGFloat"
|
||||
moduleName = "SwiftProject"
|
||||
usesParentBreakpointCondition = "Yes"
|
||||
urlString = "file:///Users/aaa/Documents/IOS%20Dev/VR/SwiftProject/SwiftProject/Project/Util/ZZHImageExtension.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "87"
|
||||
endingLineNumber = "87"
|
||||
offsetFromSymbolStart = "616">
|
||||
</Location>
|
||||
<Location
|
||||
uuid = "742F2A13-D3B1-41EF-8BDA-BE012155DB3C - bb01223bea0e6d8"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
symbolName = "__C.UIImage.getRotateFrom(__C.UIImageOrientation) -> CoreGraphics.CGFloat"
|
||||
moduleName = "SwiftProject"
|
||||
usesParentBreakpointCondition = "Yes"
|
||||
urlString = "file:///Users/aaa/Documents/IOS%20Dev/VR/SwiftProject/SwiftProject/Project/Util/ZZHImageExtension.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "90"
|
||||
endingLineNumber = "90"
|
||||
offsetFromSymbolStart = "616">
|
||||
</Location>
|
||||
</Locations>
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
@ -529,8 +451,8 @@
|
||||
filePath = "SwiftProject/Project/View/Album/CCSpaceAlbumFliterPopView/CCSpaceAlbumFilterPopView2.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "459"
|
||||
endingLineNumber = "459"
|
||||
startingLineNumber = "460"
|
||||
endingLineNumber = "460"
|
||||
landmarkName = "collectionView(_:cellForItemAt:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@ -545,8 +467,8 @@
|
||||
filePath = "SwiftProject/Project/Controller/RecordingVideo/CCSpatialVideoDisplayController/CCSpatialVideoDisplayController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "373"
|
||||
endingLineNumber = "373"
|
||||
startingLineNumber = "375"
|
||||
endingLineNumber = "375"
|
||||
landmarkName = "notification_didActiveNotification(notification:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
@ -641,8 +563,8 @@
|
||||
filePath = "SwiftProject/Project/Controller/RecordingVideo/CCSpatialVideoDisplayController/ZZHCustomSlider.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "266"
|
||||
endingLineNumber = "266"
|
||||
startingLineNumber = "267"
|
||||
endingLineNumber = "267"
|
||||
landmarkName = "touchesCancelled(_:with:)"
|
||||
landmarkType = "7">
|
||||
<Locations>
|
||||
@ -676,6 +598,21 @@
|
||||
endingLineNumber = "266"
|
||||
offsetFromSymbolStart = "560">
|
||||
</Location>
|
||||
<Location
|
||||
uuid = "91D72EA1-7A61-4702-B30F-5B860A817DC7 - f5a1762b3e6912f6"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
symbolName = "SwiftProject.CCSlider.touchesCancelled(_: Swift.Set<__C.UITouch>, with: Swift.Optional<__C.UIEvent>) -> ()"
|
||||
moduleName = "SwiftProject"
|
||||
usesParentBreakpointCondition = "Yes"
|
||||
urlString = "file:///Users/aaa/Documents/IOS%20Dev/VR/SwiftProject/SwiftProject/Project/Controller/RecordingVideo/CCSpatialVideoDisplayController/ZZHCustomSlider.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "267"
|
||||
endingLineNumber = "267"
|
||||
offsetFromSymbolStart = "560">
|
||||
</Location>
|
||||
</Locations>
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
@ -695,5 +632,37 @@
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
uuid = "A1C134FD-F27C-4C32-9835-E1C81C6ADB12"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "SwiftProject/Project/Controller/RecordingVideo/CCSpatialVideoDisplayController/CCSpatialVideoDisplayController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "619"
|
||||
endingLineNumber = "619"
|
||||
landmarkName = "navgationButtonClick2(sender:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
<BreakpointProxy
|
||||
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
|
||||
<BreakpointContent
|
||||
uuid = "C570719E-63A4-43FF-B822-56E182D55F24"
|
||||
shouldBeEnabled = "Yes"
|
||||
ignoreCount = "0"
|
||||
continueAfterRunningActions = "No"
|
||||
filePath = "SwiftProject/Project/Controller/RecordingVideo/CCSpatialVideoDisplayController/CCSpatialVideoDisplayController.swift"
|
||||
startingColumnNumber = "9223372036854775807"
|
||||
endingColumnNumber = "9223372036854775807"
|
||||
startingLineNumber = "657"
|
||||
endingLineNumber = "657"
|
||||
landmarkName = "selectedSpatialType(selectedIndex:)"
|
||||
landmarkType = "7">
|
||||
</BreakpointContent>
|
||||
</BreakpointProxy>
|
||||
</Breakpoints>
|
||||
</Bucket>
|
||||
|
||||
@ -491,8 +491,13 @@ class CCSpatialPhotoDisplayController: BaseController {
|
||||
// 处理分段选择器值改变事件
|
||||
currentSpatialType = selectedIndex
|
||||
// print("选中了第 \(selectedIndex) 个选项")
|
||||
// mImgView.frame = CGRect.init(x: 0, y: 200, width: self.view.frame.size.width, height: 240)
|
||||
|
||||
if(selectedIndex == 1){
|
||||
//空间照片 --- 单眼2D(展示原照片或者广角或者主摄其中一个)
|
||||
let image = UIImage(data: photoOriginalData!)
|
||||
mImgView.image = monocular2DImgWith(drawImg: image!, scale: currentScale)
|
||||
|
||||
}else {
|
||||
guard let imageSource = CGImageSourceCreateWithData(imgData! as CFData, nil) else {
|
||||
return
|
||||
}
|
||||
@ -509,20 +514,12 @@ class CCSpatialPhotoDisplayController: BaseController {
|
||||
if(frames.count < 2){return}
|
||||
let lciImage = CIImage(cgImage: frames.first!)
|
||||
let rciImage = CIImage(cgImage: frames[1])
|
||||
|
||||
if(selectedIndex == 1){
|
||||
//空间照片 --- 单眼2D(展示原照片或者广角或者主摄其中一个)
|
||||
let image = UIImage(data: photoOriginalData!)
|
||||
mImgView.image = monocular2DImgWith(drawImg: image!, scale: currentScale)
|
||||
|
||||
}else if(selectedIndex == 0){
|
||||
if(selectedIndex == 0){
|
||||
//平行眼
|
||||
|
||||
let newpb = joinImages(leftImage: lciImage, rightImage: rciImage, scale: currentScale, ed: currentED)
|
||||
let lastImg = UIImage(ciImage: newpb)
|
||||
// DispatchQueue.main.async { [weak self] in
|
||||
self.mImgView.image = lastImg
|
||||
// }
|
||||
|
||||
}else if(selectedIndex == 2){
|
||||
|
||||
@ -536,9 +533,8 @@ class CCSpatialPhotoDisplayController: BaseController {
|
||||
//交叉眼
|
||||
let newpb = joinImages(leftImage: rciImage , rightImage:lciImage , scale: currentScale, ed: currentED)
|
||||
let lastImg = UIImage(ciImage: newpb)
|
||||
// DispatchQueue.main.async { [weak self] in
|
||||
self.mImgView.image = lastImg
|
||||
// }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -222,10 +222,10 @@ extension CCSpatialPhotoDisplayController {
|
||||
func getImgWithED(image:UIImage,drawImgWidth:CGFloat,drawSize:CGSize) -> (UIImage,CGSize) {
|
||||
if drawSize.width <= drawImgWidth {
|
||||
|
||||
print("瞳距返回,不用处理")
|
||||
// print("瞳距返回,不用处理")
|
||||
return (image,drawSize)
|
||||
}
|
||||
print("瞳距要处理")
|
||||
// print("瞳距要处理")
|
||||
let newImageWidth = drawImgWidth * image.size.height / drawSize.height
|
||||
let dRect = CGRectMake((image.size.width - newImageWidth) * 0.5, 0, newImageWidth, image.size.height)
|
||||
let newImage = image.imageAtRect(rect: dRect)
|
||||
|
||||
@ -23,7 +23,7 @@ extension UIImage {
|
||||
let final = EXImageContext.createCGImage(imageRef, from:imageRef.extent)
|
||||
return UIImage(cgImage: final!)
|
||||
}
|
||||
print("cgimage.....>>>>>>>>>>>>>.")
|
||||
// print("cgimage.....>>>>>>>>>>>>>.")
|
||||
let imageRef = cgImage.cropping(to: rect)
|
||||
return imageRef == nil ? nil : UIImage(cgImage: imageRef!)
|
||||
}
|
||||
@ -80,7 +80,7 @@ extension UIImage {
|
||||
}
|
||||
|
||||
func getRotateFrom(_ imgOrigOritentation:UIImage.Orientation) ->CGFloat {
|
||||
print("..or:\(imgOrigOritentation.rawValue)")
|
||||
// print("..or:\(imgOrigOritentation.rawValue)")
|
||||
if imgOrigOritentation == .left {
|
||||
return -.pi/2
|
||||
} else if imgOrigOritentation == .right{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user