# 3d登陆界面 **Repository Path**: xrz_admin/threeDLogin ## Basic Information - **Project Name**: 3d登陆界面 - **Description**: 登陆界面,支持3d翻转切换 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 4 - **Created**: 2020-10-08 - **Last Updated**: 2022-05-25 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 功能 实现登陆界面从一种登陆方式切换到另一种方式,切换过程采用3D旋转. # 效果图 ![](https://images.gitee.com/uploads/images/2020/0717/144338_2c8e1826_1013055.gif) # 简要代码 ```kotlin class MainActivity : AppCompatActivity() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) setContentView(R.layout.activity_main) val rotate = Rotate3D.Builder(this) .setParentView(parent_ll) .setPositiveView(accountLoginLayout) .setNegativeView(phoneLoginLayout) .create() noPassLoginTv.setOnClickListener { rotate.transform() //启动Rotate3D if (rotate.isOpen) { noPassLoginTv.text = "使用免密登录" } else { noPassLoginTv.text = "使用账户登录" } } } } ``` # 完整源代码 [https://gitee.com/cxyzy1/threeDLogin](https://gitee.com/cxyzy1/threeDLogin) 关注头条号,第一时间获取最新文章: ![](https://images.gitee.com/uploads/images/2020/0717/144339_b1f525f0_1013055.png)