{"record":{"id":"33d55eac4737bb3c","repo":"MonoGame/MonoGame","slug":"xma-is-not-a-supported-encoding-format-it-is-spec","errorCode":null,"errorMessage":"XMA is not a supported encoding format. It is specific to the Xbox 360.","messagePattern":"XMA is not a supported encoding format\\. It is specific to the Xbox 360\\.","errorType":"exception","errorClass":"NotSupportedException","httpStatus":null,"severity":"error","filePath":"MonoGame.Framework.Content.Pipeline/Audio/DefaultAudioProfile.cs","lineNumber":316,"sourceCode":"                        // XNA seems to preserve the bit size of the input\n                        // format when converting to PCM.\n                        if (content.Format.BitsPerSample == 8)\n                            ffmpegCodecName = \"pcm_u8\";\n                        else if (content.Format.BitsPerSample == 32 && content.Format.Format == 3)\n                            ffmpegCodecName = \"pcm_f32le\";\n                        else\n                            ffmpegCodecName = \"pcm_s16le\";\n                        ffmpegMuxerName = \"wav\";\n                        //format = 0x0001; /* WAVE_FORMAT_PCM */\n                        break;\n                    case ConversionFormat.WindowsMedia:\n                        // Windows Media Audio 2\n                        ffmpegCodecName = \"wmav2\";\n                        ffmpegMuxerName = \"asf\";\n                        //format = 0x0161; /* WAVE_FORMAT_WMAUDIO2 */\n                        break;\n                    case ConversionFormat.Xma:\n                        throw new NotSupportedException(\n                            \"XMA is not a supported encoding format. It is specific to the Xbox 360.\");\n                    case ConversionFormat.ImaAdpcm:\n                        // ADPCM IMA WAV\n                        ffmpegCodecName = \"adpcm_ima_wav\";\n                        ffmpegMuxerName = \"wav\";\n                        //format = 0x0011; /* WAVE_FORMAT_IMA_ADPCM */\n                        break;\n                    case ConversionFormat.Aac:\n                        // AAC (Advanced Audio Coding)\n                        // Requires -strict experimental\n                        ffmpegCodecName = \"aac\";\n                        ffmpegMuxerName = \"ipod\";\n                        //format = 0x0000; /* WAVE_FORMAT_UNKNOWN */\n                        break;\n                    case ConversionFormat.Vorbis:\n                        // Vorbis\n                        ffmpegCodecName = \"libvorbis\";\n                        ffmpegMuxerName = \"ogg\";","sourceCodeStart":298,"sourceCodeEnd":334,"githubUrl":"https://github.com/MonoGame/MonoGame/blob/1d71bbd0ff4071a03caa583aa3bc56b85924a819/MonoGame.Framework.Content.Pipeline/Audio/DefaultAudioProfile.cs#L298-L334","documentation":"Thrown explicitly by DefaultAudioProfile.ConvertToFormat when ConversionFormat.Xma is requested. XMA (Xbox Media Audio) is an Xbox 360-only codec not supported by the cross-platform ffmpeg-based pipeline, so the request is rejected up front with NotSupportedException.","triggerScenarios":"Calling ConvertToFormat (or a processor/config that selects XMA) with ConversionFormat.Xma. Typically arises from a .mgcb or processor parameter inherited from an XNA/Xbox 360 project targeting XMA output.","commonSituations":"Migrating an old XNA Xbox 360 project whose content was configured for XMA. A processor defaulting to Xma. A misconfigured conversion format enum.","solutions":["Choose a supported format: ConversionFormat.Pcm, Adpcm, ImaAdpcm, WindowsMedia, Aac, Vorbis, or Mp3.","If targeting Xbox 360 specifically, use the Xbox 360 platform toolchain (not the open-source pipeline).","Update the processor's ConversionFormat property in the .mgcb to a non-XMA value.","Remove or replace any Xma references in content processor parameters."],"exampleFix":"// before\nDefaultAudioProfile.ConvertToFormat(content, ConversionFormat.Xma, quality, file); // throws\n\n// after\nDefaultAudioProfile.ConvertToFormat(content, ConversionFormat.Adpcm, quality, file);","handlingStrategy":"validation","validationCode":"// Reject XMA before conversion\nif (formatType == ConversionFormat.Xma)\n    throw new ArgumentOutOfRangeException(nameof(formatType), \"XMA is Xbox 360 only; choose a supported format.\");\nDefaultAudioProfile.ConvertToFormat(content, formatType, quality, file);","typeGuard":null,"tryCatchPattern":"try { ConvertToFormat(content, fmt, quality, file); }\ncatch (NotSupportedException ex) when (ex.Message.Contains(\"XMA\"))\n{ /* pick Pcm/Adpcm/etc. instead */ }","preventionTips":["Never select ConversionFormat.Xma outside the Xbox 360 toolchain.","Audit migrated XNA projects for stale XMA references in processor parameters.","Default new projects to PCM/ADPCM/Vorbis."],"tags":["audio","content-pipeline","xma","xbox360","unsupported-format","conversion"],"backgroundTag":null,"analyzedSha":"1d71bbd0ff4071a03caa583aa3bc56b85924a819","analyzedAt":"2026-08-13T17:10:33.625Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}