iOS UIImageView
来源:互联网 发布:和知乎类似的网站 编辑:程序博客网 时间:2024/05/17 05:19
//获取本地图片
UIImageView *imgV=[[UIImageView alloc]initWithFrame:self.view.frame];
UIImage *imge=[UIImage imageNamed:@"456.jpg"];
imgV.image=imge;
[self.view addSubview:imgV];
//获取网络图片
NSString *urlString=@"http://pic2.ooopic.com/01/03/51/25b1OOOPIC19.jpg";
//将网址字符串转换成url
NSURL *url=[NSURL URLWithString:urlString];
//将url转化成data类型
NSData *urldata=[NSData dataWithContentsOfURL:url];
UIImage *inmagenow=[UIImage imageWithData:urldata];
UIImageView *imagenowV=[[UIImageView alloc]initWithFrame:CGRectMake(0, 0, 750/2, 1334/2)];
imagenowV.image=inmagenow;
[self.view addSubview:imagenowV];
0 0
- iOS-UIImageView
- IOS UIImageView
- IOS-UIImageView
- IOS-UIImageView
- IOS UIImageView
- iOS UIImageView
- IOS-UIImageView
- iOS开发-UIImageView
- iOS UIImageview 点击事件
- IOS UIImageView 点击手势
- [iOS]UIImageView动画相关
- [IOS]UIImageView满屏/还原
- [IOS]UIImageView动画
- iOS中UIImageview笔记
- ios--UIImageView用法
- iOS- UIImageView/手势识别
- iOS UIImageView 大小调整
- iOS UIImageView 圆角
- 数据段描述符和代码段描述符(二)——《x86汇编语言:从实模式到保护模式》读书笔记11
- 53. Maximum Subarray
- iOS nsdate
- window下使用sratoolkit将sra文件转换成fastq
- java常用集合总结
- iOS UIImageView
- 198,自定义UITableViewCell(一)
- shells
- LeetCode OJ - Letter Combinations of a Phone Number
- TEST
- HDOJ 1994-利息计算
- 接口性能优化
- 实现应用Matrix缩放图像
- Android点击除键盘外的其他区域隐藏键盘