|
@@ -120,6 +120,15 @@ enum TSGeneratorImageStyle {
|
|
|
return .catTohumanConfig
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
+ var advance:Bool{
|
|
|
+ switch self {
|
|
|
+ case .catTohuman,.motherDay:
|
|
|
+ return true
|
|
|
+ default:
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
class TSAIUploadPhotoBaseVC: TSBaseVC {
|
|
@@ -181,6 +190,12 @@ class TSAIUploadPhotoBaseVC: TSBaseVC {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+ lazy var subInfoLabel: UILabel = {
|
|
|
+ let textLabel = UILabel.createLabel(text: "Select an image with face fully visible".localized,font: .font(size: 12),textColor: UIColor.white.withAlphaComponent(0.6))
|
|
|
+ return textLabel
|
|
|
+ }()
|
|
|
+
|
|
|
lazy var upLoadView: UIView = {
|
|
|
let bgView = UIView()
|
|
|
|
|
@@ -197,6 +212,12 @@ class TSAIUploadPhotoBaseVC: TSBaseVC {
|
|
|
textLabel.snp.makeConstraints { make in
|
|
|
make.top.equalTo(addImageView.snp.bottom).offset(16)
|
|
|
make.centerX.equalToSuperview()
|
|
|
+ }
|
|
|
+
|
|
|
+ bgView.addSubview(subInfoLabel)
|
|
|
+ subInfoLabel.snp.makeConstraints { make in
|
|
|
+ make.top.equalTo(textLabel.snp.bottom).offset(8)
|
|
|
+ make.centerX.equalToSuperview()
|
|
|
make.bottom.equalToSuperview()
|
|
|
}
|
|
|
|
|
@@ -266,13 +287,13 @@ class TSAIUploadPhotoBaseVC: TSBaseVC {
|
|
|
segmentedView.addTarget(self,action: #selector(segmentedControlValueChanged(_:)),for: .valueChanged)
|
|
|
return segmentedView
|
|
|
}()
|
|
|
- var additionalPrompt = "male"
|
|
|
+ var additionalPrompt = "female"
|
|
|
@objc func segmentedControlValueChanged(_ sender: BetterSegmentedControl) {
|
|
|
switch sender.index {
|
|
|
case 0:
|
|
|
- additionalPrompt = "male"
|
|
|
+ additionalPrompt = "female"//女
|
|
|
case 1:
|
|
|
- additionalPrompt = "female"
|
|
|
+ additionalPrompt = "male"//男
|
|
|
default:
|
|
|
additionalPrompt = ""
|
|
|
}
|
|
@@ -303,6 +324,8 @@ class TSAIUploadPhotoBaseVC: TSBaseVC {
|
|
|
|
|
|
let image = upLoadImage
|
|
|
upLoadImage = image
|
|
|
+
|
|
|
+ subInfoLabel.isHidden = generatorStyle == .catTohuman ? false : true
|
|
|
}
|
|
|
|
|
|
|
|
@@ -336,7 +359,7 @@ extension TSAIUploadPhotoBaseVC {
|
|
|
}
|
|
|
|
|
|
if generatorStyle == .catTohuman {
|
|
|
- cusStackView.addSpacing(length: 24)
|
|
|
+ cusStackView.addSpacing(length: 9)
|
|
|
cusStackView.addSubviewToStackWhiteBoard(segmentedView, length: 46)
|
|
|
segmentedView.snp.makeConstraints { make in
|
|
|
make.width.equalTo(k_ScreenWidth-70)
|