Decades may have passed since the so-called golden and silver ages of comic books, but as far as Hollywood is concerned, the industry finds itself on the cusp of a diamond-encrusted platinum era of superhero movies. As The Dark Knight roars towards $400m (pounds 201m) this weekend in its record-breaking US run following successful summer launches for Iron Man and Wanted, comic book adaptations are once again bossing it at the box office.

In order to attain such rude health, the studios are once again courting one key demographic - the geeks. This knowledgeable and vocal sub-culture has returned to prominence since the 1990s, when fan hysteria greeted films such as Men in Black, Blade, and the Star Wars sequels and propelled them to box-office success. In the intervening years, Hollywood's cyclical nature and the ascendancy of comic book aficionados such as Christopher Nolan, Zack "300" Snyder, and Frank "Sin City" Miller has seen the nerd return as a highly influential factor in Hollywood. Studio chiefs know all too well that if upcoming projects such as Captain America, Wonder Woman and Wolverine are to prosper, first and foremost they have to be all right with the fans.

Nowhere is this precarious dance more in evidence than at Comic-Con, the annual pop culture jamboree that took place last weekend in San Diego, California. It is into this maelstrom of costumes and commerce that Hollywood honchos take the plunge once a year to promote upcoming releases, announce cast members and trumpet new projects. Footage gets screened way in advance of a film's release in the hope of drumming up enthusiastic word of mouth in blogs and online forums.

Hollywood always wants to know if it's on the right track. Book adaptations and genre films are attractive propositions because studios know the in-built fan base will see the film and galvanise wider attendance. But the comic-book fans are a savvy crowd and, if Hollywood gets it wrong, poor early word can spread like wildfire. Ever since the cult website Ain't It Cool News damned 1997's Batman & Robin with negative advance reviews, there's been a potency to the musings of netizens. After all, who wants to fork out $250m in production and marketing costs only for a film to end up in the bargain bucket at the local video shop?

This year, at Comic-Con, the studios offered sneak previews of wannabe blockbusters such as The Day the Earth Stood Still (Fox's reboot of the 1951 sci-fi classic, now starring Keanu Reeves), Frank Miller's adaptation of The Spirit, based on Will Eisner's old newspaper comic strip, and Underworld: Rise of the Lycans. Reeves and Miller turned up in person, as did Hugh Jackman, Comic-Con regular Samuel L Jackson, Michelle Yeoh, Brendan Fraser and the new kings of comedy, Judd Apatow and Seth Rogen. Few places outside of the Cannes, Venice and Toronto film festivals boast such a concentration of talent.

One of the major Comic-Con events, though, was the first screening of footage from the long-gestating Watchmen movie. Twelve months after Warner Bros announced casting information, the studio returned to show footage of the postmodern superhero tale. The crowd was euphoric and - ker-ching! - you could almost hear the collective sigh of relief from the cadre of top executives seated at the front of the 6,500-seater Hall H. There were similarly excitable receptions for Warner Bros/Sony's Terminator: Salvation, Fox's Wolverine spin-off and Lionsgate's The Spirit.

Those in the know agree that in order to stand a chance of success, an adaptation must stick to the core elements of the property and the studio must not get side-tracked by the opinions of fans once the project is underway. "You always try to be faithful to the origins of the story and you always make sure you honour the tone," Summit Entertainment's co-chairman and CEO Rob Friedman told me a day before the company previewed footage of its vampire tale, Twilight, to rapturous applause. "Usually you want to keep the creator involved as much as possible and that's what we did with the author Stephenie Meyer."

Any egregious detour from the essence of a character or core story might lead to disaster. "If that happens, the fans will revolt," one leading agent close to the comic book world told me. So don't even think of turning Peter Parker from a newspaper photographer into a roguish used-car salesman. Fans will, however, allow small tweaks here and there. When Spider-Man director Sam Raimi sat down to develop the first film with producer Avi Arad, the pair decided it would take too long to show brilliant science student Parker engineering his web shooters. They settled instead on organic web slinger that shot out of Spidey's wrist.

As the Spider-Man franchise and The Dark Knight show, when an adaptation works it spells big profits for the studios. It also bolsters the sense of vicarious pride that any fan feels when his or her favourite story earns recognition. "Geek culture is here to stay," Kevin Smith, the director of such comedies as Clerks and Dogma and about as big a Comic-Con icon as you can get, told a packed hall during a panel discussion.

After several hours you become inured to the hordes of attendees decked out in tight fitting Superman outfits or smeared Joker face paint. Star Wars, of course, is a galaxy that is never far, far away at Comic-Con and the convention centre is filled with Boba Fetts, Stormtroopers and other life forms. During a panel to promote next months' release of the animated feature Star Wars: The Clone Wars, I sat next to Amy, a middle-aged veterinarian from Los Angeles, who smoothes the folds of her Obi-Wan Kenobi tunic as we talk. "There was something about Star Wars that has always stayed with me," she says. "There's so much they can do with the story; that's one of the things that makes it stay interesting." But Amy is no fool and won't buy everything with the Star Wars name. "They brought out a line of books that was pretty lame so I stopped buying those."

"It's an extended family for me," says Michael, a 59-year-old urologist from North Dakota. "I'd always loved Stars Wars and after my wife passed away 15 years ago I threw myself into it and the community became my family. I meet some of my best friends at these events. I have a day job and a mortgage and car, but this is my real life. I couldn't say what I'd do if I didn't have Star Wars and the community."

"You see this a lot," says Steve Sansweet, Lucasfilm's head of fan relations. "People will tell you how much Star Wars means to them. Fan culture is all sorts of things. It can be geeks in costumes who haven't showered for two weeks or ordinary-looking people who received their love of Star Wars from their parents and have in turn passed it on to their children." Star Wars: The Clone Wars is an original idea that Lucas and the film's director Dave Filoni worked on. A 22-episode animated TV series will follow this autumn and beyond that Lucas has his eye on a live-action TV series. "The live-action movies were really centred on the Skywalker family and we've never gotten to see the full breadth of the conflict," Filoni told the crowd in a reverential tone. "We grew up with Star Wars. We really believe in it."

So do millions of others. Lucasfilm first came to Comic-Con in 1976 because even back then, a year before the first film's release, Lucas felt a fan convention would be the perfect forum to develop awareness. They've never looked back. Are the fans' being exploited by a succession of films, books and merchandising? Sansweet doesn't think so. "You have to handle fans as a fellow fan and you can't talk down to them. Fans are smart: if they smell bullshit they're not going to jump into it."

Bullshit or not, Sansweet has never regretted jumping into the world Lucas created. "I'm a fan myself," says the man who is working on the second edition of the Star Wars encyclopedia that he assures me will run to at least 1,200 pages. "I've been called a geek, an anorak and even a nutter in Australia. I don't care. None of us cares. You take the word people are calling you and you desensitise it. If that's what we are then that's what we are and we'll keep on going." Hollywood, for one, will be cheering them on.