It really depends on the intersection whether I'll filter to the front or take the lane. How much of a shoulder is there? How much is there on the other side of the intersection? How busy is the cross street - what's the likelihood that many of the cars will be either turning right, or looking to their left as they cross? Do any of the cars have turn signals on, and if so, where are they in line? (I know not to rely on turn signals - one way or the other - but it's one of many clues I use.) How much visibility is there all around? Is #1 in line back from the intersection, in the crosswalk, or somewhere in between? What's the speed limit and the ambient speed? What are the light conditions? What's the mood of traffic I've observed approaching the intersection?

With a longer light you have the option of filtering as far as is possible or safe, all or part of the way to the light, and then taking the lane in front of a stopped car. (Motorcycles do it all the time.)

While you may put yourself in danger of a right hook if you don't wait behind all the cars, you may put yourself in danger of being rear ended if you do. (Even if you wait behind all the cars, some of them will then pass you before the intersection, and any one of them may right hook you.) In daylight, you're almost always more visible from the side than from the rear if you pull into the driver's field of view, turn around and look at them, don't get too close to their car (which is why the width of the shoulder matters).

Negotiating traffic is always a matter of making hundreds of judgments every minute. FWIW I don't think a bicyclist who plans to go straight should EVER get in a right-turn lane for ONE SECOND, even if it means riding to the left of a considerable amount of traffic. Getting into that right hand turning lane is a sure way of getting right-hooked, IMO.