Wwise SDK 2019.2.15
|
Resource file (with .rc as the extension) is a file format used to describe the resources used by the plug-in to create a custom graphical interface. An easy way to manage Resource files is to use the Visual Studio Editor tool, which lets you drag-and-drop widgets on a canvas to build the GUI. Here are the steps to create a Resource file for a new plug-in.
First of all, create a new plug-in with wp.py (if you're not familiar with the development tools, refer to 개발 도구 사용하기).
Answer the prompts and when the plug-in is created, change directory to the project folder and call premake
.
Open the generated solution file (.sln) in Visual Studio 2019, make sure that the project folder is highlighted (do not confuse this with the solution folder, otherwise the Add New Item
choices will be different) and select Add New Item...
in the Project menu. In the dialog window, select Resource
in the left column, and then Resource File (.rc)
in the middle pane. This will create a file named Resource.rc
in the WwisePlugin
folder of your project.
In the Resource View, right-click on the Resource.rc
file and select Add Resource
. In the Add Resource
window, select Dialog and click the New button.
참고: When you create a DIALOG window, make sure you set the following styles in its Properties:
|
Using the Toolbox
tab on the left side of the interface, you should now be able to drag-and-drop widgets on the canvas to compose the graphical interface of the plug-in. Saving the project will update the Resource file.
To include the Resource.rc
file in your project, all you have to do is to call premake again. Then, the next time you build your plug-in, a file called resource.h
will be automatically generated based on the Resource file:
To tell the plug-in to use the custom interface, you need to override a few methods provided by AK::Wwise::IAudioPlugin
. In PluginNamePlugin.h
, include resource.h
, add the method signatures and create a private variable to store a window handle:
In PluginNamePlugin.cpp
, add the implementation of these methods:
Finally, add resource files to PremkaePlugin.lua
:
Recompile and load the plug-in in a Wwise project. You should now see your custom graphical interface.
프로젝트를 등록하세요. 아무런 조건이나 의무 사항 없이 빠른 시작을 도와드리겠습니다.
Wwise를 시작해 보세요