Click here to Skip to main content
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 23:24pm
Edited 2-Oct-12 23:42pm
(no name)181.5K
v2

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

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 408
1 Sascha Lefévre 235
2 Maciej Los 180
3 Abhinav S 170
4 Richard Deeming 155
0 Sergey Alexandrovich Kryukov 7,096
1 OriginalGriff 6,395
2 Maciej Los 2,782
3 Abhinav S 2,732
4 Peter Leow 2,694


Advertise | Privacy | Mobile
Web02 | 2.8.150414.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