You are not logged in.

Read the FAQ and Knowledge Base before posting.
We won't make a 3DS/2DS emulator.



#1 2012-07-11 20:55:46

someone
Member
Registered: 2009-01-07
Posts: 78

Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

I am sure rogerman is already aware of the issues, but I just want to confirm that the blank graphics display problem is still present on the GM, thus the retail version of OS X 10.8

Offline

#2 2012-07-13 04:07:17

rogerman
Member
Registered: 2011-06-04
Posts: 380

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

Hi someone,

Sorry that Mac DeSmuME doesn't work in OS X 10.8 Mountain Lion. The issue here is that Mountain Lion makes some changes to its OpenGL implementation, which is what Mac DeSmuME uses to render frames to the window.  Unfortunately, no one on the DeSmuME team currently has a pre-release copy of Mountain Lion to test with, so it is currently unsupported at this time. When Apple finally releases Mountain Lion, we should be able to fix the graphics issue.

Offline

#3 2012-07-29 21:04:07

songohan155
Member
Registered: 2012-07-29
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

I had the same issue when I upgraded my macbook to osx 10.8. For this reason, I had a look the  the code and  I've found what's wrong .
It seems that OSX's lion noes requires each app to specify the opengl profile at initalisation. For this reason, I have set the view to use opengl's legacy profile (not 3.2 core) in the displayView.mm file. Now Desmune video output is working again in osx 10.8:-)

- (id)initWithCoder:(NSCoder *)aDecoder
{
	self = [super init];
	if (self == nil)
	{
		return self;
	}
	
    NSOpenGLPixelFormatAttribute pixelFormatAttributes[] =
    {
        NSOpenGLPFAOpenGLProfile, NSOpenGLProfileVersionLegacy,
        0
    };
   
    
	dispViewDelegate = nil;
	lastFrameSize = NSMakeSize(GPU_DISPLAY_WIDTH, GPU_DISPLAY_HEIGHT * 2.0);
	glTexPixelFormat = GL_UNSIGNED_SHORT_1_5_5_5_REV;
	glTexRenderStyle = GL_LINEAR;
	
	UInt32 w = GetNearestPositivePOT((UInt32)lastFrameSize.width);
	UInt32 h = GetNearestPositivePOT((UInt32)lastFrameSize.height);
	glTexBack = (GLvoid *)calloc(w * h, sizeof(UInt16));
	glTexBackSize = NSMakeSize(w, h);
    
    NSOpenGLPixelFormat *pixelFormat = [[[NSOpenGLPixelFormat alloc] initWithAttributes:pixelFormatAttributes] autorelease];
    NSOpenGLContext* openGLContext = [[[NSOpenGLContext alloc] initWithFormat:pixelFormat shareContext:nil] autorelease];
    [super initWithCoder:aDecoder];
    [self setOpenGLContext:openGLContext];
    [openGLContext makeCurrentContext];
  
   
    return self;
}

desmuneosx108.png

Uploaded with ImageShack.us

Can the DeSmenu Mac team members    confirm this "patch" works for them?

Offline

#4 2012-07-30 06:07:03

marcusmaximusii
Member
Registered: 2012-07-30
Posts: 1

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

I must ask you songohan155 how were you able to edit the file and what did you use to make this "patch". I can try and confirm it for you if needed

Offline

#5 2012-07-30 07:27:20

pkmnmstralexxx
Member
Registered: 2012-07-30
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

songohan155, I was also unable to locate how you did this, perhaps you could PM me and explain it a little further?.

Offline

#6 2012-07-30 09:15:06

songohan155
Member
Registered: 2012-07-29
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

To apply this patch, you have to build desmune from the latest source code. Basically, you need to :
1-install Xcode dev tools from the mac app store
2-download the source code either from svn (0.9.9) or the project page.
3- Open Desmune (XCode4).xcodprojct
3-in the files pane, open (CocoaPort->userinterface->displayView.mm)
4-replace the original [OpenGLDisplayView initWithCoder:(NSCoder*)a Decoder] implementation with the code I provided above)
5-build the  "Desmune (v10.7 lion) My Mac 64 bit target".
This creates a new desmune app bundle compatible with osx 10.8.

Offline

#7 2012-07-30 16:12:01

amfreund
Member
Registered: 2012-07-30
Posts: 2

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

So I have 0 programming experience, and I'm trying to figure out how to do this. I replace the code, but I keep getting an error every time I try to build. clang:

"error: no such file or directory: '/Users/alexfreund/Downloads/desmume-0.9.8/src/cocoa/../metaspu/SoundTouch/AAFilter.cpp'
clang: error: no input files
Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 1"

do you have any suggestions?

Offline

#8 2012-07-30 16:38:33

pkmnmstralexxx
Member
Registered: 2012-07-30
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

@songohan155, I can't seem to find an svn 0.9.9 build. It seems that the only builds for that are still not available on the internet, as it would be the "fixed" version of this already making what we're doing here pointless.
0.9.9 isn't available... is it?.
0.o

and also, when I use the 0.9.8 build and follow your steps, when I go to build it I get an error message saying that "10.5 leopard contains no buildables that can be built for the SDK's supported by the run destination My Mac 64-bit".
any suggestions on this?.

Offline

#9 2012-07-30 17:08:22

pkmnmstralexxx
Member
Registered: 2012-07-30
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

Everytime I try this I just get the same message saying it failed to build; "Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 1"
how do I fix this?.
D;

Offline

#10 2012-07-30 17:47:55

riosgra89
Member
Registered: 2012-07-30
Posts: 3

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

could you upload a fixed binary in sendfile or mediafire or wherever you like a copy of the fixed binary???


songohan155 wrote:

I had the same issue when I upgraded my macbook to osx 10.8. For this reason, I had a look the  the code and  I've found what's wrong .
It seems that OSX's lion noes requires each app to specify the opengl profile at initalisation. For this reason, I have set the view to use opengl's legacy profile (not 3.2 core) in the displayView.mm file. Now Desmune video output is working again in osx 10.8:-)

- (id)initWithCoder:(NSCoder *)aDecoder
{
	self = [super init];
	if (self == nil)
	{
		return self;
	}
	
    NSOpenGLPixelFormatAttribute pixelFormatAttributes[] =
    {
        NSOpenGLPFAOpenGLProfile, NSOpenGLProfileVersionLegacy,
        0
    };
   
    
	dispViewDelegate = nil;
	lastFrameSize = NSMakeSize(GPU_DISPLAY_WIDTH, GPU_DISPLAY_HEIGHT * 2.0);
	glTexPixelFormat = GL_UNSIGNED_SHORT_1_5_5_5_REV;
	glTexRenderStyle = GL_LINEAR;
	
	UInt32 w = GetNearestPositivePOT((UInt32)lastFrameSize.width);
	UInt32 h = GetNearestPositivePOT((UInt32)lastFrameSize.height);
	glTexBack = (GLvoid *)calloc(w * h, sizeof(UInt16));
	glTexBackSize = NSMakeSize(w, h);
    
    NSOpenGLPixelFormat *pixelFormat = [[[NSOpenGLPixelFormat alloc] initWithAttributes:pixelFormatAttributes] autorelease];
    NSOpenGLContext* openGLContext = [[[NSOpenGLContext alloc] initWithFormat:pixelFormat shareContext:nil] autorelease];
    [super initWithCoder:aDecoder];
    [self setOpenGLContext:openGLContext];
    [openGLContext makeCurrentContext];
  
   
    return self;
}

http://img571.imageshack.us/img571/4458/desmuneosx108.png

Uploaded with ImageShack.us

Can the DeSmenu Mac team members    confirm this "patch" works for them?



could you upload a fixed binary in sendfile or mediafire or wherever you like a copy of the fixed binary???

Offline

#11 2012-07-30 18:32:40

songohan155
Member
Registered: 2012-07-29
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

here is a compiled osx bundle . I've just checked out the latest svn trunk (revision 4334), and applied the patch. So far I've only tested it with dragon quest IX, but it should work with other games too.

Remember, this is an unofficial build, so use it at your own risk. Also, since I don't have a developer id,  the application is not digitally signed. Therefore, with Gatekeeper's default security settings it won't run. Just right click on desmune and select "open" to bypass it (or just disable gatekeeper).

http://www.mediafire.com/?csy4wg7egl1hh56

Offline

#12 2012-07-30 18:53:25

riosgra89
Member
Registered: 2012-07-30
Posts: 3

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

it does works great! thank you

Offline

#13 2012-07-30 19:20:56

pkmnmstralexxx
Member
Registered: 2012-07-30
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

OHHHH, songohan155, you made my week!. It works like a charm. >;D.

Offline

#14 2012-07-31 18:36:01

amfreund
Member
Registered: 2012-07-30
Posts: 2

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

You are GOD

Offline

#15 2012-08-01 01:25:08

steve611
Member
Registered: 2012-08-01
Posts: 1

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

I don't normally post on these things, but I felt compelled to register for the forum when I saw the work put in by Songohan. You have my thanks sir. It works flawlessly.

Offline

#16 2012-08-01 01:53:02

Tubebaum
Member
Registered: 2012-07-28
Posts: 3

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

Thank you so much for the compiled bundle songohan smile

Offline

#17 2012-08-06 11:29:45

songohan155
Member
Registered: 2012-07-29
Posts: 4

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

Rogerman has  fixed this bug in SVN Revision 4343 :-)

Offline

#18 2012-08-06 18:47:29

icecubelux
Member
Registered: 2012-07-28
Posts: 6

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

Wow, songohan155, thanks a LOT. I love your version, but it has one minor problem: the in-game music is slower than normally. I'm not sure if it's only your version which has the bug. Could you please help? Thanks a lot smile

Last edited by icecubelux (2012-08-06 18:47:54)

Offline

#19 2012-08-06 19:43:27

rogerman
Member
Registered: 2011-06-04
Posts: 380

Re: Desmume 0.9.8 and Mac OS X Mountain Lion Golden Master

We've posted a new OS X build that fixes the graphical issues in Mountain Lion. Be sure to get it from our downloads page!

Download Link: http://desmume.org/download/

Last edited by rogerman (2012-08-06 19:44:05)

Offline

Board footer

Powered by FluxBB