• Advertisement
Sign in to follow this  

How to make a left-right format 3D program?

This topic is 1924 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am making a program with left-right 3d format using Direct3D9.
I set up two camera represent human eyes.
And I want to cut half pixie in one scene.
just like this
[img]http://wenwen.soso.com/p/20110521/20110521162429-305520161.jpg[/img]
So how can I make this? Edited by kgs

Share this post


Link to post
Share on other sites
Advertisement
One method would be to [url="http://msdn.microsoft.com/en-us/library/windows/desktop/bb206341(v=vs.85).aspx"]set a viewport[/url] that covers the left half, render the 1st image, then set a viewport that covers the right half, and render the 2nd image.

Share this post


Link to post
Share on other sites
[quote name='Hodgman' timestamp='1350118644' post='4989719']
One method would be to [url="http://msdn.microsoft.com/en-us/library/windows/desktop/bb206341(v=vs.85).aspx"]set a viewport[/url] that covers the left half, render the 1st image, then set a viewport that covers the right half, and render the 2nd image.
[/quote]
Thank you!!This method works and it's very simple!
And my next step is to write a program with Interlaced format 3D!
Do you have any idea about how to do with it?

Share this post


Link to post
Share on other sites
How familiar with HLSL/shaders are you?

Personally, I would render the left/right images to 2 different render-targets. Then I would use a pixel shader that checks the current pixel's position, and then samples either the left/right texture depending on if the position is odd/even.

Share this post


Link to post
Share on other sites
If I recall correctly, there was an article on interlaced rendering in one of the original ShaderX books, which I think are available online for free. Try searching around for it - the technology may be outdated, but the theory should be more or less the same (interlaced video has been around since TV broadcasts started...).

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement