Thanks to Easy Rawlins and Leonid McGill – and a bunch of less savory characters – Walter Mosley could spend his 60s writing for a few hours each day, then dabbling with his art projects before heading out into the streets of New York City to enjoy the good life and wait for inspiration to find him.

And some days are probably just like that.

But Mosley, like the heroes of dozens of his best-selling books, starting with “Devil in a Blue Dress,” also chooses to get involved with issues that he easily could avoid. In his public speaking and opinion writing, he departs from the difficulties faced by the modern fiction writer and addresses things like the real meaning of the Trayvon Martin case (a concise essay for Newsweek magazine) and the “senseless cynicism” that has taken over America (in the Nation).

He sees the environment as one of the most significant, and significantly ignored, problems facing the world today, and he could talk for quite a while about the fundamental failure of both capitalism and communism to build a society that values all its people equally. (He even has what he admits is probably an unworkable solution – it involves a leasing, rather than selling, economy.)

Expect some of those things to come up Thursday evening when Mosley presents the annual Martin Luther King Jr. Commemoration keynote address at the University at Buffalo’s Center for the Arts.

The MLK talk traditionally celebrates the slain leader’s legacy by focusing on issues of race, rights and where America stands on both, with past speakers including children of the Rev. King, Newark Mayor Cory Booker, lawyer Johnnie Cochran and figures from sports and entertainment, like Kareem Abdul-Jabbar, Sidney Poitier and rapper KRS-ONE.

“What was appealing about Walter Mosley is that, in addition to being a significant author, he is not afraid of making social commentary,” said William Regan, UB director of special events. “Certainly he’s very capable of reflecting on civil rights.”

Regan also noted, “He brings a whole different side to the discussion [and] appeals to the nontraditional audience. Our English department is completely jazzed up about it.”

As Mosley put it, in a recent telephone conversation, “To a great degree I’m a political figure, at least regarding political philosophy. I’m interested in Marx and Hegel and Freud, and in those aspects of technology and technique that create society.”

He details that in his 2011 book “Twelve Steps Toward Political Revelation,” a discourse on how America can free itself from its culture of consumption, much the way he eventually overcame his addiction to alcohol and cigarettes. And note his use of the word “revelation” rather than “revolution” in the title.

Clearly, Mosley is a “big picture” sort of man, and he sees no simple answers to the difficulties faced by the planet’s underclasses.

“There are so many problems in the world,” Mosley said. “The biggest problem that we face is that the world is at a standstill – even the things that we invent are not moving us forward. Capitalism has kind of turned in on itself. Instead of creating, [the pursuit of profit] now limits the potential for growth – economic, cultural and intellectually.”

Even though his genre is crime fiction, Mosley’s books don’t skim over his social concerns. His modern-day investigator, Leonid McGill, works in both the gritty and glittering streets of New York, connecting the dots between the lives of the poor and the actions of the rich in books such as “The Long Fall” and “All I Did Was Shoot My Man.” The suffering he discovers often is born of economic inequality, and of larcenous levels of corporate and bureaucratic greed – along with the greed of a well-organized underworld.

Mosley’s characters come in the full spectrum of skin tones, from creamy to caramel to ebony, but he uses the various shades of white and brown to describe their looks, not their character. This is especially true in his McGill books, set in the here and now; in the Easy Rawlins books, set in the 1950s and ’60s, racism plays a more powerful role. But even then, for Rawlins, bigots are barriers to work around, not chains holding him back.

For Mosley, the only child of a Jewish mother and African-American father, it’s a matter of pragmatism.

“I understand racism, but understanding racism is like understanding a rabid dog,” Mosley says. “I mean, it’s a rabid dog ­– it’s going to bite you.

“But to make that a major part of your philosophy would be defining yourself down. It would let the rabid dog that bit you to define who you are. Yes, race is a part of my life, but it does not run my life. I have a really good life.”

In the interview a week ago, Mosley said he wasn’t sure exactly what he would say at UB, but expected it would be a little different from the “normal kind of talk about race.”

“When people say we are in one world (a post-racial world for example), it’s so crazy,” he said. “I have a story that I tell: about how, in the 20th century, a young black man in Detroit, would say, ‘It’s tough on a young black man in Detroit, ’ and I would be saying, ‘I know what you’re talking about, brother,’ and in the early 21st century, you could go there, and ask ‘How ya doing?,’ and he’d say, ‘I’m OK, but it’s hard on a young black man in Detroit,’ and I’d say ‘I know, brother, but the world is so big – there is a guy in Kandahar who would be happy to trade apartments with us.’ ”

The global view adds perspective, but, Mosley said, “to say there is no more racism is completely ridiculous. How can we say we live in a post-racial world, as if we didn’t have millions of black men in prison … as if people of color weren’t still facing this economic divide. … If you’re a black child in an economically depressed area, if nothing is going your way, for that kid and that kids’ parents – bad schools, no jobs – for them, race is a major issue.”

But, he says, it really is a different world from the one of 60 years ago – the one in which his parents faced a multitude of prejudices for their ethnicity, skin color and love for each other.

“We have to realize everyone is not George Wallace, the world is different,” Mosley said. “I mean, Obama got elected twice.”