Skip to content

Conversation

@thynetruly
Copy link

Hello! I emailed the Live2D team last year about my comment translation script since I had successfully used it to translate the comments throughout the Live2D Cubism SDK for Native files into English for my team's internal use. Hope this can help the Live2D developer community by increasing accessibility to the API documentation! Please let me know if there are any changes, proofreading, or editing needed since I retained the original file's grammar. I tried very hard to treat this as a reference document with all of the information from the source PDF file properly reflected. I'm also willing to port the Japanese PDF, so please let me know if you need that.

Copilot AI review requested due to automatic review settings August 24, 2025 08:35
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR converts the Live2D Cubism Core API Reference from PDF format to Markdown, making the documentation more accessible to developers. The conversion includes all content from the original PDF with proper formatting, code snippets, and internal navigation links.

  • Converted the entire NativeCoreAPIReference_en_r13.pdf to Markdown format
  • Maintained all original content including changelog, API descriptions, and code examples
  • Added proper Markdown formatting for tables, code blocks, and navigation links

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment on lines 740 to 750
// If partParentIndex = -1, parent is empty.
// If partParentIndex >= 0, the value of parentPartIndices is the Index of the parent.
for (int i = 0; i < partCount; ++i)
{
if(partParentIndex[i] == -1)
{
printf("partParentIndex[%d]:%s does not have a parent part.", i, partIds[i]);
}
else
{
printf("partParentIndex[%d]:Parent part of %s is %s.", i, partIds[i], partIds[parentPartIndices[i]]);
Copy link

Copilot AI Aug 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Variable name inconsistency: 'partParentIndex' is used here but 'parentPartIndices' is declared on line 738. This should be 'parentPartIndices[i]' to match the declared variable.

Suggested change
// If partParentIndex = -1, parent is empty.
// If partParentIndex >= 0, the value of parentPartIndices is the Index of the parent.
for (int i = 0; i < partCount; ++i)
{
if(partParentIndex[i] == -1)
{
printf("partParentIndex[%d]:%s does not have a parent part.", i, partIds[i]);
}
else
{
printf("partParentIndex[%d]:Parent part of %s is %s.", i, partIds[i], partIds[parentPartIndices[i]]);
// If parentPartIndices[i] = -1, parent is empty.
// If parentPartIndices[i] >= 0, the value of parentPartIndices is the Index of the parent.
for (int i = 0; i < partCount; ++i)
{
if(parentPartIndices[i] == -1)
{
printf("parentPartIndices[%d]:%s does not have a parent part.", i, partIds[i]);
}
else
{
printf("parentPartIndices[%d]:Parent part of %s is %s.", i, partIds[i], partIds[parentPartIndices[i]]);

Copilot uses AI. Check for mistakes.
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here is the original code from the PDF document for reference. The lines with the potential discrepancy/inconsistency are 4 onward:

// Getting the ID list of parts.
const char** partIds =csmGetPartIds(model);
// Getting the parent of the index list of parts.
const int* parentPartIndices =csmGetPartParentPartIndices(model);
// If partParentIndex = -1, parent is empty.
// If partParentIndex> = 0, the value of parentPartIndices is the Index of the parent.
for (int i = 0; i < partCount; ++i)
{
if(partParentIndex[i] == -1)
{
printf("partParentIndex[%d]:%s does not have a parent part.
"
,i,partIds[i]);
}
{
else
printf("partParentIndex[%d]:Parent part of %s is %s.
"
,i,partIds[i],partIds[parentPartIndices[i]]);
}
}

@wada-at-live2d-com wada-at-live2d-com self-requested a review August 25, 2025 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant