Click here to Skip to main content
11,706,142 members (46,757 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Video audio
CreateMediaSource( lpctszInput_i, &pSource );
AUDIO_ATTRIBUTES_t stAudioParam;
SubTypeGUID = MFAudioFormat_MP3;
ContainerTypeGUID = MFTranscodeContainerType_MP3;
 
hrStatus = MFCreateTranscodeProfile( &pProfile );
hrStatus = MFCreateAttributes( &pAudioAttributes, 7 );
hrStatus = pAudioAttributes->SetGUID( MF_MT_SUBTYPE, SubTypeGUID );
hrStatus = pAudioAttributes->SetUINT32( MF_MT_AUDIO_BITS_PER_SAMPLE, uBitsPerSample );
hrStatus = pAudioAttributes->SetUINT32( MF_MT_AUDIO_SAMPLES_PER_SECOND, uSamplesPerSec );
hrStatus = pAudioAttributes->SetUINT32( MF_MT_AUDIO_NUM_CHANNELS, uNumChannels );
hrStatus = pAudioAttributes->SetUINT32( MF_MT_AUDIO_AVG_BYTES_PER_SECOND, uBytesPerSec );
hrStatus = pAudioAttributes->SetUINT32( MF_MT_AUDIO_BLOCK_ALIGNMENT, uAudioBlockAllign );
hrStatus = pAudioAttributes->SetUINT32( MF_MT_AAC_AUDIO_PROFILE_LEVEL_INDICATION, uProfile );
hrStatus = pProfile->SetAudioAttributes( pAudioAttributes );
hrStatus = MFCreateAttributes( &pContainer, 1 );
hrStatus = pContainer->SetGUID( MF_TRANSCODE_CONTAINERTYPE, ContainerTypeGUID );
hrStatus = pProfile->SetContainerAttributes( pContainer );
hrStatus = MFCreateTranscodeTopology( pSource, lpctszOutput_i, pProfile, &pTopology );

But MFCreateTranscodeTopology return MF_E_NOT_FOUND error. Whether I need to set any other parameters? Why this error occurred?
Thanks in Advance...
Posted 2-Oct-12 22:24pm
Edited 2-Oct-12 22:42pm
(no name)183.1K
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 196
1 Sergey Alexandrovich Kryukov 151
2 ppolymorphe 61
3 Inimicos 60
4 ProgramFOX 50
0 OriginalGriff 9,050
1 Sergey Alexandrovich Kryukov 8,417
2 CPallini 5,189
3 Maciej Los 4,726
4 Mika Wendelius 3,636


Advertise | Privacy | Mobile
Web01 | 2.8.150819.1 | Last Updated 3 Oct 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100