Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
201 commits
Select commit Hold shift + click to select a range
1c5f3a7
M1: add internal/engine/engine.go
pgousdal Oct 5, 2026
9491040
M1: add internal/engine/povray/povray.go
pgousdal Oct 5, 2026
95d9af0
M1: add internal/engine/povray/povray_test.go
pgousdal Oct 5, 2026
41f9b40
M1: add tests/scenes/m1-smoke.pov
pgousdal Oct 5, 2026
6cda74b
M1: add docs/M1.md
pgousdal Oct 5, 2026
80d6967
M1: route POV-Ray jobs through node protocol
pgousdal Oct 5, 2026
eb3368f
M1: gate real POV-Ray smoke render in CI
pgousdal Oct 5, 2026
c430a5a
M1: add farm capability.go
pgousdal Oct 5, 2026
0fe21f6
M1: add farm scheduler.go
pgousdal Oct 5, 2026
d8ce64e
M1: add farm scheduler_test.go
pgousdal Oct 5, 2026
a2645f6
M1: add farm FARM.md
pgousdal Oct 5, 2026
d7d74bd
M1: advertise farm engine capabilities
pgousdal Oct 5, 2026
6d1b2fd
M1: add optional idle workload workload.go
pgousdal Oct 5, 2026
25e945a
M1: add optional idle workload workload_test.go
pgousdal Oct 5, 2026
7b0b273
M1: add optional idle workload IDLE-WORKLOADS.md
pgousdal Oct 5, 2026
c925722
M1: add optional idle workload idle.example.json
pgousdal Oct 5, 2026
8bd6e96
M1: gofmt idle workload core
pgousdal Oct 5, 2026
6583fdf
M1: gofmt idle workload core
pgousdal Oct 5, 2026
17df426
M1: add idle lifecycle state machine
pgousdal Oct 5, 2026
ef8009f
M1: add idle lifecycle state machine
pgousdal Oct 5, 2026
e755ce9
M1: normalize idle lifecycle formatting
pgousdal Oct 5, 2026
63e46f2
M1: normalize idle lifecycle formatting
pgousdal Oct 5, 2026
34c700e
M1: add idle workload process adapter
pgousdal Oct 5, 2026
83fc7b5
M1: keep mining integration policy-only
pgousdal Oct 5, 2026
ec15b18
M1: test opt-in mining policy
pgousdal Oct 5, 2026
619c757
M1: add farm node registration
pgousdal Oct 5, 2026
111bffe
M1: add farm node registration
pgousdal Oct 5, 2026
76ac0a6
M1: add farm node registration
pgousdal Oct 5, 2026
4e1cb04
M1: route jobs through farm registry
pgousdal Oct 5, 2026
923d836
M1: route jobs through farm registry
pgousdal Oct 5, 2026
6f47fda
M1: add controller worker transport
pgousdal Oct 5, 2026
0ee9e0a
M1: add controller worker transport
pgousdal Oct 5, 2026
981087a
M1: integrate farm coordinator routing
pgousdal Oct 5, 2026
b12d0f2
M1: integrate farm coordinator routing
pgousdal Oct 5, 2026
3b3efc8
M1: align worker with farm wire protocol
pgousdal Oct 6, 2026
db7bfd4
M1: extract testable node server
pgousdal Oct 6, 2026
0024d33
M1: extract testable node server
pgousdal Oct 6, 2026
dc41834
M1: use shared node server in daemon
pgousdal Oct 6, 2026
03a8be9
M1: test distributed POV-Ray render end to end
pgousdal Oct 6, 2026
f420807
CI: require POV-Ray during Go integration tests
pgousdal Oct 6, 2026
e5a2cbf
CI: apply gofmt alignment to node integration test
pgousdal Oct 6, 2026
fb62172
M1: update legacy node test for shared server
pgousdal Oct 6, 2026
1e4ed52
M1: start portable Amiga submission client
pgousdal Oct 6, 2026
a43e94b
M1: start portable Amiga submission client
pgousdal Oct 6, 2026
e181dde
M1: start portable Amiga submission client
pgousdal Oct 6, 2026
a5c309b
M1: start portable Amiga submission client
pgousdal Oct 6, 2026
61899ac
CI: test portable Amiga submission client
pgousdal Oct 6, 2026
02a14c7
M1: add portable Amiga client transport boundary
pgousdal Oct 6, 2026
da3f1c7
M1: add portable Amiga client transport boundary
pgousdal Oct 6, 2026
0aae33c
M1: add portable Amiga client transport boundary
pgousdal Oct 6, 2026
2660e91
M1: declare Amiga job type at transport boundary
pgousdal Oct 6, 2026
6d4c057
CI: test Amiga client transport boundary
pgousdal Oct 6, 2026
a78887c
M1: add Amiga bsdsocket transport
pgousdal Oct 6, 2026
2774e34
M1: add Amiga bsdsocket transport
pgousdal Oct 6, 2026
4499035
M1: add Amiga bsdsocket transport
pgousdal Oct 6, 2026
ff82425
M1: add AmigaOS submission CLI
pgousdal Oct 6, 2026
fb83d68
M1: add AmigaOS submission CLI
pgousdal Oct 6, 2026
c4d09c0
CI: build Amiga client with amiga-dev
pgousdal Oct 6, 2026
a230527
Fix Bebbo bsdsocket compatibility
pgousdal Oct 6, 2026
489a4e7
Fix NDK gethostbyname signedness boundary
pgousdal Oct 6, 2026
1773e33
Use IPv4 literals in M1 Amiga transport
pgousdal Oct 6, 2026
aae9506
Parse IPv4 locally in Amiga transport
pgousdal Oct 6, 2026
a16f337
CI: link Amiga client outside bind mount
pgousdal Oct 6, 2026
1eef23d
CI: inspect Amiga binary inside build container
pgousdal Oct 6, 2026
a7966e5
Amiga: default Makefile to m68k cross compiler
pgousdal Oct 6, 2026
85c7576
Amiga: add classic runtime qualification contract
pgousdal Oct 6, 2026
b099daa
Amiga: add classic runtime smoke script
pgousdal Oct 6, 2026
dfa9770
CI: stage Amiga runtime qualification payload
pgousdal Oct 6, 2026
f70aa57
Amiga: receive complete newline-framed replies
pgousdal Oct 7, 2026
594462f
Node: add bounded asset staging protocol
pgousdal Oct 7, 2026
965210a
Test: cover node asset staging and traversal rejection
pgousdal Oct 7, 2026
9f96e54
Test: gofmt asset staging coverage
pgousdal Oct 7, 2026
79c2664
Test: finish gofmt cleanup for staging test
pgousdal Oct 7, 2026
babe706
Fix staging test source escaping
pgousdal Oct 7, 2026
1f0b924
Docs: define M1 asset staging protocol
pgousdal Oct 7, 2026
68d35b1
Amiga: define asset upload message builder
pgousdal Oct 7, 2026
2970030
Amiga: add portable base64 upload builder
pgousdal Oct 7, 2026
9d82ecf
Test: cover Amiga upload message builder
pgousdal Oct 7, 2026
0e94475
Amiga: link upload builder into client
pgousdal Oct 7, 2026
318d7a5
CI: run portable Amiga upload tests
pgousdal Oct 7, 2026
c3c486e
Amiga: expose asset upload transport API
pgousdal Oct 7, 2026
d4ac345
Amiga: add upload and STAGED response handling
pgousdal Oct 7, 2026
3cd8f86
Amiga: upload local scene before render submit
pgousdal Oct 7, 2026
f5721c2
Test: cover Amiga UPLOAD and STAGED transport
pgousdal Oct 7, 2026
5b726d6
CI: link upload builder in transport test
pgousdal Oct 7, 2026
fcdc01b
CI: link upload implementation in client transport test
pgousdal Oct 7, 2026
c9890b9
Node: allow bounded large upload messages
pgousdal Oct 7, 2026
1007fbc
Node: add bounded staged asset download
pgousdal Oct 7, 2026
bbada57
Test: cover staged asset download
pgousdal Oct 7, 2026
81be6dc
Format staged download implementation
pgousdal Oct 7, 2026
2d17f9d
Format staged download implementation
pgousdal Oct 7, 2026
f88d290
Amiga: expose staged asset download API
pgousdal Oct 7, 2026
e37897c
Amiga: implement staged asset download
pgousdal Oct 7, 2026
ac44898
Amiga: include stdio for download request formatting
pgousdal Oct 7, 2026
8337832
Test: cover Amiga staged asset download
pgousdal Oct 7, 2026
370c1a4
Node: stage POV-Ray output on worker
pgousdal Oct 7, 2026
b1b5540
Amiga: download rendered output to local path
pgousdal Oct 7, 2026
8a768b6
Test: expect worker-staged POV-Ray output
pgousdal Oct 7, 2026
7c59363
Docs: define retro preservation and modern farm scope
pgousdal Oct 7, 2026
f7855ca
Test: cover full POV-Ray wire round trip
pgousdal Oct 7, 2026
2d37c77
Docs: add landscape rendering roadmap
pgousdal Oct 7, 2026
7744677
Test: gofmt POV-Ray wire round trip
pgousdal Oct 7, 2026
4260a78
Test: decode render result with worker contract
pgousdal Oct 7, 2026
8f1f155
Docs: define remote render asset return flow
pgousdal Oct 7, 2026
5f516ee
Protocol: add bounded chunk transfer primitives
pgousdal Oct 7, 2026
45a7529
Protocol: format chunk transfer fields
pgousdal Oct 7, 2026
886228d
Test: cover multi-chunk asset round trip
pgousdal Oct 7, 2026
5b4a39e
Test: format chunk round trip coverage
pgousdal Oct 7, 2026
0234fde
Amiga: define chunked transport API
pgousdal Oct 7, 2026
49942a2
Amiga: implement chunked asset transport
pgousdal Oct 7, 2026
38d4ce9
Amiga: stream scene and output in chunks
pgousdal Oct 7, 2026
5f93bc5
Amiga: complete CLI streaming migration
pgousdal Oct 7, 2026
f277343
Amiga: reduce chunk transport stack buffers
pgousdal Oct 7, 2026
aad3967
Amiga: use 2 KiB streaming chunks
pgousdal Oct 7, 2026
dbdbfe1
Protocol: finalize chunked uploads explicitly
pgousdal Oct 7, 2026
e4883fe
Amiga: expose upload completion API
pgousdal Oct 7, 2026
d8ebabb
Amiga: implement upload completion handshake
pgousdal Oct 7, 2026
fb6fe62
Amiga: require staged upload completion
pgousdal Oct 7, 2026
85c7504
Protocol: enforce declared upload size with server sessions
pgousdal Oct 7, 2026
29b27f5
Test: reject incomplete and forged upload completion
pgousdal Oct 7, 2026
d42aa26
Test: gofmt upload completion cases
pgousdal Oct 7, 2026
3a22847
Node: reject rendering from unfinished staged uploads
pgousdal Oct 7, 2026
85897c8
Test: reject POV-Ray submission before upload completion
pgousdal Oct 7, 2026
10fa578
Test: release render block after upload completion
pgousdal Oct 7, 2026
1a20187
Node: expire abandoned chunk upload sessions
pgousdal Oct 7, 2026
1dea5fb
Node: gofmt upload session fields
pgousdal Oct 7, 2026
0507b50
Test: correct completed scene payload length
pgousdal Oct 7, 2026
1b103c6
Test: expire abandoned uploads without deleting active sessions
pgousdal Oct 7, 2026
802615d
Node: restrict upload cleanup to registered staging directories
pgousdal Oct 8, 2026
8888e82
Test: use registered staging directories for TTL cleanup
pgousdal Oct 8, 2026
060c8ff
Test: preserve non-staging directories during session cleanup
pgousdal Oct 8, 2026
b3a2e0d
Node: periodically clean up expired upload sessions
pgousdal Oct 8, 2026
f240070
Node: serialize chunk writes with session cleanup and enforce size
pgousdal Oct 8, 2026
bc05934
Test: enforce chunk upload bounds and finalized session rejection
pgousdal Oct 8, 2026
ef5624f
Node: atomically finalize uploads against concurrent cleanup and chunks
pgousdal Oct 8, 2026
057d717
Test: serialize upload completion against TTL cleanup
pgousdal Oct 8, 2026
58b6306
Node: reject symlink and non-temp staging asset paths
pgousdal Oct 8, 2026
569e2be
Test: reject unsafe staged asset references
pgousdal Oct 8, 2026
79637ab
Node: introduce cryptographic opaque asset ID registry
pgousdal Oct 8, 2026
5ad7d2b
Node: gofmt opaque asset registry imports
pgousdal Oct 8, 2026
33f8444
Protocol: expose opaque ID alongside legacy upload path
pgousdal Oct 8, 2026
a53e47b
Protocol: accept opaque asset IDs for chunk upload and finalization
pgousdal Oct 8, 2026
0618222
Test: exercise opaque asset ID upload and reject unknown IDs
pgousdal Oct 8, 2026
15e66f9
Protocol: support opaque IDs in download endpoints
pgousdal Oct 8, 2026
f2a77e6
Test: cover opaque asset ID downloads
pgousdal Oct 8, 2026
ef8c923
Node: revoke asset IDs when expired uploads are cleaned
pgousdal Oct 8, 2026
98d9a3a
Test: expired uploads revoke opaque asset IDs
pgousdal Oct 8, 2026
6a1ea74
Node: retain completed assets for 24 hours and expire IDs
pgousdal Oct 8, 2026
ec13dfa
Node: gofmt completed asset retention cleanup
pgousdal Oct 8, 2026
1fba7e3
Test: verify completed asset retention boundary
pgousdal Oct 8, 2026
b4b6840
Node: add active asset leases to defer TTL cleanup
pgousdal Oct 9, 2026
2d281b8
Node: lease opaque assets during download operations
pgousdal Oct 9, 2026
7866994
Node: lease opaque scene assets throughout POV-Ray rendering
pgousdal Oct 9, 2026
2265e50
Test: active asset lease defers completed asset cleanup
pgousdal Oct 9, 2026
44adb01
Node: defer scene lease release across POV-Ray errors
pgousdal Oct 9, 2026
3e1a286
Test: POV-Ray render with opaque scene asset ID
pgousdal Oct 9, 2026
6ea8b14
Test: gofmt opaque POV-Ray integration test
pgousdal Oct 9, 2026
06df549
Node: register POV-Ray outputs for completed asset TTL cleanup
pgousdal Oct 9, 2026
b16c751
Protocol: expose optional opaque asset ID on worker results
pgousdal Oct 9, 2026
a18093e
Protocol: format optional asset ID field
pgousdal Oct 9, 2026
7e598f8
Node: return opaque asset ID alongside legacy render output path
pgousdal Oct 9, 2026
b031a0a
Test: download rendered PNG by opaque output asset ID
pgousdal Oct 9, 2026
36ff516
Amiga: prefer opaque render asset ID with legacy output fallback
pgousdal Oct 9, 2026
27cb3e2
Amiga: declare render output asset selection helper
pgousdal Oct 9, 2026
0115833
Amiga: make opaque output selection independently testable
pgousdal Oct 9, 2026
9fb0cc9
Amiga: reuse tested output asset selection in CLI
pgousdal Oct 9, 2026
6887d70
Test: Amiga output asset ID preference and legacy fallback
pgousdal Oct 9, 2026
d82d0b3
Amiga: prefer opaque staging ID in chunked upload
pgousdal Oct 9, 2026
a8a56d7
Test: opaque upload ID preference and legacy staging fallback
pgousdal Oct 9, 2026
ac6b40e
Test: Amiga chunked upload preserves opaque asset ID end to end
pgousdal Oct 9, 2026
4c1054c
Test: Amiga opaque chunked download across blocks and EOF
pgousdal Oct 9, 2026
3362c76
Amiga: download into temporary file and publish only on success
pgousdal Oct 10, 2026
f03b712
Amiga: use native AmigaDOS Rename to avoid libc link dependency
pgousdal Oct 10, 2026
7205cb1
Amiga: expose transactional file download for testing
pgousdal Oct 10, 2026
1aa13e5
Amiga: move transactional download into reusable transport client
pgousdal Oct 10, 2026
4b1cf9c
Amiga CLI: use reusable transactional download helper
pgousdal Oct 10, 2026
bda3939
Test: failed download preserves existing output and removes partial file
pgousdal Oct 10, 2026
529c584
Test: interrupted multi-chunk download preserves output and removes p…
pgousdal Oct 10, 2026
2e7277c
Test: successful multi-chunk download publishes complete output
pgousdal Oct 10, 2026
7f9a41c
Fix portable C test syntax in completed download assertion
pgousdal Oct 10, 2026
95811bc
Test: malformed and empty download replies preserve output and clean …
pgousdal Oct 11, 2026
1dc9131
Amiga: reject malformed Base64 padding and noncanonical trailing bits
pgousdal Oct 11, 2026
37e4f39
Test: reject invalid Base64 padding and trailing bits in downloads
pgousdal Oct 11, 2026
de27c8f
Test: report failing malformed Base64 case in CI
pgousdal Oct 11, 2026
f4db63b
Fix escaped newline in diagnostic test message
pgousdal Oct 11, 2026
3225d4b
Amiga: validate Base64 padding in DOWNLOAD_CHUNK decoder
pgousdal Oct 11, 2026
b9f33f6
Amiga: reject empty completed render downloads
pgousdal Oct 11, 2026
67ec297
Test: empty EOF must not publish an empty render result
pgousdal Oct 11, 2026
7561f1f
Amiga: require explicit boolean EOF in chunk replies
pgousdal Oct 11, 2026
f9d1e80
Test: reject missing and nonboolean EOF flags in downloads
pgousdal Oct 11, 2026
6583854
Amiga: reject duplicate or contradictory EOF fields in download replies
pgousdal Oct 12, 2026
97c43b4
Test: duplicate and conflicting EOF values must fail safely
pgousdal Oct 12, 2026
a50deac
Amiga: parse top-level download fields without matching quoted text
pgousdal Oct 12, 2026
971b436
Test: reject quoted protocol lookalikes and duplicate data fields
pgousdal Oct 12, 2026
6b59646
Test: reject truncated JSON and unterminated quoted download replies
pgousdal Oct 13, 2026
6a4c41f
Test: keep valid escaped JSON outside invalid-reply cases
pgousdal Oct 13, 2026
cd21641
Test: accept escaped JSON metadata without shadowing download fields
pgousdal Oct 14, 2026
2894dd7
Amiga: reject invalid JSON string escapes and control bytes
pgousdal Oct 15, 2026
15c9b41
Test: invalid JSON escape sequences fail download safely
pgousdal Oct 15, 2026
79239db
Amiga: reject trailing garbage and unmatched JSON object braces
pgousdal Oct 15, 2026
a1f70ad
Test: reject unmatched JSON braces and trailing protocol garbage
pgousdal Oct 15, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions .github/workflows/amiga.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Amiga build

on:
push:
pull_request:

permissions:
contents: read

jobs:
amiga-build:
runs-on: ubuntu-latest
env:
AMIGA_DEV_IMAGE: ghcr.io/ploos-as/amiga-dev:edge
AMIGA_CPU_PROFILE: "68000"
steps:
- uses: actions/checkout@v4
- name: Pull amiga-dev
run: docker pull "$AMIGA_DEV_IMAGE"
- name: Verify amiga-dev contract
run: docker run --rm "$AMIGA_DEV_IMAGE" amiga-check
- name: Build and stage AmiRender Amiga client
run: |
mkdir -p amiga-runtime-payload/C amiga-runtime-payload/S
chmod 0777 amiga-runtime-payload/C
cp clients/amiga/runtime/amiga-runtime.json amiga-runtime-payload/
cp clients/amiga/runtime/run-test amiga-runtime-payload/S/
docker run --rm \
-e AMIGA_CPU_PROFILE="$AMIGA_CPU_PROFILE" \
-v "$PWD:/workspace:ro" \
-v "$PWD/amiga-runtime-payload/C:/out" \
"$AMIGA_DEV_IMAGE" \
amiga-build sh -ec 'cd /workspace/clients/amiga && make TARGET=/out/amirender CC=m68k-amigaos-gcc CFLAGS="$AMIGA_CPU_FLAGS -Os -Wall -Wextra -Werror" && test -s /out/amirender && amiga-inspect /out/amirender'
test -s amiga-runtime-payload/C/amirender
- name: Upload classic runtime payload
uses: actions/upload-artifact@v4
with:
name: amirender-m1-amiga-runtime-payload
path: amiga-runtime-payload/
if-no-files-found: error

# M1 uses :edge as the consumer-integration gate. Pin to a qualified immutable
# amiga-dev sha-* tag or digest before release qualification.
31 changes: 29 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,41 @@ on:
push:
pull_request:
jobs:
m0:
m1:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.22.x'
- run: gofmt -w cmd
- name: Install POV-Ray
run: |
sudo apt-get update
sudo DEBIAN_FRONTEND=noninteractive apt-get install -y povray
- run: gofmt -w cmd internal
- run: git diff --exit-code
- run: go test ./...
- run: go build ./cmd/amirender-node ./cmd/amirender-controller
- name: Test portable Amiga client
run: |
cc -std=c99 -Wall -Wextra -Werror -pedantic \
-Iclients/amiga/include \
clients/amiga/src/submit.c clients/amiga/tests/test_submit.c \
-o build-amiga-client-test
./build-amiga-client-test
cc -std=c99 -Wall -Wextra -Werror -pedantic \
-Iclients/amiga/include \
clients/amiga/src/upload.c clients/amiga/tests/test_upload.c \
-o build-amiga-upload-test
./build-amiga-upload-test
cc -std=c99 -Wall -Wextra -Werror -pedantic \
-Iclients/amiga/include \
clients/amiga/src/submit.c clients/amiga/src/upload.c clients/amiga/src/client.c \
clients/amiga/tests/test_client.c \
-o build-amiga-transport-test
./build-amiga-transport-test
- name: Render POV-Ray smoke scene
run: |
mkdir -p build
povray +Itests/scenes/m1-smoke.pov +Obuild/m1-smoke.png +W160 +H120 -D +FN
test -s build/m1-smoke.png
32 changes: 31 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# AmiRender

A render accelerator appliance and distributed rendering system for classic Amiga workflows.
A render accelerator appliance, distributed Linux render farm, and preservation bridge for classic 3D workflows.

The Amiga is the workstation. AmiRender provides the modern compute.

Expand Down Expand Up @@ -28,6 +28,36 @@ AmiRender is intended to support, over time:
- AmiTerrain
- Ami3D
- Blender/Cycles/Eevee as appliance/farm backends
- Atari ST CAD-3D / Cyber Studio family
- Freescape / 3D Construction Kit scenes from C64, Atari ST, and Amiga

## Render modes

AmiRender keeps preservation and enhancement as separate, explicit goals:

- `original`: use the original renderer/software where practical, on original hardware or a qualified emulator/VM, preserving native scene and output formats.
- `authentic`: reproduce the original platform renderer, palette, resolution, shading, and relevant limitations in an automatable AmiRender backend.
- `enhanced`: preserve the source scene semantics in AmiRender IR and render with modern backends for the best practical result.

Importers must preserve original values and metadata alongside normalized IR data. Import must not destructively "improve" source assets.

Native formats are first-class preservation inputs/outputs. Planned examples include Atari CAD-3D/Cyber formats and Freescape/3D Construction Kit data. Modern interchange formats are additional outputs, not replacements for native-format support.

## Render farm

POV-Ray and Blender are first-class modern Linux farm backends. The scheduler is intended to support amd64 and ARM64 CPU workers and GPU-capable workers where the backend supports them. Retro scene import is independent of the renderer: a preserved classic scene may be rendered in original/authentic mode or sent through the same modern farm in enhanced mode.

## Landscape roadmap

Landscape generation is a first-class render source, with AmiTerrain owning terrain semantics and format compatibility.

- Preserve Vista/VistaPro, Scenery Animator, World Construction Set and other supported classic landscape inputs through AmiTerrain.
- Render preserved landscape scenes in `original`, `authentic`, or `enhanced` mode.
- Accept AmiTerrain Terrain IR without discarding native source metadata.
- Use POV-Ray and Blender/Cycles/Eevee as modern Linux farm targets for enhanced landscape rendering.
- Support modern open-source terrain workflows through AmiTerrain interchange, including TerraForge3D, Blender terrain/erosion workflows, generic heightmaps, meshes and DEM/GIS-derived terrain.
- Keep reverse conversion possible where representable: modern terrain may be reduced/quantized into formats usable by original classic landscape software.
- AmiRender does not replace AmiTerrain's importers or generators; it schedules and renders their outputs.

## User experience

Expand Down
21 changes: 21 additions & 0 deletions clients/amiga/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
CC = m68k-amigaos-gcc
CFLAGS ?= -O2 -Wall -Wextra
CPPFLAGS ?= -Iinclude
TARGET ?= amirender

SOURCES = \
src/submit.c \
src/upload.c \
src/client.c \
src/bsdsocket_amiga.c \
src/main_amiga.c

.PHONY: all clean

all: $(TARGET)

$(TARGET): $(SOURCES)
$(CC) $(CPPFLAGS) $(CFLAGS) $(SOURCES) -o $@

clean:
rm -f $(TARGET)
25 changes: 25 additions & 0 deletions clients/amiga/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# AmiRender Amiga client

This directory contains the first AmigaOS/m68k submission client components.

M1 deliberately separates the portable wire-protocol builder from networking. The
portable C layer builds the same newline-delimited JSON `SUBMIT` message accepted
by `amirender-node`. The Amiga transport layer will use `bsdsocket.library`.

The protocol builder rejects control characters, quotes and backslashes in text
fields rather than attempting incomplete JSON escaping. A later protocol utility
may add full escaping.

Target integration:

```text
Amiga application / CLI / ARexx
|
portable submit builder
|
bsdsocket.library
|
AmiRender node
```

No proprietary AmigaOS or Kickstart files belong in this repository.
29 changes: 29 additions & 0 deletions clients/amiga/docs/BUILD-AMIGA.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Building the AmigaOS/m68k client

The portable client code is tested by the normal Linux CI. The Amiga-specific
transport lives in `src/bsdsocket_amiga.c` and targets an AmigaOS-compatible
m68k toolchain with `bsdsocket.library` development headers.

Expected source set:

```text
src/submit.c
src/client.c
src/bsdsocket_amiga.c
```

The transport opens `bsdsocket.library` version 4, resolves the controller or
worker host with `gethostbyname()`, creates an IPv4 TCP socket and exposes it
through the portable `amirender_transport` interface.

The default AmiRender TCP port is 6800.

## Qualification

M1 qualification should compile this source with the Ploos `amiga-dev` Bebbo
toolchain, then execute the resulting m68k client in `amiga-runtime` against a
real AmiRender node. Runtime qualification must use an m68k Amiga environment;
AROS/i386 is not a substitute for this gate.

No Kickstart ROM, AmigaOS installation, or other proprietary system file is
stored in this repository.
18 changes: 18 additions & 0 deletions clients/amiga/include/amirender_bsdsocket.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#ifndef AMIRENDER_BSDSOCKET_H
#define AMIRENDER_BSDSOCKET_H

#include "amirender_transport.h"

struct amirender_bsdsocket {
int socket_fd;
};

int amirender_bsdsocket_connect(
struct amirender_bsdsocket *socket,
const char *host,
unsigned short port,
struct amirender_transport *transport);

void amirender_bsdsocket_close(struct amirender_bsdsocket *socket);

#endif
18 changes: 18 additions & 0 deletions clients/amiga/include/amirender_submit.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#ifndef AMIRENDER_SUBMIT_H
#define AMIRENDER_SUBMIT_H

#include <stddef.h>

struct amirender_job {
const char *id;
const char *engine;
const char *scene;
const char *output;
int frame;
int width;
int height;
};

int amirender_build_submit(char *buffer, size_t size, const struct amirender_job *job);

#endif
70 changes: 70 additions & 0 deletions clients/amiga/include/amirender_transport.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
#ifndef AMIRENDER_TRANSPORT_H
#define AMIRENDER_TRANSPORT_H

#include <stddef.h>

struct amirender_job;

struct amirender_transport {
void *context;
int (*send)(void *context, const char *data, size_t length);
int (*receive)(void *context, char *buffer, size_t size);
};

int amirender_upload_asset(
struct amirender_transport *transport,
const char *name,
const unsigned char *data,
size_t data_size,
char *asset,
size_t asset_size);

int amirender_download_asset(
struct amirender_transport *transport,
const char *asset,
unsigned char *data,
size_t data_size,
size_t *received_size);

int amirender_upload_begin(
struct amirender_transport *transport,
const char *name,
size_t total_size,
char *asset,
size_t asset_size);

int amirender_upload_chunk(
struct amirender_transport *transport,
const char *asset,
size_t offset,
const unsigned char *data,
size_t data_size);

int amirender_upload_end(
struct amirender_transport *transport,
const char *asset,
size_t total_size);

int amirender_download_chunk(
struct amirender_transport *transport,
const char *asset,
size_t offset,
unsigned char *data,
size_t data_size,
size_t *received_size,
int *eof);

int amirender_submit_job(
struct amirender_transport *transport,
const struct amirender_job *job,
char *reply,
size_t reply_size);

int amirender_extract_output_asset(
const char *reply, char *asset, size_t asset_size);

int amirender_download_file(
struct amirender_transport *transport, const char *asset,
const char *path, size_t *total_size);

#endif
13 changes: 13 additions & 0 deletions clients/amiga/include/amirender_upload.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#ifndef AMIRENDER_UPLOAD_H
#define AMIRENDER_UPLOAD_H

#include <stddef.h>

int amirender_build_upload(
char *buffer,
size_t size,
const char *name,
const unsigned char *data,
size_t data_size);

#endif
25 changes: 25 additions & 0 deletions clients/amiga/runtime/amiga-runtime.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"schema": 1,
"project": "AmiRender",
"milestone": "M1-amiga-client",
"architecture": "m68k",
"cpu": "68000",
"os": "AmigaOS",
"emulator_profiles": ["a500-os204", "a500plus-os2", "a1200-020-os3"],
"payload": {
"programs": ["C/amirender"],
"script": "S/run-test"
},
"result": {
"logs": ["T/amirender.log"],
"required_lines": ["AMIRENDER_EXEC=PASS", "AMIRENDER_USAGE_RC=20"]
},
"policy": {
"roms_in_repository": false,
"amigaos_files_in_repository": false
},
"requirements": {
"network": false,
"bsdsocket_library": true
}
}
14 changes: 14 additions & 0 deletions clients/amiga/runtime/run-test
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
; AmiRender M1 classic runtime smoke test
; The client is intentionally invoked without arguments.
; Exit code 20 proves the m68k executable reached its CLI validation path.

C:amirender >T:amirender-cli.out
SET rc $RC

ECHO "AMIRENDER_USAGE_RC=$rc" >T:amirender.log

IF $rc EQ 20
ECHO "AMIRENDER_EXEC=PASS" >>T:amirender.log
ELSE
ECHO "AMIRENDER_EXEC=FAIL" >>T:amirender.log
ENDIF
Loading
Loading