Skip to content

Commit

Permalink
Fix indices for subcommand in Vulkan when resolving command groups (#…
Browse files Browse the repository at this point in the history
…1223)

* Fix indices for subcommand in Vulkan when resolving command groups

Fix #1214

Turns out we just need to remove two historical lines of code

* remove unused variables
  • Loading branch information
Qining authored Oct 18, 2017
1 parent 2afd0b2 commit b007250
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions gapis/resolve/command_tree.go
Original file line number Diff line number Diff line change
Expand Up @@ -114,17 +114,13 @@ func CommandTreeNode(ctx context.Context, c *path.CommandTreeNode) (*service.Com
case api.SubCmdRoot:
count := uint64(1)
g := ""
commandStart := append([]uint64{}, item.Id...)
commandEnd := append([]uint64{}, item.Id...)
if len(item.Id) > 1 {
g = fmt.Sprintf("%v", item.Id)
commandStart = append(commandStart, uint64(0))
commandEnd = append(commandEnd, uint64(item.SubGroup.Count()-1))
count = uint64(item.SubGroup.Count())
}
return &service.CommandTreeNode{
NumChildren: item.SubGroup.Count(),
Commands: cmdTree.path.Capture.SubCommandRange(commandStart, commandEnd),
Commands: cmdTree.path.Capture.SubCommandRange(item.Id, item.Id),
Group: g,
NumCommands: count,
}, nil
Expand Down

0 comments on commit b007250

Please sign in to comment.