Jump to content
Eternal Lands Official Forums
Sign in to follow this  
ttlanhil

problems trying to get music to play

Recommended Posts

I've been trying to get the client to play the .oggs. it's trying not to.

I know the .dlls are new enough because I downloaded the latest release earlier today, and no help

it all works up until trying to ov_open the .ogg itself, then I get a memory access error. if the file isn't openable, then all is well

 

the ov_open call is in sound.c:209

 

 

backtrace:

 	ntdll.dll!RtlpWaitForCriticalSection()  + 0x5b	
	ntdll.dll!RtlEnterCriticalSection()  + 0x46	
vorbisfile_d.dll!fseek(_iobuf * stream=0x00565578, long offset=0, int whence=1)  Line 103 + 0x9	
	vorbisfile_d.dll!_fseek64_wrap(_iobuf * f=0x00565578, __int64 off=0, int whence=1)  Line 630 + 0x11
vorbisfile_d.dll!_ov_open1(void * f=0x00565578, OggVorbis_File * vf=0x006e3c40, char * initial=0x00000000, long ibytes=0, ov_callbacks callbacks={...})  Line 635 + 0x15
	vorbisfile_d.dll!ov_open_callbacks(void * f=0x00565578, OggVorbis_File * vf=0x006e3c40, char * initial=0x00000000, long ibytes=0, ov_callbacks callbacks={...})  Line 731 + 0x31
	vorbisfile_d.dll!ov_open(_iobuf * f=0x00565578, OggVorbis_File * vf=0x006e3c40, char * initial=0x00000000, long ibytes=0)  Line 744 + 0x31
	elc_ttlanhil_debug.exe!load_ogg_file(char * file_name=0x006e3fb4)  Line 208 + 0x14
	elc_ttlanhil_debug.exe!play_ogg_file(char * file_name=0x006e3fb4)  Line 168 + 0x9
	elc_ttlanhil_debug.exe!update_music(void * dummy=0x00000000)  Line 565 + 0x13
	SDL.dll!SDL_Delay()  + 0x61e	

 

the offending part of the fseek() is:

_lock_str(stream);

stream is as such:

stream	0x00565578 {_ptr=0x1c2dae10 "OggS" _cnt=0x00000000 _base=0x1c2dae10 "OggS" ...}	_iobuf *
_ptr	0x1c2dae10 "OggS"	char *
_cnt	0x00000000	int
_base	0x1c2dae10 "OggS"	char *
_flag	0x00002009	int
_file	0x0000000a	int
_charbuf	0x00000000	int
_bufsiz	0x00000200	int
_tmpfname	0x00000000 <Bad Ptr>	char *

(that "OggS" is what the start of the file looks like, with a null at the end, so it's proof the file is opened)

 

and the memory that cannot be accessed is always 0x10, which is odd...

 

I don't really read assembly, but in case anyone does and it helps; the line that the error comes up on in ntdll is last of the following:

7C918FDA  mov		 eax,dword ptr [esi+10h] 
7C918FDD  cmp		 eax,ebx 
7C918FDF  mov		 dword ptr [ebp-4],eax 
7C918FE2  je		  RtlpUnWaitCriticalSection+2Fh (7C919086h) 
7C918FE8  mov		 eax,dword ptr [esi] 
7C918FEA  inc		 dword ptr [eax+10h] 

(at time of crash, eax is 0, esi is 5658008. which seems wrong after the mov)

 

now, I have one possible culprit, that's that using .dll's makes passing the file handle not work. but the EL client that's available for download has them as .dlls too.

I've tried a static link, but it comes up with missing references in the .lib, not sure if I did it wrong, or i need to statically link more stuff in, or what

 

any constructive comments welcome

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×