Think of it as two interfaces:
1) Between the frame and the BB.
2) Between the BB and the crankset.
You will need a BB that matches both - so for most Shimano that would be PF BB86 (1) and Hollowtech II (2). Changing to SRAM on that frame you'll need PF BB86 (1) and most probably GXP (2) - though I'm not an expert on SRAM. You may find that GXP and HTII are compatible too though I'm also not sure on that and would probably play it safe.
Generally speaking, for (2) you can work out compatibility based on axle length and width but again I tend to play it safe.
1) Between the frame and the BB.
2) Between the BB and the crankset.
You will need a BB that matches both - so for most Shimano that would be PF BB86 (1) and Hollowtech II (2). Changing to SRAM on that frame you'll need PF BB86 (1) and most probably GXP (2) - though I'm not an expert on SRAM. You may find that GXP and HTII are compatible too though I'm also not sure on that and would probably play it safe.
Generally speaking, for (2) you can work out compatibility based on axle length and width but again I tend to play it safe.