C 공유 라이브러리 통합
패키징된 MATLAB® 함수를 C 애플리케이션에 통합
MATLAB Compiler SDK™를 사용하면 MATLAB 함수로부터 C 공유 라이브러리를 만들 수 있습니다.
mxArray
API를 사용하는 공유 라이브러리에는 C 스타일 함수를 사용하여 MATLAB Runtime을 초기화하고, 패키징된 MATLAB 함수를 MATLAB Runtime으로 불러오고, C 코드와 MATLAB Runtime 간에 전달되는 데이터를 관리하는 인터페이스가 있습니다. 예제는 Create a C Shared Library with MATLAB Code 항목을 참조하십시오.
함수
compiler.build.cSharedLibrary | Create C shared library (R2021a 이후) |
compiler.build.CSharedLibraryOptions | Options for building C shared libraries (R2021a 이후) |
compiler.build.Results | Compiler build results object (R2020b 이후) |
mbuild | Compile and link source files against MATLAB generated shared libraries |
C API
mclmcrInitialize | Initialize the MATLAB Runtime proxy library |
mclInitializeApplication | Set up application state shared by all MATLAB Runtime instances created in current process |
mclTerminateApplication | Close MATLAB Runtime-internal application state |
<library>Initialize[WithHandlers] | Initialize MATLAB Runtime instance associated with
|
<library>Terminate | Free all resources allocated by MATLAB Runtime instance associated with
|
mclRunMain | Mechanism for creating identical wrapper code across all platforms |
mclIsMCRInitialized | Determine if MATLAB Runtime has been properly initialized |
mclWaitForFiguresToDie | Enable deployed applications to process graphics events so that figure windows remain displayed |
mclGetLastErrorMessage | Last error message from unsuccessful library initialization or MATLAB function call |
mclGetLogFileName | Retrieve name of log file used by MATLAB Runtime |
mclIsJVMEnabled | Determine if MATLAB Runtime was started with instance of Java Virtual Machine (JVM) |
mclIsNoDisplaySet | Determine if -nodisplay mode is enabled |
도움말 항목
C 공유 라이브러리 생성 및 구현하기
- Create a C Shared Library with MATLAB Code
Learn how to create a C shared library.
C 드라이버 애플리케이션으로 C 공유 라이브러리 통합하기
- Call MATLAB Compiler SDK API Functions from C/C++
Use MATLAB Compiler SDK shared library functions in C and C++ code. - Use Multiple Shared Libraries in Single Application
Use multiple generated shared libraries in a single C/C++ application.
C 공유 라이브러리 문제 해결
- Compilation Failures
List of possible failures during compilation. - Testing Failures
List of possible failures during testing. - Deployment Failures
List of possible failures during deployment. - Troubleshoot mbuild
Issues involving thembuild
utility and creating standalone applications.