To be precise, I want to achieve this. 
I am using recyclerview with GridLayoutManager. I also made the first element big using the following code
lLayout.setSpanSizeLookup(new GridLayoutManager.SpanSizeLookup() { @Override public int getSpanSize(int i) { if (i==0) return 2; else return 1; } });
Everything works fine except for one: the element at position 1 (i.e. the next element from the large image) is stretched vertically to fit the height of the large element. From line 3, all images are shown in the image.
How can I get rid of this?
Edit: after some analysis
So the problem is that the large image spans two spans horizontally but one span vertically, and since I made my ImageView be square, it looks like it also took two rows, where in fact it is one row. For this reason, the second image seems elongated.
So, now my question is: how to make a grid element two vertical and two spans horizontally?
source share