@ -0,0 +1,93 @@ | 
				
			||||
<template> | 
				
			||||
	<view> | 
				
			||||
		<view class="content photo_back" style="background-color: #000;"> | 
				
			||||
			<custom_navbar :title="navbar_title" @getNavHeight="getNavHeight" theme="light" /> | 
				
			||||
			<view class="photo_main" :style="'margin-top:'+margin_top+'px'" style="width:100%;margin-left: 0;"> | 
				
			||||
				<view class="photo_cartoon_2" v-if="loaded && cameraEnable"> | 
				
			||||
 | 
				
			||||
					<camera flash="auto" :device-position="devicePosition" @error="errorCamera" | 
				
			||||
						style="width: 100%; height: 100%;"> | 
				
			||||
					</camera> | 
				
			||||
 | 
				
			||||
				</view> | 
				
			||||
 | 
				
			||||
				<view class="photo_cartoon_2" v-else style="overflow: hidden;"> | 
				
			||||
					<view style="display: flex;justify-content: center;margin-top: 200rpx;overflow:hidden;">请授权使用摄像头 | 
				
			||||
					</view> | 
				
			||||
				</view> | 
				
			||||
 | 
				
			||||
				<view class="photo_cartoon_2_2"> | 
				
			||||
					<view class="photo_cartoon_2_2_1"> | 
				
			||||
						<image src="/static/img/photo/cartoon_4.png" /> | 
				
			||||
					</view> | 
				
			||||
					<view class="photo_cartoon_2_2_2"> | 
				
			||||
						<image src="/static/img/photo/cartoon_3.png" /> | 
				
			||||
					</view> | 
				
			||||
					<view class="photo_cartoon_2_2_1"> | 
				
			||||
						<image src="/static/img/photo/cartoon_5.png" /> | 
				
			||||
					</view> | 
				
			||||
				</view> | 
				
			||||
 | 
				
			||||
			</view> | 
				
			||||
 | 
				
			||||
		</view> | 
				
			||||
 | 
				
			||||
 | 
				
			||||
	</view> | 
				
			||||
</template> | 
				
			||||
 | 
				
			||||
<script> | 
				
			||||
	import custom_navbar from "./components/photo_header.vue"; | 
				
			||||
	export default { | 
				
			||||
		components: { | 
				
			||||
			custom_navbar | 
				
			||||
 | 
				
			||||
		}, | 
				
			||||
		data() { | 
				
			||||
			return { | 
				
			||||
				navbar_title: '卡通画风', | 
				
			||||
				margin_top: 0, | 
				
			||||
				loaded: false, | 
				
			||||
				cameraEnable: true, | 
				
			||||
				loop: false, | 
				
			||||
				devicePosition: "back", | 
				
			||||
				use_camera: 1, | 
				
			||||
				cameraContext: {}, | 
				
			||||
			} | 
				
			||||
		}, | 
				
			||||
 | 
				
			||||
		mounted() { | 
				
			||||
			setTimeout(() => { | 
				
			||||
				this.loaded = true; | 
				
			||||
				this.loopGetCameraInfo(); | 
				
			||||
			}, 500); | 
				
			||||
		}, | 
				
			||||
		onShow() { | 
				
			||||
			if (this.loaded && !this.loop) { | 
				
			||||
				// 轮询当前相机权限状态,当用户授权则将cameraEnable设置为true | 
				
			||||
				this.loopGetCameraInfo(); | 
				
			||||
			} | 
				
			||||
		}, | 
				
			||||
		onLoad() { | 
				
			||||
			if (uni.createCameraContext) { | 
				
			||||
				this.cameraContext = uni.createCameraContext() | 
				
			||||
			} else { | 
				
			||||
				// 如果希望用户在最新版本的客户端上体验您的小程序,可以这样子提示 | 
				
			||||
				uni.showModal({ | 
				
			||||
					title: '提示', | 
				
			||||
					content: '当前微信版本过低,无法使用该功能,请升级到最新微信版本后重试。' | 
				
			||||
				}) | 
				
			||||
			} | 
				
			||||
		}, | 
				
			||||
		methods: { | 
				
			||||
 | 
				
			||||
			getNavHeight(e) { | 
				
			||||
				this.margin_top += e; | 
				
			||||
			}, | 
				
			||||
		} | 
				
			||||
	} | 
				
			||||
</script> | 
				
			||||
 | 
				
			||||
<style lang="scss" scoped> | 
				
			||||
	@import './this.scss'; | 
				
			||||
</style> | 
				
			||||
@ -0,0 +1,60 @@ | 
				
			||||
<template> | 
				
			||||
	<view> | 
				
			||||
		<view class="content photo_back" style="background-color: #000;"> | 
				
			||||
			<custom_navbar :title="navbar_title" @getNavHeight="getNavHeight" theme="light" /> | 
				
			||||
			<view class="photo_main" :style="'margin-top:'+margin_top+'px'" style="width:100%;margin-left: 0;"> | 
				
			||||
				<view class="photo_cartoon_2"> | 
				
			||||
					<image | 
				
			||||
						src="https://img30.360buyimg.com/sku/jfs/t1/221254/4/39390/74349/661e039aF46114279/48532008a0001dd0.jpg" | 
				
			||||
						mode="aspectFill" /> | 
				
			||||
				</view> | 
				
			||||
				 | 
				
			||||
				<view class="photo_cartoon_3_2"> | 
				
			||||
					<view class="photo_cartoon_3_2_1 photo_full_blue_btn">提交生成</view> | 
				
			||||
					<view class="photo_cartoon_3_2_2">剩余生成次数 <text style="color: #7A74F0;">1</text>/30</view> | 
				
			||||
				</view> | 
				
			||||
 | 
				
			||||
			</view> | 
				
			||||
 | 
				
			||||
		</view> | 
				
			||||
 | 
				
			||||
 | 
				
			||||
	</view> | 
				
			||||
</template> | 
				
			||||
 | 
				
			||||
<script> | 
				
			||||
	import custom_navbar from "./components/photo_header.vue"; | 
				
			||||
	export default { | 
				
			||||
		components: { | 
				
			||||
			custom_navbar | 
				
			||||
 | 
				
			||||
		}, | 
				
			||||
		data() { | 
				
			||||
			return { | 
				
			||||
				navbar_title: '卡通画风', | 
				
			||||
				margin_top: 0, | 
				
			||||
				 | 
				
			||||
			} | 
				
			||||
		}, | 
				
			||||
 | 
				
			||||
		mounted() { | 
				
			||||
			 | 
				
			||||
		}, | 
				
			||||
		onShow() { | 
				
			||||
		 | 
				
			||||
		}, | 
				
			||||
		onLoad() { | 
				
			||||
			 | 
				
			||||
		}, | 
				
			||||
		methods: { | 
				
			||||
 | 
				
			||||
			getNavHeight(e) { | 
				
			||||
				this.margin_top += e; | 
				
			||||
			}, | 
				
			||||
		} | 
				
			||||
	} | 
				
			||||
</script> | 
				
			||||
 | 
				
			||||
<style lang="scss" scoped> | 
				
			||||
	@import './this.scss'; | 
				
			||||
</style> | 
				
			||||
@ -0,0 +1,71 @@ | 
				
			||||
<template> | 
				
			||||
	<view> | 
				
			||||
		<view class="content "> | 
				
			||||
			<custom_navbar :title="navbar_title" @getNavHeight="getNavHeight" :theme="theme" /> | 
				
			||||
			<view class="photo_main_face" :style="'margin-top:-'+margin_top+'px'"> | 
				
			||||
				<view class="photo_main_face_head"></view> | 
				
			||||
				<view class="photo_success_1"> | 
				
			||||
					<image src="/static/img/common/photo_c1.png"/> | 
				
			||||
				</view> | 
				
			||||
				<view class="photo_success_2">生成已提交</view> | 
				
			||||
				<view class="photo_success_3"> | 
				
			||||
					<view>目前排队人数较多,请耐心等待</view>  | 
				
			||||
					<view>可去<text>【我的】</text>页面查看生成结果</view> | 
				
			||||
				</view> | 
				
			||||
				<view class="photo_success_4"> | 
				
			||||
					<image src="/static/img/common/photo_c2.png"/> | 
				
			||||
				</view> | 
				
			||||
			</view> | 
				
			||||
 | 
				
			||||
		</view> | 
				
			||||
 | 
				
			||||
 | 
				
			||||
	</view> | 
				
			||||
</template> | 
				
			||||
 | 
				
			||||
<script> | 
				
			||||
	import custom_navbar from "./components/photo_header.vue"; | 
				
			||||
	export default { | 
				
			||||
		components: { | 
				
			||||
			custom_navbar | 
				
			||||
 | 
				
			||||
		}, | 
				
			||||
		data() { | 
				
			||||
			return { | 
				
			||||
				navbar_title: '', | 
				
			||||
				theme: "blue", | 
				
			||||
				margin_top: -7, | 
				
			||||
 | 
				
			||||
 | 
				
			||||
			} | 
				
			||||
		}, | 
				
			||||
 | 
				
			||||
		mounted() { | 
				
			||||
 | 
				
			||||
		}, | 
				
			||||
		onPageScroll(e) { | 
				
			||||
					if (e.scrollTop > 50) { | 
				
			||||
						this.theme = 'white'; | 
				
			||||
				 | 
				
			||||
					} else { | 
				
			||||
				 | 
				
			||||
						this.theme = 'blue'; | 
				
			||||
					} | 
				
			||||
				}, | 
				
			||||
		methods: { | 
				
			||||
 | 
				
			||||
			getNavHeight(e) { | 
				
			||||
				this.margin_top += e; | 
				
			||||
			} | 
				
			||||
 | 
				
			||||
 | 
				
			||||
 | 
				
			||||
		} | 
				
			||||
	} | 
				
			||||
</script> | 
				
			||||
 | 
				
			||||
<style lang="scss" scoped> | 
				
			||||
	@import './this.scss'; | 
				
			||||
 | 
				
			||||
	 | 
				
			||||
</style> | 
				
			||||
| 
		 After Width: | Height: | Size: 4.0 KiB  | 
| 
		 After Width: | Height: | Size: 2.7 KiB  | 
| 
		 After Width: | Height: | Size: 51 KiB  | 
| 
		 After Width: | Height: | Size: 721 KiB  | 
| 
		 After Width: | Height: | Size: 3.7 KiB  | 
| 
		 After Width: | Height: | Size: 1.3 KiB  | 
| 
		 After Width: | Height: | Size: 1.5 KiB  | 
| 
		 After Width: | Height: | Size: 2.6 KiB  |