1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
2<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-US" lang="en-US">
3<!-- InstanceBegin template="/Templates/default_template.dwt" codeOutsideHTMLIsLocked="false" -->
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
6<meta http-equiv="Content-Style-Type" content="text/css" />
7<!-- InstanceBeginEditable name="CSS の相対パス指定" -->
8<link href="../../common/manual.css" rel="stylesheet" type="text/css" />
9<!-- InstanceEndEditable --> <!-- InstanceBeginEditable name="ページのタイトル" -->
10<title>CreativeStudio Command Line Version</title>
11<!-- InstanceEndEditable -->
12</head>
13<body>
14<div>
15  <div class="body"> <!-- InstanceBeginEditable name="本文のタイトル" -->
16    <h1>CreativeStudio Command Line Version</h1>
17    <!-- InstanceEndEditable --> <!-- InstanceBeginEditable name="本文" -->
18    <p>CreativeStudio comes with a command line version.<br /> This allows you to automate data generation and binary conversion without displaying the GUI.</p>
19    <p class="hint">We cannot provide adequate support for scripting questions at this time.<br /> We apologize for any inconvenience.</p>
20    <h2>Setting up the Command Line Version of CreativeStudio</h2>
21    <p>The CreativeStudio command line version can be found in the following location.</p>
22    <p><CODE>%NW4C_ROOT%/tools/CreativeStudio/NW4C_CreativeStudioConsole.exe</CODE></p>
23    <h3>Path Settings</h3>
24    <p>Set the <CODE>PATH</CODE> environment variable to the directory where <CODE><em>NW4C_CreativeStudioConsole.exe</em></CODE> has been installed. </p>
25    <p>If the system environment variable is not configured, you need to set the current directory to the directory where <CODE>NW4C_CreativeStudioConsole.exe</CODE> has been installed.</p>
26    <h2>Outputting a Binary File Using a Script</h2>
27    <p>This section describes a script for converting multiple intermediate files into a binary file.<br /> Enter the commands below to launch the CreativeStudio command line version and automatically run the commands specified in the script.</p>
28    <p class="system"><CODE>NW4C_CreativeStudioConsole.exe -s=&lt;path to script file&gt;</CODE></p>
29    <h3>Script File</h3>
30    <p>Run the following script file using the <CODE>NW4C_CreativeStudioConsole.exe -s</CODE> command to automatically read in the <CODE>human.cmdl</CODE> and <CODE>human.cskla</CODE> intermediate files and output the <CODE>Binary.bcres</CODE> binary file.</p>
31    <p class="system">The script file is saved using UTF-16 BOM encoding.</p>
32    <p>Sample Script File</p>
33    <img src="assets/binary_output.png" alt="Sample Script File"/>
34    <ol>
35      <li>
36        <p>Loading Files</p>
37        <p>This specifies the files for NW4C_CreativeStudioConsole to load.</p>
38        <p class="system"><CODE>CreativeStudio.Execute(&quot;FileLoad&quot;, &quot;&lt;filename to load&gt;&quot;)</CODE></p>
39        <p><CODE>FileLoad</CODE>: Use this command to load a file.</p>
40      </li>
41      <li>
42        <p>Outputting Data to a Binary File</p>
43        <p>This converts the files loaded by NW4C_CreativeStudioConsole to binary and then outputs.</p>
44        <p class="system"><CODE>CreativeStudio.Execute(&quot;FileSave&quot;, &quot;-o=&lt;filename to output&gt;&quot;, &quot;-t=nw4cBinary&quot;)</CODE></p>
45        <p><CODE>FileSave</CODE>: Use this command to save a file.<br /> <CODE>-o</CODE>: Enter the directory and filename to output.<br /> <CODE>-t</CODE>: Specify the output file type.</p>
46      </li>
47      <li>
48        <p>Initializing the Tool</p>
49        <p>This initializes the tool.</p>
50        <p class="system"><CODE>CreativeStudio.Execute(&quot;File&quot;, &quot; &quot;)</CODE></p>
51      </li>
52    </ol>
53    <p>After you initialize the tool, the script operations are done.<br /> Change the filenames used in the examples above and try converting your own intermediate files to a binary file.</p>
54    <a name="OptimizeSelectedModel" id="OptimizeSelectedModel"></a>
55    <h4>Conversion from a skeletal model to a model</h4>
56    <p>Added an sample script for loading a skeletal model from the file given below, converting to a model, and saving the result.</p>
57    <p class="system"> # Load a file.<br /> CreativeStudio.Execute(&quot;FileLoad&quot;, &quot;C:/Dir/data.cmdl&quot;)<br /> # Select a optimization target<br /> CreativeStudio.Execute(&quot;Selection&quot;, &quot;-cs=data&quot;, &quot;-s=r&quot;)<br /> # Do Optimize<br /> CreativeStudio.Execute(&quot;OptimizeSelectedModel&quot;, &quot;-cobsm&quot;)<br /> # Save the File.<br /> CreativeStudio.Execute(&quot;FileSave&quot;, &quot;-o=D:/Dir/data_result.cmdl&quot;, &quot;--type=Save&quot;, &quot;-ft=nw4cAscii&quot;, &quot;-sao&quot;)<br /> # Reset NWCS.<br /> CreativeStudio.Execute(&quot;File&quot; ,&quot;&quot;)<br /> # move to next file....</p>
58    <!-- InstanceEndEditable --> </div>
59  <div class="footer" />
60</div>
61<hr><p>CONFIDENTIAL</p></body>
62<!-- InstanceEnd -->
63</html>
64