Anybody know how to control inside the program language how many core the software will be use? For example, to limit to use only two cores of processor.
Unfortunately not. Media SDK SW processing (encode/decode/VPP) will create threads corresponding to the number of logical cores on the machine. There was previously a NumThreads parameter that provided some control but this parameter has been deprecated for various reasons.