The main aim of realism in literature is to represent reality in such a manner that portrays earthly and everyday experiences as they exist in real life.
From the statement in the question which was taken from a poem titled "Song of Myself" by Walt Whitman, we can see he is saying the corpse which he thinks is a good manure doesn't offend him but instead he is reaching for nice scented smell of white roses.
This depicts the beautiful and harsh part of life.
Thus, the theme of realism here is: The beautiful and harsh realities of life