본문 바로가기
안드로이드 스튜디오

firebase 저장소에 저장된 사진을 불러와 이미지뷰에 넣기.

by Jun_N 2018. 9. 13.

intent에서 이미지정보를 넘겨줌.

intent.putExtra("IMAGE1", arr.get(a).getImageUrl1());

=> 작업을 원하는 Activity로 이동.

String image1 = intent.getExtras().getString("IMAGE1");

로 image1에 정보를 받기.


StorageReference ref = FirebaseStorage.getInstance().getReference("images/"+image1);

로 ref에 저장소값 저장.

Glide.with(this /* context */)
.load(ref)
.into(imageShow1);

imageShow1이라는 이미지뷰에 Glide로 넣어주면 사진정보가 넘어가서 imageview에 뜨게됨.