Joaquin Phoenix looked as though he'd lost it, coming completely unglued with his film "I'm Still Here," in which he chronicles his supposed move into rap music after announcing his retirement from acting.

Sure, it was all a put-on: his retirement, the rap career and the way he degenerates through the film. Yet letting himself hurtle out of control was part of the plan, Phoenix said.

Phoenix had grown a bit bored with filmmaking and how he approached it, the scripted roles and the predictability of the storytelling.

"I'm Still Here" was his way of working without a net.

"I wanted to do something that was terrifying and felt like there wasn't any blueprint and I didn't really know what was going to happen," Phoenix, 37, said in an interview at the Toronto International Film Festival, where his drama "The Master" played ahead of its theatrical release Friday.

"I need to know that there's some kind of, like, crazy magic that happens. And maybe it's not. Maybe that's just from my end, and a really smart director knows that you do these certain things and you get a reaction from an audience. But I don't like that, and I had to kind of feel that there was something mysterious and something out of my control that occurs for it to feel like it was exciting to me again."

So he and brother-in-law Casey Affleck came up with a plan. Phoenix announced that his 2009 drama "Two Lovers" would be his farewell to acting after a career that included such films as "To Die For," ''Signs" and "Hotel Rwanda," along with Academy Award-nominated performances as a despotic Roman ruler in "Gladiator" and as Johnny Cash in "Walk the Line."

With Affleck directing, they chronicled Phoenix's transition to music in 2010's "I'm Still Here," purportedly a documentary but really an elaborate fiction that seemed to show the actor crumbling into an emotional meltdown.

Part of the inspiration came from reality television, particularly shows exposing intimate and embarrassing details of celebrities' lives, Phoenix said.

The normally clean-cut Phoenix let his hair go and grew a wild beehive of a beard. In "I'm Still Here," he croaked bad rap music, smoked weed endlessly and appeared to snort cocaine off of a prostitute's breasts. The film also included his notorious interview with David Letterman to promote "Two Lovers," in which Phoenix mumbled responses, stared at the talk show host in uncomfortable silences and generally seemed off his rocker.

Phoenix came back on the show in 2010 and apologized, telling Letterman it was all an act for "I'm Still Here."

"Casey and I unfortunately — Casey more than I — have that horrible sense of humor where we just love seeing people squirm, particularly ourselves," Phoenix said at Toronto. "It was just something where we were trying to capture that moment of incredible discomfort where you're cringing for somebody else."

Some people did cringe for Phoenix, wondering if he really had gone off the deep end. Others in Hollywood assumed he was playing a role, making a film in a daring new way.

Among those was Paul Thomas Anderson, whose own bold films include "Magnolia" and "There Will Be Blood." Anderson had his eye on Phoenix to co-star with Philip Seymour Hoffman in "The Master," a tale with overtones of L. Ron Hubbard and Scientology that centers on a boozy, brawling World War II veteran who falls under the sway of the dynamic leader of a spiritual movement.

But Anderson refrained from contacting Phoenix until "I'm Still Here" was behind him, not wanting to distract the actor from convincing the world that he had gone crazy. Anderson did not know for sure, but he said he sensed Phoenix was just playing a role.

"I was cheering from the sidelines, watching him sort of being out of his mind and enjoying it," said Anderson, who thinks Phoenix came out of "I'm Still Here" a better actor, able to dig deeper than ever. "He found a way to scare himself again and to care and to get his hunger back. I got the benefits of that. I just thank my lucky stars that we came together at the right time to go about doing this thing that we did."

"The Master" has shot to the top of this season's Oscar list after earning Anderson the directing prize at the Venice Film Festival, where Phoenix and Hoffman also shared the best-actor award.

Phoenix plays Freddie Quell, a Navy veteran drifting without a rudder until he falls in with Lancaster Dodd (frequent Anderson collaborator Hoffman, an Oscar winner for "Capote"). Dodd is founder of The Cause, a cult whose adherents believe they can access memories from past lives to help achieve balance and tranquility.

Much of "I'm Still Here" was unscripted, and Phoenix said the improvisation he had to do in that film was great preparation for capturing the volatility of Freddie as he swings back and forth from devotion to disdain for Dodd.

"I'm Still Here" ''really allowed me to be more open as an actor, and going into this film, Paul seemed to not only allow but encourage a real change in behavior from moment to moment. It really suited the character, because he's so mercurial in a way, and you're not really sure of his motivation," Phoenix said. "I don't really like controlled performances, and so that I think was really helpful for me."

He's hurled himself back into acting, with upcoming roles in Spike Jonze's as-yet-untitled film, which features "The Master" co-star Amy Adams, and teaming with "Two Lovers" director James Gray for their fourth movie together.

So Phoenix is still here, with no plans to retire.

"The joke was that Casey and I after every movie say, like, we're quitting, and we realize that we have no other skills and it's something that we love to do," Phoenix said. "And it's absurd to think of retiring from something at 35 which doesn't really have a retirement age. It's not like it's basketball and your knees go. We just felt that it was a built-in joke and thought it was funny."