# Playing mpeg radio station on PS4

**URL:** <https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368>\
**Category:** FMOD Engine\
**Tags:** ue4, ps5\
**Created:** [December 4, 2024, 10:08am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368 "2024-12-04T10:08:06Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![stargx](https://avatars.discourse-cdn.com/v4/letter/s/eb9ed0/32.png) [@stargx](https://qa.fmod.com/u/stargx)\
**Post date:** [December 4, 2024, 10:08am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/1 "2024-12-04T10:08:06Z")

</div>

Hi,  
I’m tyring to play a radio stream on PS4, but I’m getting a FMOD\_ERR\_FORMAT error from system-\>playSound(…).

The stream is mpeg.

Is there something I need to enable on PS4 to get this to work?

Here’s the url: [yp.shoutcast.com/sbin/tunein-station.pls?id=99497996](http://yp.shoutcast.com/sbin/tunein-station.pls?id=99497996)

Any ideas?

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [December 4, 2024, 11:53pm UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/2 "2024-12-04T23:53:43Z")

</div>

Hi,

Thanks for sharing the link. Testing it in our examples: `fmodstudioapi20225ps4_sdk11.500-installer_147358\api\core\examples\vs2019\examples.sln` → `net_stream`  
I was able to hear the stream on our test machine.

Could I please grab some more info:

- FMOD Studio and integration versions
- Unreal Engine version exactly

---

<div class="post-metadata">

**Author:** ![stargx](https://avatars.discourse-cdn.com/v4/letter/s/eb9ed0/32.png) [@stargx](https://qa.fmod.com/u/stargx)\
**Post date:** [December 5, 2024, 9:34am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/3 "2024-12-05T09:34:38Z")

</div>

Thanks for testing.

I’m on Unreal 4.27 and FMOD studio api 2019 ps4 sdk 10.500

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [December 6, 2024, 3:29am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/4 "2024-12-06T03:29:26Z")

</div>

Thank you for the information.

Just to confirm the FMOD version, was it `2.02.19`? As we don’t have `SDK 10.500` available on our download page.

It can be confirmed in UE by checking the about FMOD under the `Help` toolbar:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/6/6cda266feb70803e56b14dafd9cbaaf91b6c1467.jpeg)  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/2/2b9ed26488f1b15afe60bcf096685f8c6a7a27b7.png).

---

<div class="post-metadata">

**Author:** ![stargx](https://avatars.discourse-cdn.com/v4/letter/s/eb9ed0/32.png) [@stargx](https://qa.fmod.com/u/stargx)\
**Post date:** [December 6, 2024, 9:55am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/5 "2024-12-06T09:55:19Z")

</div>

Ah, thanks. I’m on 2.02.19

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [December 9, 2024, 12:27am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/6 "2024-12-09T00:27:20Z")

</div>

Thanks for confirming that. Can you confirm where you downlaoded the integration from for SDK `10.500`? I cannot find it on our downlaod page:

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/b/b6dc7e680562aa93452cd6a55ce1728a8f472cc9.png)  
Thanks

---

<div class="post-metadata">

**Author:** ![stargx](https://avatars.discourse-cdn.com/v4/letter/s/eb9ed0/32.png) [@stargx](https://qa.fmod.com/u/stargx)\
**Post date:** [December 9, 2024, 10:04am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/7 "2024-12-09T10:04:19Z")

</div>

![FMOD sdk](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/0/007c01ef54884d0aaaf0074822faf955df08bebf.jpeg)

Ah, so I’m not sure now. I have FMOD Engine for PlayStation 4 (SDK 10.500) - See screen shot. But I’m not sure I used that.

I also have fmodstudio20219ue4.27ps4\_sdk9.000.zip (See bottom of screen shot)

So I could be on SDK 9.000. Does that sound right?

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [December 10, 2024, 4:15am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/8 "2024-12-10T04:15:15Z")

</div>

Hi, that does sound right. Thank you for confirming that.

Would it be possible to share the code you are using to play the stream in your Unreal project?

---

<div class="post-metadata">

**Author:** ![stargx](https://avatars.discourse-cdn.com/v4/letter/s/eb9ed0/32.png) [@stargx](https://qa.fmod.com/u/stargx)\
**Post date:** [December 10, 2024, 1:32pm UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/9 "2024-12-10T13:32:01Z")

</div>

Sure, here is my code. I’ve squished it into 1 function and checked it still comes up with the same error:

```auto
void Caudio::init()
{
	// init core api

	FMOD_RESULT result;
	result = FMOD::System_Create(&system); // Create the main system object.
	if (result != FMOD_OK)
	{
		showError("System_Create", result);
		return;
	}

	// Set the DSP buffer size to 1024 samples
	unsigned int bufferLength = 1024; // Number of samples per DSP processing callback
	int numBuffers = 4; // Number of buffers (default is usually 4)
	result = system->setDSPBufferSize(bufferLength, numBuffers);
	if (result != FMOD_OK)
	{
		showError("setDSPBufferSize", result);
		return;
	}

	result = system->init(512, FMOD_INIT_NORMAL, 0); // Initialize FMOD.
	if (result != FMOD_OK)
	{
		showError("system->init", result);
		return;
	}

	// Create music group
	system->createChannelGroup("BHMusic", &musicChannelGroup);

	// Test play radio station
	result = system->createStream("http://yp.shoutcast.com/sbin/tunein-station.pls?id=99497996", FMOD_DEFAULT, NULL, &musicSound);
	if (result != FMOD_OK)
	{
		showError("playMusicW HTTP", result);
		return;
	}

	result = system->playSound(musicSound, musicChannelGroup, false, &musicChannel);
	if (result != FMOD_OK)
	{
		showError("playMusicW - PlaySound", result);
		return;
	}
}

```

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [December 17, 2024, 5:09am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/10 "2024-12-17T05:09:08Z")

</div>

Thank you for the code.

Could you please try updating the `createStream()` function with the following

```auto
memset(&exinfo, 0, sizeof(FMOD_CREATESOUNDEXINFO));
exinfo.cbsize = sizeof(FMOD_CREATESOUNDEXINFO);
exinfo.filebuffersize = 1024 * 16; /* Increase the default file chunk size to handle seeking inside large playlist files that may be over 2kb. */
// Test play radio station
result = system->createStream("http://yp.shoutcast.com/sbin/tunein-station.pls?id=99497996", FMOD_CREATESTREAM | FMOD_NONBLOCKING, &exinfo, &musicSound);
if (result != FMOD_OK)
{
    showError("playMusicW HTTP", result);
    return;
}

```

Two issues I identified was missing the `exinfo` ([FMOD Engine | Core API Reference - FMOD\_CREATESOUNDEXINFO](https://fmod.com/docs/2.02/api/core-api-system.html#fmod_createsoundexinfo)) which contains information about the sound to be played and updating the flags used when creating the sound ([FMOD Engine | Core API Reference - FMOD\_MODE](https://fmod.com/docs/2.02/api/core-api-common.html#fmod_mode)).

Let me know if that works.

---

<div class="post-metadata">

**Author:** ![stargx](https://avatars.discourse-cdn.com/v4/letter/s/eb9ed0/32.png) [@stargx](https://qa.fmod.com/u/stargx)\
**Post date:** [January 6, 2025, 10:48am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/11 "2025-01-06T10:48:21Z")

</div>

In the playSound call I now get the error FMOD\_ERR\_NOTREADY.  
If I remove the FMOD\_NONBLOCKING options, I still get the FMOD\_ERR\_FORMAT error.

So that code didn’t seem to change anything on my end. Any ideas?

---

<div class="post-metadata">

**Author:** ![Connor\_FMOD](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/connor_fmod/32/3685_2.png) [@Connor\_FMOD](https://qa.fmod.com/u/Connor_FMOD)\
**Post date:** [January 9, 2025, 1:16am UTC](https://qa.fmod.com/t/playing-mpeg-radio-station-on-ps4/22368/12 "2025-01-09T01:16:50Z")

</div>

Thank you for testing that for me.

I think we have found a bug with UE. I will create a task to investigate the issue further.

An option may be using an `FMODAudio` component rather than playing it our self.

1. First we need to create the Programmer instrument  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/f/f5b4352d601d07f43da6bb65c9285669bc95d06f.png)  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/8/8ca3b05ec24219fbf74c6ed4b68f349612bab5f1.png)
2. Trigger it using an `FMODAudio` component  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/c/c6b08b733f5a1bb8d0facd5ab1c029e803621560.png)
3. Set the `Programmer Sound Name` as the URL  
 ![image](https://canada1.discourse-cdn.com/flex036/uploads/fmod/original/2X/b/b76e31877a65bb5b605a8f5e48043ff948a54d7a.png)

Hope this helps!
