Shadowmapping Large Terrains

I have a problem with getting my shadowm frustum to follow my camera around… As of now when I move it based on my camera position xz values the frustum moves the opposite way… I am trying to get the frustum to follow so I can shadow only whats near my viewing volume. Any help would be great. Thanks

Sorry, but what is your question? Do you need a tutorial in linear algebra? I would suggest buying a book on the subject.

Originally posted by <s03>:
Sorry, but what is your question? Do you need a tutorial in linear algebra? I would suggest buying a book on the subject.
Thanks for the tip, but not what I am looking for. I am looking for what am I to do or should be doing to make my shadow’s frustum follow me around so I can reduce(have reduced my frustum) to make for a more high resolution shadowmap. Thanks

Sorry, I’d like to help you but I just don’t understand the question.

If you mean maximizing lightmap resolution via trapezoid shadow mapping (TSM) or light space perspective shadow maps (LiPSM) then there’s plenty online in the way of white papers and some good demos with source.

But it sounds more to me like you’re struggling with some matrix math. If that’s the case I again urge you to get a book on the subject. You won’t regret it.