It is currently Sat Dec 20, 2014 7:55 am

All times are UTC




Post new topic Reply to topic  [ 12 posts ] 
Author Message
PostPosted: Wed Feb 09, 2011 11:30 pm 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
I'm wondering if it would be possible to display the 5 layers and sprites and in 3D to provide a sense of depth. If you've ever played a Virtual Boy game, you've seen the depth effect and have an idea of what I'm talking about.

I made a mock up 3D image of a game that makes use of layers, Joe & Mac. I took a screenshot of each layer, then in a photo editor pasted them side by side and moved each layer 5 pixels to the left or right.

Image

To see the effect, cross your eyes slightly until you see a dot in the center bottom, then look up at the image that appears in the center.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 09, 2011 11:35 pm 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
also sorry if this hurts your eyes ;)


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 11, 2011 1:38 am 
Offline
Official Android Porter
User avatar

Joined: Mon Feb 07, 2011 9:20 pm
Posts: 303
Location: All up in your business
Unfortunately there's no really effective way to do this without specific emulator settings for each game or game engine. Different games will deal with parallax in different ways, and on top of that, you would need to shift the background each time a new screen loads AND make the background images slightly wider or restrict the traversable areas a bit l. It's a minor gain for a lot of work, and it would have to be repeated for every ROM.

Sorry. :/


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 11, 2011 2:18 am 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
If the offset was adjustable per game, it could still be useful. There could even be a repository of conf files for games, user created. I could see the 3D community getting into this.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 11, 2011 2:54 am 
Offline
Official Android Porter
User avatar

Joined: Mon Feb 07, 2011 9:20 pm
Posts: 303
Location: All up in your business
industrai wrote:
If the offset was adjustable per game, it could still be useful. There could even be a repository of conf files for games, user created. I could see the 3D community getting into this.


It's not even just a matter of adjustable offset. It's the method that you'd have to use to -get- the offset in the first place - there's a lot going on behind the scenes, and you'd have to dig into the ROM's programming to figure out what has to be done. Without having access to the source code that was used to make the ROM in the first place, you'd have to decompile the thing, work through the machine code to find what needs to be tweaked (which would require the expertise of a ROM-hacking god), and try the tweak and hope like the dickens that it doesn't make things break horribly. Somehow, you'd have to fool the game into thinking that you're a bit left (or right) of where you're actually standing. This simply isn't feasible.

Once you have that, as long as it doesn't negatively affect anything, it wouldn't be all that difficult to rig up a custom emulator that runs two sessions side-by-side, the hacked version and the regular version. But even then, you'll run into issues with the far left and far right side of the playing field hitting the 'edge' and killing your 3D as the game proceeds to stop at the same place on both screens instead of having the offset that's so necessary for the effect to work.

It's easy to make a game that uses an established 3D graphics library into proper stereoscopic 3D, such as OpenGL or Direct3D. Cobbling stereoscopy into a game that has no support for anything but 2D is difficult at best, futile at worst.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 11, 2011 3:36 am 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
I understand that each game is different, but couldn't something rudimentary be built without having to work perfect for each game right off the bat?

In snes9x you can press 1-5 to turn on and off the layers of any game. Would you really need to dig into each rom's programming to offset those layers, say ctrl+1+up and ctrl+1+down to increase the offset on layer 1 etc.?


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 11, 2011 6:47 am 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
Perhaps this will be a more popular topic once snes emulation comes to the 3DS


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 21, 2011 10:27 pm 
Offline
Snes9x Brown Belt
User avatar

Joined: Fri May 28, 2004 6:16 pm
Posts: 1100
I think computer software would have to be wayyyyyyyyyyyyyyyy more developed before you could really consider soemthing like this relistically (at least for this to be automatic, which would be best). Perhaps someday, but still years down the road at the earliest.

_________________
The soldier was forced to desert his dessert in the desert.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 21, 2011 10:32 pm 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
kolechovski wrote:
I think computer software would have to be wayyyyyyyyyyyyyyyy more developed before you could really consider soemthing like this relistically (at least for this to be automatic, which would be best). Perhaps someday, but still years down the road at the earliest.


I don't think computer software has to be way more developed for this to happen. The layers are there, the emulators can detect them, and enable/disable them with a simple keystroke. I don't believe it would be that much more difficult to offset the layers. It doesn't have to be automated, it could be user controlled, and saved per game as a txt file, and exported for future gamers.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 21, 2011 11:24 pm 
Offline
Official Android Porter
User avatar

Joined: Mon Feb 07, 2011 9:20 pm
Posts: 303
Location: All up in your business
Automatic detection is more the issue - adjusting it by hand just seems messy, and very hack-ish. It also simply doesn't fit the objective of SNES9x as well, which is accurate emulation and portability.

Now, if you can pick out the parts in the source code pertaining to drawing of backgrounds, I might be able to throw something together - but I haven't delved very far into the source myself. It's an interesting idea for a hack though.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Feb 21, 2011 11:51 pm 
Offline
Snes9x White Belt

Joined: Wed Feb 09, 2011 11:13 pm
Posts: 7
Doing a quick search for BG1, I see in gfx.cpp the following:

void RenderScreen (uint8 *Screen, bool8 sub, bool8 force_no_add, uint8 D)
{
bool8 BG0;
bool8 BG1;
bool8 BG2;
bool8 BG3;
bool8 OB;

GFX.S = Screen;

not sure if that is a good starting point or not.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Feb 22, 2011 4:58 am 
Offline
Official Android Porter
User avatar

Joined: Mon Feb 07, 2011 9:20 pm
Posts: 303
Location: All up in your business
It just might be. I'll give it a look when I have a chance.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group