diff options
author | deva <deva> | 2005-05-25 15:36:05 +0000 |
---|---|---|
committer | deva <deva> | 2005-05-25 15:36:05 +0000 |
commit | d4017394ba8868e5d44b5cc01a59c100cbaf953f (patch) | |
tree | 81345aa9521c3397363b6c3afe1ef19bb860c776 /src | |
parent | 0e7d7464b0f87ce82fa5c48e350a2d51fcef4882 (diff) |
Added mpeg4 encoding to the encoders, controllable by the config file.R0_2_3
Diffstat (limited to 'src')
-rw-r--r-- | src/mov_encoder.cc | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/src/mov_encoder.cc b/src/mov_encoder.cc index 0a478fc..e052893 100644 --- a/src/mov_encoder.cc +++ b/src/mov_encoder.cc @@ -39,6 +39,9 @@ /* * $Log$ + * Revision 1.25 2005/05/25 15:36:05 deva + * Added mpeg4 encoding to the encoders, controllable by the config file. + * * Revision 1.24 2005/05/22 15:49:22 deva * Added multithreaded encoding support. * @@ -205,8 +208,27 @@ MovEncoder::MovEncoder(sem_t *r_sem, static const char profilename[] = "MIaV\0"; fame_par.profile = profilename; // profile name fame_par.total_frames = 0; // total number of frames - // fame_par.stats = NULL; // No need for statistics at the moment + if(strcmp(config->readString("encoding_codec")->c_str(), "mpeg4") == 0) { + + fprintf(stderr, "Using mpeg4 compression\n"); fflush(stderr); + fame_object_t *object; + + object = fame_get_object(fame_context, "profile/mpeg4/simple"); + if(object) fame_register(fame_context, "profile", object); + + } else if(strcmp(config->readString("encoding_codec")->c_str(), "mpeg1") == 0) { + + fprintf(stderr, "Using mpeg1 compression\n"); fflush(stderr); + fame_object_t *object; + + object = fame_get_object(fame_context, "profile/mpeg1"); + if(object) fame_register(fame_context, "profile", object); + + } else if(strcmp(config->readString("encoding_codec")->c_str(), "mpeg1") == 0) { + } else { + fprintf(stderr, "Using default (mpeg1) compression\n"); fflush(stderr); + } fame_init(fame_context, &fame_par, fame_buffer, FAME_BUFFER_SIZE); |