android中做图片的平铺
16lz
2021-01-26
在android中做图片的平铺需要两步:
1. 美工出图,“根图片”,就是一个小小的图,像这样
好小啊,看不清- -!命名为bg.png
2. 一个xml文件,名为point_bg.xml
内容:<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
android:src="@drawable/point_bg"
android:tileMode="repeat" /> //这里选择平铺模式
然后再view中设置background为point_bg就行了。
更多相关文章
- Android获取assets目录下的文件和图片
- android 使用getDrawable和BitmapFactory.decodeResource加载图
- Android实现异步加载图片 ListView
- Android培训班(22)
- TextView 中显示图片
- android用户界面-组件Widget-网格视图GridView
- 上传多张图片到服务器
- android实现瀑布流加载图片
- Android图片加载之认识bitmap的四种加载方式