Conversation
|
Did you try to close the video after encoding? I guess the ADM_paramList.cpp part is missing: index dc2a65bc3..27caccc96 100644
--- a/avidemux_core/ADM_coreUtils/src/ADM_paramList.cpp
+++ b/avidemux_core/ADM_coreUtils/src/ADM_paramList.cpp
@@ -159,6 +159,11 @@ static bool compressReadFromString(COMPRES_PARAMS *params,const char *str)
params->mode=COMPRESS_SAME;
return true;
}
+ if(!strcasecmp(str,"LOSSLESS"))
+ {
+ params->mode=COMPRESS_LOSSLESS;
+ return true;
+ }
// all other are in the form a=b
strcpy(tmp,str);
char *s=tmp;
@@ -197,8 +202,9 @@ bool ADM_compressWriteToString(COMPRES_PARAMS *params, char **str)
case COMPRESS_SAME: sprintf(tmp,"SAME");break;
case COMPRESS_2PASS_BITRATE: sprintf(tmp,"2PASSBITRATE=%" PRIu32,params->avg_bitrate);break;
case COMPRESS_AQ: sprintf(tmp,"AQ=%" PRIu32,params->qz);break;
+ case COMPRESS_LOSSLESS: sprintf(tmp,"LOSSLESS");break;
default:
- ADM_error("Unknown compressin mode \n");
+ ADM_error("Unknown compression mode\n");
return false;
}
*str=ADM_strdup(tmp); |
|
Thanks. It just needed a minor tweak to work properly. |
| case COMPRESS_SAME: sprintf(tmp,"SAME");break; | ||
| case COMPRESS_2PASS_BITRATE: sprintf(tmp,"2PASSBITRATE=%" PRIu32,params->avg_bitrate);break; | ||
| case COMPRESS_AQ: sprintf(tmp,"AQ=%" PRIu32,params->qz);break; | ||
| case COMPRESS_LOSSLESS: sprintf(tmp,"LOSSLESS=1");break; |
There was a problem hiding this comment.
For me, it feels somewhat awkward to write "general.params=LOSSLESS=1" when "general.params=LOSSLESS=0" means exactly the same. Could you please explain the rationale?
With "general.params=LOSSLESS" we can exit compressReadFromString() early like in case of "general.params=SAME" (just not really used anywhere) and it is free from ambiguity, IMHO.
There was a problem hiding this comment.
In my Q&D version to try out the lossless mode, I ended up with the same changes here, but, for a proper implementation, I'd love to see all options overridden by lossless mode systematically disabled. Maybe not trying to rush it in 2.8.2 but doing it thoroughly right thereafter?
No description provided.