M
M
mrspd2012-09-02 21:10:03
css
mrspd, 2012-09-02 21:10:03

Mosaic of pictures, like VKontakte

Not so long ago, a feature appeared on VKontakte when a post with pictures is posted on the wall, and they line up in a beautiful mosaic. I remember that there was an article about something similar on Habré, but I never found it ...

But the link is not the main question. Maybe there are some js plugins? In general, I want to write such a thing myself, but I’ve been hatching an algorithm all day and nothing comes to mind. Does anyone have any ideas? Ready to take it, then write a post about the problems that have arisen and, of course, put the plugin in public.

Perhaps this is also solved on the server side, but I still have a goal of automatic rendering when changing the window width.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
V
Vitaliy Petrychuk, 2012-09-02
@mrspd

Can you give a screenshot of "how does it look in contact"?
Judging by the description, you are looking for something like this - masonry.desandro.com

I
Igor Deryabin, 2012-09-03
@rodweb

tympanus.net/codrops/2011/08/30/automatic-image-montage/

S
Skull, 2012-09-04
@Skull

Maybe without plugins, I did it by hand. We wrap the image in a div, apply our own styles with negative offsets to each div, so that exactly a square or rectangle with the desired proportions is displayed

P
povisok_dmitriy, 2014-06-17
@povisok_dmitriy

how to screw a lightbox here tympanus.net/codrops/2011/08/30/automatic-image-mo...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question