1. I like swimming in the river.

2. I like to swim in the river.
------------------------------
Are both the same in meaning?

3. I like swimming in the river.
4. I like to swim in the river now.
(#3 means 'generally I like swimming in the river.' #4 means 'I want to swim now though I don't like swimming. It's very hot today.' What about the explanation?)

1 answer

1 and 2 mean the same thing, yes.

Your explanation for 3 is fine.

Your explanation for 4 adds things that aren't there! For 4, I'd simply say it means I like to swim there at the moment (now).

4 could mean I like swimming there now, but not in the winter. It could mean many other things, depending on its context.