audio play automatically in the background when opening picture

Ask for help and post your question on how to use XnView MP.

Moderators: helmut, XnTriq, xnview

Post Reply
dlareg
Posts: 5
Joined: Thu Apr 18, 2024 8:11 pm

audio play automatically in the background when opening picture

Post by dlareg »

How can I have audio files (*.WAV and *.MP3) play automatically in the background when viewing an image?
-----------------------------------------------------------------------------------------------------------------------------------
Hello,
I really appreciate the versatility and functionality of XnViewMP. My question, or rather my problem is whining on a high level . . .

According to:
viewtopic.php?f=35&t=5201&p=197789#p197789
audio files (for me WAV and MP3 files) can be linked to an image.

----------------------
I have recorded thousands of sound files with moods and comments on my pictures since 2002.
Question:
What do I have to set so that the audio files with the same name as the picture are played in view mode?
The explanations and sounds (MP3 files) for each picture are displayed in an empty window without the picture after clicking [next, next picture].
(The fact that the files are displayed in image management mode is certainly functional and o.k.). )
I have experimented with the filter settings, setting visible/invisible (in the file system) etc . . . so far without success

----------------------
Problem #2
- The *.WAV files are not played, the play list seems to be frozen.
Hhhmmm . . I could convert these approx. 2500 files to *.MP3.
(terrible idea, but would be a solution)

Question:
What would I have to set to play these WAV files in an external player (e.g. Win-Mediaplayer) in view mode ?
( I have only been able to do this in image management mode by double-clicking on the thumbnail,
but unfortunately not in view/presentation mode )

many thanks in advance
Gerald
Attachments
Example_Files.zip
(105.54 KiB) Downloaded 55 times
User avatar
xnview
Author of XnView
Posts: 46236
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: audio play automatically in the background when opening picture

Post by xnview »

Please try to replace the ffmpeg (lite version) from default version
Pierre.
dlareg
Posts: 5
Joined: Thu Apr 18, 2024 8:11 pm

Re: audio play automatically in the background when opening picture

Post by dlareg »

Hello Pierre,

thanks for your quick reply.
I have "ffmpeg", i.e. the contents of the folder "\ffmpeg-master-windows-desktop-vs2022ltl-default\bin\x86\"
in
- c:\Users\MyUserName\AppData\Roaming\XnViewMP\AddOns\
and
- c:\Program Files\XnViewMP\AddOn\
copied into it.

Regrettably without the desired success. Hhhmmm . . .
- What do I have to enter in XnViewMP so that the sound files are played automatically when an image is opened?

Thank you for your patience
Gerald
jkm
Posts: 11
Joined: Sat May 11, 2024 12:43 am

Re: audio play automatically in the background when opening picture

Post by jkm »

I agree that this would be a wonderful and unique feature.

Many cameras allow the recording of an "audio note" when an image is taken. This audio note is saved as a .WAV or .MP3 file alongside the jpeg or raw file. It's essentially an audio sidecar file.

What the OP (and I) are looking for is if XnView MP is browsing a folder and sees two files like this:
P2136819.JPG
P2136819.WAV

that if you open the JPG file in the browser, the audio WAV file automatically plays.

This would really be terrific if it could be added, please!
User avatar
xnview
Author of XnView
Posts: 46236
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: audio play automatically in the background when opening picture

Post by xnview »

you need to replace ffmpeg-6.dll in the folder of xnviewmp.exe
Pierre.
jkm
Posts: 11
Joined: Sat May 11, 2024 12:43 am

Re: audio play automatically in the background when opening picture

Post by jkm »

xnview wrote: Mon May 13, 2024 7:12 am you need to replace ffmpeg-6.dll in the folder of xnviewmp.exe
Thank you, I did, but it does not address the problem.

I did what you said, and replaced the ffmpeg-6.dll in the folder with xnviewmp.exe. I used the dll from ffmpeg-6.0-windows-desktop-vs2022-default.7z

Doing so does not make the audio sidecar file play automatically. This is not a compatibility problem: the stock ffmpeg-6.dll you ship with XNviewMP will play the sound file, if and only if you click specifically on the sound file and then click the play button.

If you look at my previous post, what we are looking for is if you double-click the JPEG, the JPEG should open and display in a tab, while simultaneously the sidecar wav/mp3 file automatically plays in the background.
dlareg
Posts: 5
Joined: Thu Apr 18, 2024 8:11 pm

Re: audio play automatically in the background when opening picture

Post by dlareg »

Hello Pierre,

thanks for the information.

I also copied ffmpeg-7.dll instead of ffmpeg-6.dll into the EXE folder and renamed it to ffmpeg-6.dll.
Unfortunately, XnView MP crashes with this combination.
Obviously you meant something else.

What must be entered in the settings so that the
audio files belonging to the images are played automatically when the images are displayed?

Many thanks for your patience,
Gerald
User avatar
xnview
Author of XnView
Posts: 46236
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: audio play automatically in the background when opening picture

Post by xnview »

i've tried with this one, and it works... You need to extract other .dlls too
Pierre.
dlareg
Posts: 5
Joined: Thu Apr 18, 2024 8:11 pm

Re: audio-file play automatically in the background when opening picture

Post by dlareg »

Hello Pierre,

thank you, now XnView MP plays absolutely everything.
Even all the old wild media data that I have accumulated so far are displayed/played without any problems.
- Great -


my main problem
--> Simultaneous playback of sound files with the same name when displaying an image <--

Do I have to write a script for this function?
Forgive me, unfortunately I have not found any information or a link for integrating scripts.
I am a pensioner, I programmed TurboPascal 30 years ago . . .

- Which scripting language is it ? GhostScript ?
- how are scripts integrated and saved in XnView MP ?

many thanks in advance
Gerald
Post Reply