Zum Inhalt springen
SoulFire LogoSoulFire

Render bot POV

Diese Anleitung gibt es nur auf Englisch.

GET
/v1/instances/{instance_id}/bots/{bot_id}/pov:render

Renders the bot's point-of-view as a PNG image using headless Vulkan. The bot must be online with a valid player and level. Uses the bot's current render distance setting.

Authorization

headerAuthorizationBearer <JWT>

Preferred API authentication. Use a JWT with the api audience.

Path Parameters

instance_id*string

The UUID of the SoulFire instance containing the bot.

Formatuuid
bot_id*string

The profile UUID of the bot to render POV for.

Formatuuid

Query Parameters

width*integer

Desired image width in pixels. Default: 854 (if 0 or not provided). Maximum: 1920 (values above this are clamped). Minimum: 1 (values below this are clamped).

Formatint32
height*integer

Desired image height in pixels. Default: 480 (if 0 or not provided). Maximum: 1080 (values above this are clamped). Minimum: 1 (values below this are clamped).

Formatint32
max_distance?|

Maximum render distance in blocks. Default: the bot's current render distance setting. Maximum: 2048 (values above this are clamped).

fov?||

Vertical field of view in degrees. Default: the renderer default FOV. Valid range: 1.0 to 179.0.

camera_x?||

Optional camera X coordinate. Defaults to the bot's current eye position.

camera_y?||

Optional camera Y coordinate. Defaults to the bot's current eye position.

camera_z?||

Optional camera Z coordinate. Defaults to the bot's current eye position.

y_rot?||

Optional yaw in degrees. Defaults to the bot's current yaw.

x_rot?||

Optional pitch in degrees. Defaults to the bot's current pitch.

include_hud?|

Whether to render the HUD overlay. Default: true.

include_hands?|

Whether to render first-person hands and held items. Default: true.

include_debug_trace?boolean

Whether to include renderer debug counters in the response. Default: false.

Response Body

Response containing the rendered POV image.

application/json
  1. response

Response containing the rendered POV image.

imageBase64*string

Base64-encoded PNG image data. Decode with standard Base64 decoder to get raw PNG bytes. See metadata for the effective render settings used.

imageMimeType*string

MIME type for image_base64.

metadata*

Effective render settings used for this frame.

debugTrace?|

Optional debug counters and samples. Present only when include_debug_trace is true.

Example Request
curl -X GET 'http://127.0.0.1:38765/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/bots/497f6eca-6276-4993-bfeb-53cbbbba6f08/pov:render?width=0&height=0'
Example Response
{
  "imageBase64": "string",
  "imageMimeType": "string",
  "metadata": {
    "width": 0,
    "height": 0,
    "fov": 0.1,
    "maxDistance": 0,
    "cameraX": 0.1,
    "cameraY": 0.1,
    "cameraZ": 0.1,
    "yRot": 0.1,
    "xRot": 0.1,
    "includedHud": true,
    "includedHands": true
  },
  "debugTrace": {
    "renderId": "string",
    "chunksConsidered": "string",
    "chunksLoaded": "string",
    "sectionsVisible": "string",
    "sectionsMeshed": "string",
    "sectionCacheHits": "string",
    "sectionCacheMisses": "string",
    "blockQuads": "string",
    "entitiesConsidered": "string",
    "entitiesVisible": "string",
    "billboards": "string",
    "weatherBillboards": "string",
    "vanillaBlockGeometryHits": "string",
    "vanillaBlockGeometryFallbacks": "string",
    "resourceBlockGeometryFallbacks": "string",
    "inventoryIconIgnored": "string",
    "unknownRenderPipelines": "string",
    "runtimeTextureMirrorSkips": "string",
    "opaqueTriangles": "string",
    "cutoutTriangles": "string",
    "translucentTriangles": "string",
    "worldCollectNanos": "string",
    "dynamicCollectNanos": "string",
    "rasterNanos": "string",
    "totalNanos": "string",
    "textSubmissions": "string",
    "textSamples": [
      {
        "source": "string",
        "text": "string",
        "shadow": true,
        "displayMode": "string",
        "light": 0,
        "color": "string",
        "backgroundColor": "string",
        "outlineColor": "string"
      }
    ],
    "notableEvents": [
      "string"
    ],
    "detailedFailures": [
      "string"
    ]
  }
}

War diese Seite hilfreich?