本文整理汇总了Java中jp.wasabeef.glide.transformations.ColorFilterTransformation类的典型用法代码示例。如果您正苦于以下问题:Java ColorFilterTransformation类的具体用法?Java ColorFilterTransformation怎么用?Java ColorFilterTransformation使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ColorFilterTransformation类属于jp.wasabeef.glide.transformations包,在下文中一共展示了ColorFilterTransformation类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: showGoodsInfo
import jp.wasabeef.glide.transformations.ColorFilterTransformation; //导入依赖的package包/类
@Override
public void showGoodsInfo(GoodsItem goodsItem) {
phone = goodsItem.getPhone();
username = goodsItem.getUsername();
imageList.clear();
imageList.addAll(goodsItem.getPics());
tvSendtimeLost.setText(goodsItem.getCreated_on());
tvTextLostTitle.setText(goodsItem.getTit());
tvTextLost.setText(goodsItem.getContent());
tvGoodsQuality.setText(goodsItem.getAttr());
ivNumLost.setText(goodsItem.getUsername());
tvGoodsPrice.setText(String.valueOf("¥" + goodsItem.getPrize()));
tvGoodsTel.setText(TextUtils.isEmpty(phone) ? "无联系方式" : phone);
tvGoodsLocation.setText(TextUtils.isEmpty(goodsItem.getAddress()) ? "湖工大" : goodsItem.getAddress());
if (!ListUtils.isEmpty(imageList)) {
Glide
.with(this)
.load(Constants.PICTURE_URL + imageList.get(0))
.skipMemoryCache(true)
.placeholder(R.drawable.blur_plac_min)
.error(R.drawable.blur_plac_min)
.bitmapTransform(new BlurTransformation(context, 100), new ColorFilterTransformation(this, 0x29000000))
.crossFade()
.into(ivBgimage);
adapter.notifyDataSetChanged();
}
}
开发者ID:NICOLITE,项目名称:HutHelper,代码行数:29,代码来源:GoodsInfoActivity.java
示例2: doBusiness
import jp.wasabeef.glide.transformations.ColorFilterTransformation; //导入依赖的package包/类
@Override
protected void doBusiness() {
Toolbar toolbar = (Toolbar) findViewById(R.id.toolbar);
toolbar.setTitle(linksBean.getName());
setSupportActionBar(toolbar);
ActionBar actionBar = getSupportActionBar();
if (actionBar != null) {
actionBar.setDisplayHomeAsUpEnabled(true);
}
toolbar.setNavigationOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
onBackPressed();
}
});
VideoItemAdapter adapter = new VideoItemAdapter(context, linksBean.getVedioList());
adapter.setOnItemClickListener(new VideoItemAdapter.OnItemClickListener() {
@Override
public void onItemClick(View view, int position, long itemId) {
String path = url + linksBean.getVedioList().get(position).getUrl();
if (CommUtil.isWifiConnected(VideoItemActivity.this)) {
startPlay(path);
} else {
showDialog(path);
}
}
});
rlVideoitem.setLayoutManager(new GridLayoutManager(context, 3));
rlVideoitem.setAdapter(adapter);
Glide
.with(activity)
.load(linksBean.getImg())
.skipMemoryCache(true)
.crossFade()
.into(ivVideoitemImg);
Glide
.with(activity)
.load(linksBean.getImg())
.skipMemoryCache(true)
.crossFade()
.bitmapTransform(new BlurTransformation(context, 25),
new ColorFilterTransformation(context, 0x21000000))
.into(ivVideoitemBg);
}
开发者ID:NICOLITE,项目名称:HutHelper,代码行数:47,代码来源:VideoItemActivity.java
示例3: getTransform
import jp.wasabeef.glide.transformations.ColorFilterTransformation; //导入依赖的package包/类
Transformation<Bitmap> getTransform(int position, Context mContext) {
if (position % 19 == 0) {
return new CropCircleTransformation(mContext);
} else if (position % 19 == 1) {
return new RoundedCornersTransformation(mContext, 30, 0,
RoundedCornersTransformation.CornerType.BOTTOM);
} else if (position % 19 == 2) {
return new CropTransformation(mContext, 300, 100, CropTransformation.CropType.BOTTOM);
} else if (position % 19 == 3) {
return new CropSquareTransformation(mContext);
} else if (position % 19 == 4) {
return new CropTransformation(mContext, 300, 100, CropTransformation.CropType.CENTER);
} else if (position % 19 == 5) {
return new ColorFilterTransformation(mContext, Color.argb(80, 255, 0, 0));
} else if (position % 19 == 6) {
return new GrayscaleTransformation(mContext);
} else if (position % 19 == 7) {
return new CropTransformation(mContext, 300, 100);
} else if (position % 19 == 8) {
return new BlurTransformation(mContext, 25);
} else if (position % 19 == 9) {
return new ToonFilterTransformation(mContext);
} else if (position % 19 == 10) {
return new SepiaFilterTransformation(mContext);
} else if (position % 19 == 11) {
return new ContrastFilterTransformation(mContext, 2.0f);
} else if (position % 19 == 12) {
return new InvertFilterTransformation(mContext);
} else if (position % 19 == 13) {
return new PixelationFilterTransformation(mContext, 20);
} else if (position % 19 == 14) {
return new SketchFilterTransformation(mContext);
} else if (position % 19 == 15) {
return new SwirlFilterTransformation(mContext, 0.5f, 1.0f, new PointF(0.5f, 0.5f));
} else if (position % 19 == 16) {
return new BrightnessFilterTransformation(mContext, 0.5f);
} else if (position % 19 == 17) {
return new KuwaharaFilterTransformation(mContext, 25);
} else if (position % 19 == 18) {
return new VignetteFilterTransformation(mContext, new PointF(0.5f, 0.5f),
new float[]{0.0f, 0.0f, 0.0f}, 0f, 0.75f);
}
return null;
}
开发者ID:cymcsg,项目名称:UltimateAndroid,代码行数:54,代码来源:RepositoryAdapter.java
注:本文中的jp.wasabeef.glide.transformations.ColorFilterTransformation类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论