Ah, I’m glad that it does!
Just provide collision geometry. This can be made up in code (see the manual entry on collision solids, and perhaps some of the surrounding pages for context), or, if you want a more form-fitting piece of geometry, if can be created as part of the model.
However, see my further answers below…
If I load that model in PView, all that I see is a square–it looks like there’s a texture that it expects to have.
If that texture is making the model appear non-square, then I imagine that the box that your ray is hitting is, in fact, the geometry, which is the square–applying a texture doesn’t change the underlying geometry, even if it’s transparent. In that case you’re just seeing through the transparent parts–but they’re still there.
I think that that line is making the visible geometry available for the ray to collide with–that is, that it causes the ray to collide with visible geometry, but only the specific visible geometry to which that mask is applied.
That said, if you have only one (or a handful) or such objects being picked, then colliding with them shouldn’t be too bad, I suspect–and nowhere near as bad as just making the ray collide with all visible geometry, I daresay.
Hmm… I do have a question, if I may: why do you want to eschew DirectGUI for this?