Camera
MSFS 2024 lets an add-on take the camera: acquire it, place it relative to the world, an aircraft or the pilot’s eyepoint, and give it back. The SDK calls are bound on the engine, pkg/camera turns them into shots, and the airport map films its traffic with them.
Bindings
engine.Engine (MSFS 2024 only):
| Call | What it does |
|---|---|
CameraAcquire(clientID) |
Takes the camera; a SIMCONNECT_RECV_CAMERA_STATUS follows (Message.AsCameraStatus). |
CameraSet(data, mask) |
Places it: types.SIMCONNECT_DATA_CAMERA with the members in mask (position, rotation, target, field of view). |
CameraGet(referential) |
Asks where it is; Message.AsCameraData decodes the answer. |
CameraRelease(def) |
Gives it back. |
RequestCameraWorldLocker(pos, ref, id), DeleteCameraWorldLocker() |
Keeps the terrain, scenery and objects around a point loaded while the camera is away from the user aircraft. |
CameraGetStatus, SubscribeToCameraStatusUpdate, UnsubscribeToCameraStatusUpdate, CameraEnableFlag, CameraDisableFlag, EnumerateCameraDefinitions, CameraSetUsingCameraDefinition, SubscribeToCameraWorldLockerStatusUpdate |
The rest of the API. |
SimConnect packs SIMCONNECT_DATA_CAMERA to one byte (84 bytes), so it crosses the API as bytes: Bytes() and types.CameraDataFrom.
Conventions
These were measured live with SDK 1.7.3; the SDK documentation leaves them out.
- World referential: x is the latitude and y the longitude, both in degrees; z is the altitude in meters above sea level.
- Relative to an aircraft: x points to its left, y up, z forward, in meters.
- Rotation: what SimConnect returns does not follow the header’s pitch, bank, heading order.
pkg/cameraaims with a point to look at (targeted) instead of angles.
camera.On(object, right, up, forward) takes an offset to the right and flips it for SimConnect (object 0 is the user aircraft). camera.At(lat, lon, altM) is a point in the world; a Point with Frame: camera.Eyepoint is an offset from the pilot’s eyepoint.
Poses and shots
p := camera.Pose{
Eye: camera.On(obj, 40, 6, -60), // right, up, forward of the aircraft
Target: camera.On(obj, 0, 2, 0), // look at it
FovDeg: 45,
}
A pose without FovDeg uses camera.DefaultFovDeg (55°). A Shot is the camera over time: Length(), PoseAt(t) and Name(). No shot runs longer than camera.MaxShot (10 s).
Holdkeeps one pose.Movegoes from one pose to another, eased (Smooth: no jerk at either end).Pathflies through keyframes on a Catmull-Rom curve. This is where combined moves come from: rising while circling while pushing in.Orbit,Chase,Track(a camera fixed in the world that follows an aircraft) andTrackZoom(the same, zooming).Spot.TravelToandPan(see Travel).
Drone moves
Each move is a MoveFunc(object, size, side, duration), scaled to the aircraft’s span and length.
| Kind | Moves |
|---|---|
| Wide | RevealRise, Flyover, SpiralDescend, LeadChase, ParallaxTrack, HeroLowPushIn, PullBackReveal, TopDown, TopOrbit, SideDolly, HeadOnPass, ChaseRise |
| Detail | EngineDetail, NoseGearDetail, MainGearDetail, CockpitDetail, TailDetail, WingtipAlong, LightsDetail |
Long shots
MaxShot (10 s) caps every shot unless it opts out. camera.Stretch(shot, d) plays any shot over d, up to MaxStretch (5 minutes), its move slowed to fit, for a camera that stays with one aircraft through an event. In a scene or a ShotRequest, "long": true makes sec exact (no pacing, no cap).
Moments
The instants worth a cut, on any aircraft the World sees: flare, touchdown, reversers, vacated, rotate, liftoff, gearup. World.OnMoment(f) hands each one over as it happens; GET /api/camera/moments?since=SEQ gives the last 256 after that number (seq, name, tail, objectId, at, user, ours). Scene cues use them as ROLE:MOMENT.
Ours say all of them, at the frame they happen. The player’s and other traffic’s are read off the scan, at its rate, and are only what the simulator shows: touchdown and liftoff (from SIM ON GROUND, 20 ft up before it counts as flown, so a bounce is not a lift-off), gearup, and vacated (50 m off the line it touched down on). They have no flare, rotate or reversers.
Spotting director
World.StartSpotting(SpottingRequest{ICAO: "LKPR"}) or POST /api/camera/spotting: the camera watches the airport by itself. It picks an aircraft landing, taking off or taxiing and the nearest fitting spot, stays with it until that is over, and moves on. Landings and take-offs come first and interrupt a taxi, never each other. GET /api/camera gives subject, event and shot; mode off ends it.
It reads the scan, so it sees ours, other traffic and the player alike. Kinds (ours, other, player), Types (ICAO designators) and Events limit what it may pick. It cuts to a closer spot at most every 10 s, and only one 30% closer. What an aircraft is doing is worked out from where it is and how it moves, not from our controllers: an unusual approach off the runway’s line counts as nothing to watch until it lines up.
One observer
A hard cut to a spot far away makes the simulator load the scenery and models there, and they pop in just after the cut. With travelMaxM set, the director is one drone that moves between its spots instead:
- Where it is: every shot starts from the camera’s current pose. The first shot of a spotting is a cut from wherever the camera was.
- Cut: only to a spot within
cutMof the eye (default 300 m, at mosttravelMaxM). The area there is loaded, so it reads as a new angle. - Travel: a spot within
travelMaxMis flown to, a slow drone flight that is a shot in itself (camera.Spot.TravelTo), attravelSpeed(default 15 m/s, kept to 10–20). The spot shot joins it with no cut. - Farther: not gone to. A subject whose spot is out of reach is not picked.
- Subjects near it first: a candidate’s score adds the way from the eye to its spot. A landing or a take-off still comes before a taxi.
- Landings: an aircraft lined up with a runway up to 12 NM out pulls the drone there. It leaves about 60 s before the flight to the touchdown spot would be too late, in hops when that spot is out of reach, filming the arrival on the way. Each hop goes to the spot within reach nearest it, or, with none nearer, to a waypoint in the air towards it, above the higher of the two plus 15 m. No travel starts for a taxi while a landing is due within 5 minutes, and a taxi or a take-off already climbing out gives way to a landing that cannot wait.
- Nothing to film: a slow look round where it is (
camera.Pan), at the nearest parked aircraft or now and then the player’s (at most every 5 minutes, kindplayerifkindsis set), else a 30° sweep. It never jumps elsewhere for that.
travelMaxM 0 (absent) keeps the cuts anywhere, as before: cutM and travelSpeed are then not used. GET /api/camera gives move: cut; and with the observer travel while the drone flies, join in the spot it flew to (or the spot taken again, no cut), look while it looks round.
POST /api/camera/spotting
{"icao": "LKPR", "travelMaxM": 1000, "cutM": 300, "travelSpeed": 15}
Spots
A camera.Spot is a camera standing in the world: fixed, or on a straight rail (RailEnd, at most RailSpeed, 4 m/s by default) going abeam its subject. Its lens (FovMin, FovMax) is chosen to keep the aircraft at Share of the frame’s width, the change smoothed. Spot.Track(object, size, d, feed, clock) plays it for up to MaxStretch. Spot.Framing(size, dist) is the lens it would choose.
The aim is a world point from a filter on the subject’s samples, which may come only once a second: it runs on with the velocity found between them and takes corrections out slowly, so a long lens does not show a step and a subject flying straight is not lagged. LockAim aims at the object itself instead, the simulator keeping it dead centre.
The filter is a camera.Aim (NewAim(object, feed, clock)), one per subject. Shots that film the same subject one after another share it, so the aim and the lens run on across them: Spot.Follow(aim, size, d, join) is Track on a shared aim, and join carries on from the last shot on it (its rail starts at the point nearest the eye shown last and moves on gently, the lens from the last one).
Travel
Spot.TravelTo(aim, size, camera.Travel{From, Move, SpeedMps, MarginM}) flies the drone from the pose From (its eye a world point) to the spot’s eye, framing the aim’s subject:
- Speed: eases in and out of a steady cruise over
TravelRamp(8 s) at each end, the speed rising and falling asSmooth, so there is no step in it. The cruise isSpeedMps(defaultDefaultTravelSpeed, 15 m/s), counting the climb. - Height: it climbs to the higher of its two ends plus
MarginM(default 15 m) and comes down to the spot at the end. There is no ground data, so the spots’ heights are what is known. - View: a world target in
Fromturns to the subject no faster thanTravelTurnRate(6°/s); a long turn makes the travel longer. Then it aims as the spot does,LockAimtoo. The lens blends fromFrom’s to the spot’s framing. - Moves:
TravelGlidestraight;TravelDollyalongside a moving aircraft, on its heading;TravelSlidebowing out round a parked aircraft;TravelRisehigher, over an apron;TravelPushInending moving towards the subject.TravelAutopicks from the subject. - Join: it ends exactly at the spot’s eye with the spot’s lens. Play
Spot.Follow(aim, size, d, true)after it on the same aim and going into the spot shot is not a cut.
The length is the way at the cruise plus one ramp, at most MaxStretch. Poses are set on the simulator’s frame like any other shot; the aim runs per frame on the samples it has.
camera.Pan(name, eye, from, to, fromFov, toFov, d) turns a camera standing at eye from one world point to another, eased; PanLength is long enough to stay under PanRate (4°/s).
Observer in a host app
A host app with its own spotter, one that never calls StartSpotting, gets the same one-observer moves from camera.Observer. The World’s spotting decides each cut or travel with it too.
obs := camera.Observer{TravelMaxM: 1000} // CutM 300, SpeedMps 15, MarginM 15 by default
way := obs.Plan(camera.Leg{
From: pose, Have: havePose, // the camera now; Have false for the first shot
To: spot, Aim: aim, Size: span * 1.05,
D: 30 * time.Second, // the spot shot
})
switch way.Kind {
case camera.MoveCut, camera.MoveTravel:
for _, s := range way.Shots { /* play them one after another */ }
case camera.MoveTooFar:
// not gone to: pick another subject or spot
}
- Cut: the spot’s shot starts within
CutMof the eye (default 300 m, at mostTravelMaxM). On a rail the shot starts abeam the subject, so that point counts, not the spot’s eye.Shotsis the spot shot alone (Spot.Follow, not joined). - Travel: the spot’s eye is within
TravelMaxM.Shotsis the travel (Spot.TravelTofromFrom, atSpeedMps, kept to 10–20 m/s, andMarginM) and the spot shot joined to it, on the same aim. The travel ends exactly at the spot’s eye, so going into the spot shot is not a cut.Travelis the travel’s length. - Too far: farther, no shots.
- No pose:
Havefalse, or an eye that is not a world point, is a cut. The zeroObserver(TravelMaxM0) always cuts, as a spotter did before.
Way.M is the way in metres on the ground. Decide(have, startM, eyeM) gives the move from the distances alone, and Seconds(have, d) about how long a travel over d takes, to choose a subject before building any shot. Shots(kind, leg) builds the shots of a move already decided. The travel takes Leg.Move (TravelAuto by default; the World uses TravelRise over an apron).
There is no ground or building data. The travel’s only clearance is MarginM above the higher of its two ends, so give each spot a height that clears what is around it.
Keep the pose the camera ends on (Way.Shots’ last pose, or the Director’s) as From for the next leg. A From aimed at a world point turns to the subject slowly; any other target is let go of at once.
A spotter that drives the camera itself, with no Aim or Spot, flies a TravelPath: the same flight as Spot.TravelTo, which uses it too. Its ends are live. Each At takes the eye and the look point now, so an eye creeping along a rail and a moving subject are followed with no jump, and the drone lands exactly on the latest eye at Length.
tp := camera.NewTravelPath(pose, eye, look, obs) // the way and time planned to this eye
for el := time.Duration(0); !tp.Done(el); el += frame {
eye, look = railEye(), subject() // live, World points
p := tp.At(el, eye, look)
p.FovDeg = tp.Lens(el, myFov) // from the start's lens to yours
show(p)
}
NewTravelPath(from, toEye, toLook, obs)flies at theObserver’s cruise and margin (kept to its limits),TravelAutofrom a subject standing.Travel{From: pose, Move: camera.TravelDolly, LookVelMps: v}.Path(toEye, toLook)picks the move or gives the subject’s velocity (east, north, up).- The way and the time come from
from’s eye and the firsttoEye. When the eye moves, the path shifts by its move times the share of the way flown, so the drone flies a little faster or slower than the cruise. - The view turns from
from’s target to the look over at least 3 s, at mostTravelTurnRate, then stays on the look. CallAtin time order.
World.Spots(icao) (GET /api/camera/spots?icao=) lists an airport’s spots, generated from its data: threshold:<end>, touchdown:<end> (on a rail), approach:<end>, holding:<end> and apron:<lowest stand>. A low one keeps clear of the runways, taxiways and stands, and a spot with no clear place is left out. World.PlaySpot (POST /api/camera/spot) plays one on any aircraft: id (-1 the player) or tail, with sec, share and lock. In a scene, "spot": "touchdown:24" on a shot, or "touchdown" for the aircraft’s own runway.
spots.json in DataDir changes them by airport, local winning per value; a name not generated adds a spot:
{"LKPR": {"touchdown:24": {"up": 12}, "threshold:06": {"off": true},
"mine": {"lat": 50.1, "lon": 14.26, "up": 4}}}
Heights are above the runway’s elevation, or the airport’s off a runway. SimConnect has no call for the ground at a point, and no building data, so where the ground falls or rises under a spot (an approach, most of all) the table sets up or altM.
Director
d := camera.NewDirector(engine, "my-addon")
d.LockWorld(camera.At(lat, lon, altM)) // optional: no scenery loading on cuts
d.Play(shotA, shotB) // a cut; Then queues
// in the connection's goroutine, 30–60 times a second:
d.Tick(time.Now())
// and for every message:
d.Handle(msg)
The director acquires the camera on the first Tick with a shot to play, and asks again every AcquireRetry (5 s) while it is not given (ErrNotAcquired meanwhile); a camera held by someone else or disabled by the user is not asked for again until Release. It sets the current shot’s pose on every tick and moves to the next shot when one ends; with nothing queued it holds the last pose. After each cut the new shot holds its first pose for CutSettle (600 ms) while the picture settles. OnShot hears each shot as it starts; Current and Remaining tell what plays, Pose the last pose set (where the camera is, for a shot that starts from there). After a reconnect call Reset(api) (nil keeps the client). Release gives the camera back and deletes the world locker. Always release it: a camera left acquired stays stuck for the user.
Shots on a replay
For a shot designer over a recorded flight:
-
Moves listed:
Moves()gives the drone moves asMoveInfo{Name, Doc, Kind, Func}: name, what it shows,WideorDetail, and the function making the shot (Func(object, size, side, duration)).TrackZoomis not among them, since it takes an eye point. -
Shots in the world:
Placed(point, poseOf)places a shot’s point in the world.- A world point stays as it is.
- An object point is placed from that object’s
ObjectPose(lat, lon, altitude, heading, pitch, bank), rotated by its attitude. - An eyepoint point cannot be placed.
WorldPoses(shot, step, poseAt)samples a whole shot that way, the object’s pose taken at each time from the recording. Each sample has the eye, the target and the field of view, which is the camera path and view cone to draw on a map, matching what the simulator will show. -
On the replay’s clock: a
TimelineofCue{At, Shot}places shots on a film.Director.Follow(timeline, clock)plays it on a clock the host supplies, such as the replay’s time.- Seeking and pausing: a shot cued at 545 s plays then, after a seek or a pause, at any rate.
- Between shots: the camera holds its last pose.
- At the end: past the film’s end,
TickreturnsErrFilmEnded, and the host callsRelease, which also stops following. - Clock function: it is called under the Director’s lock, so it must not call the Director.
-
Designed shots: a
WorldPathis a shot keyed in the world on the replay’s clock.- Keys: each
WorldKeyhas a replay timeT(from the recording’s first sample), the eye (Lat,Lon,AltMabove sea level), a heading and pitch, and a field of view. The eye moves on a Catmull-Rom curve through the keys, eased over the whole shot (Ease, nil:Smooth). - Shots on a ghost:
OnObject(length, object, shot)is a shot on an object only known during the replay. It asksobject()as it plays, holds the camera while that is 0, and makes the shot again when the object changes, as after a seek. Withflight.GhostFleet:Keep(keys...)the film’s subjects, so they are flown whatever the budget, and passObjectOf(key)as the object (see flight). - Look at:
LookAircraftfollows the replayed aircraft, either its live object (Object, placed by the simulator in step with what it shows) or, without one, its recorded track (Track(t)).LookPointkeeps a fixed point in view, andLookFreeaims by each key’s heading and pitch. - Checks:
Validatechecks the structure (two keys or more, increasing times, a complete look mode).LongreturnsErrShotTooLongpastMaxShot(10 s) as a warning only: the shot still plays at its full length. - Playing:
p.Cue()places it at its first key’s time;NewTimeline(cues...)andDirector.Follow(timeline, replayTime)play it, released atErrFilmEnded. - Presets:
KeysOf(shot, at, step, poseAt)turns any shot, such asSideDolly, into world keys at replay timeat, each aimed where the shot looks, so a designer starts from a preset and edits it (played back withLookFree). - Lens:
FovFromFocalMMandFocalMMFromFovconvert a full-frame focal length to the horizontal field of view and back (50 mm is 39.6°).
- Keys: each
On the airport map
The camera button in the status strip opens the director:
- 🎥 Camera
- Auto director cuts to the aircraft on the radio as you hear the call. It plays a short sequence for what that aircraft is doing: wide, a detail, wide again; on the runway and on final it opens with a camera beside the runway.
- Follow selected stays on the selected card’s aircraft.
- Tower looks from the airport’s tower. With an aircraft selected it turns with that aircraft. With none, it stands at the tower aimed at the middle of the airfield, and the Tower look buttons turn it: ⟲ ⟳ left and right, ▲ ▼ up and down, + − zoom; hold one to keep turning. The aim eases after each turn (
towerEase, 0.35 s). Swing makes it look round by itself, one slow swing side to side (110°, 70 s there and back).POST /api/camera {"mode":"look","yaw":4,"tilt":0,"fov":0}turns it;{"mode":"look","swing":true}swings. Keys turn it too (arrows, + and −, Shift faster), and so does the middle mouse button held and dragged (with the wheel while held for zoom); a double click of the middle button locks the look to the mouse with no button held, until another middle click or Esc. The Angle switch (off by default) draws on the map a cone of where it looks, labelled with its bearing, tilt and field of view;GET /api/cameragives them aslook. The tower is where you placed it (Airport tab: Tower, saved per airport in the user cache folder,towers.json). Otherwise it is the airport’s known tower (airport.Limits.Tower: LKPR’s facility position is not its tower), then the facility’sTOWER_LATITUDE/TOWER_LONGITUDE(TOWER_ALTITUDEis the ground there, not the cab), then over the airport reference point. The cab is 100 m above the airfield unless you set another height (10–250 m).GET/POST /api/tower. - When our camera is released, the simulator’s camera is set back to what it was before (live, it otherwise drops into chase).
- Simulator camera gives the camera back to the simulator and sets its own:
CAMERA STATEcockpit (2), chase (3), drone (4), fixed on plane (5), free (6, environment), written as INT32 likeexamples/set-variables. Measured live in MSFS 2024: the numbering on the 2024 SDK page (drone 8, showcase 7, follow traffic 23) was refused. ◀ ▶ step through the camera’s views (CAMERA VIEW TYPE AND INDEX:1) from the one it is on. API:POST /api/camera {"mode":"sim","sim":"drone"}or{"mode":"sim","step":1}. - 🎬 Scene plays a scripted film. A scene spawns its cast, listens to one of them on the radio, and plays beats: each waits for its cue, then cuts to its shots. If a beat’s shots end before the next cue, more shots of the same aircraft fill the gap.
A host can play a scene it holds: World.PlayScene(icao, scene) (POST /api/camera/scene?icao= with the scene in the body), validated first, and World.StopScene(). World.OnSceneEvent hears what it reaches, in order and off the camera’s goroutine: start, cue, beat, shot, end. GET /api/camera has the same as scene: name, beat, beats, cue and elapsed seconds.
Scenes are JSON files in -scenes (default scenes/), read on every play, so a scene can be edited and played again without a restart. The built-in scenes come after them; a file with a built-in scene’s name wins.
{
"name": "DEMO007 departure",
"cast": [{ "role": "dep", "kind": "departure", "tail": "DEMO007", "models": "csa-lines, a320", "tug": true, "procedure": true, "pushAfterSec": 35 }],
"listen": "dep",
"beats": [
{ "cue": "start", "shots": [{ "move": "crane", "who": "dep", "sec": 10 }] },
{ "cue": "dep:lights:B", "shots": [{ "move": "topOrbit", "who": "dep", "sec": 10 }] },
{ "cue": "dep:departing", "shots": [{ "move": "runwaySide", "who": "dep", "along": 900, "right": 90, "fov": 40, "fovTo": 22, "sec": 7 }] },
{ "cue": "dep:height:1500", "end": true, "shots": [{ "move": "chaseRise", "who": "dep", "sec": 10 }] }
]
}
Cues
A cue holds once reached, so a beat is not missed when two things happen close together.
| Cue | When it holds |
|---|---|
start |
At once. |
t:SECONDS |
That long after the scene began. |
ROLE:STATE |
The aircraft has reached that controller state, e.g. dep:pushback, dep:taxiing, arr:rollout. |
ROLE:airborne |
The departure has left the ground. |
ROLE:lights:X |
That light has come on: N nav, B beacon, S strobe, T taxi, L landing, O logo, W wing. |
ROLE:height:FEET |
The departure has climbed that high above the runway. |
ROLE:below:FEET |
The arrival has come down that low above the ground. |
ROLE:MOMENT |
That moment has happened since the scene began. ROLE can also be player or the call sign of any aircraft outside the cast. |
ROLE:heard |
A call to or from the aircraft has been heard since the last beat. |
ROLE:rescue |
Rescue vehicles have been sent for it (it has priority: an emergency). |
ROLE:rescue:with |
It is down and one of its rescue vehicles is within 80 m. |
Time of day
"local": "21:30" plays the scene at that time of day, local at the user’s aircraft, and puts the clock back when it ends. The date stays. The light follows at once and our traffic takes no notice, since it runs on its own clock.
A scene cannot set the simulation rate. MSFS 2024 ignored SIM_RATE_INCR, SIM_RATE_DECR and SIM_RATE_SET from SimConnect in a measured test (no error, the rate stayed 1) and refused writing SIMULATION RATE.
Radio
Scene events of kind radio give each transmission: speaker (a crew’s call sign or the station), callsign (who a station talks to), frequency, text, atSec and durSec. atSec is when it starts, later than the event when it waits for the frequency. durSec is the speaking time worked out from the words, not what a voice took. Events of kind shot and beat give the subject on screen.
lines is the scene’s own radio, to a timetable: {"atSec": 12, "who": "dep", "text": "..."}. who is a cast role (its crew) or a station’s name, given as the controller so that all its lines are one voice; a station needs frequency and can name to. A line is said word for word at its time and never moves. Traffic on the frequency is kept off it for 15 s before and until it ends, and lines overlapping on one frequency are refused. These times are the scene’s clock, as t: cues.
mute keeps the rest of the radio from the host: traffic goes on talking and acting, and its transmissions still come as radio events with muted, but OnTransmission hears only the lines. A host’s voice still chooses what it plays, for example by SceneFrequency.
The airport, emergencies and actions
A scene can do more than film. These fields make one a whole demonstration, as the built-in 4-showcase does:
jetways: true switches the jetways on as the scene starts.schedule:{"density": 2, "maxAircraft": 30}switches the airport’s scheduled traffic on around the cast if it is off.- Cast:
atSecis when it appears, in seconds from the start of the scene. Withafterset to a cue,atSeccounts from that cue instead. For example,"after": "dep:pushback"keeps an arrival in step with the departure however long its fuelling takes.pushAfterSecis the earliest push. A fuel truck or tug still at work comes first.standputs a departure on that stand; if it is taken, the departure goes to any free one.fuelhas it refuelled before the push.emergencygives an arrival an emergency of that kind (engine-failure,medical,fuel,pressurisation,fire,hydraulic). It is declared once the aircraft flies, with its MAYDAY or PAN PAN, priority in the sequence, and the airport’s rescue vehicles.
- Beat
actions: run as the beat starts, withwhoa role. They are the scenario actions (World.Act):{"do": "say", "kind": "expectDelay", "who": "dep", "args": {"minutes": "5"}};{"do": "say", "kind": "custom", "who": "kal", "args": {"text": "…"}}is a line said as written. It comes from the controller unless"from": "pilot"."reply"is the other side’s answer as written ("none"for no answer); by default a controller’s line gets “Roger, …” and a crew’s line gets nothing."frequency": "132.89"puts it on a frequency no station of ours has, such as Praha Control en route;{"do": "emergency", "kind": "medical", "who": "kal", "args": {"say": "none"}}gives priority, squawk 7700 and the rescue without the stock radio calls, so the scene’s own lines tell it;{"do": "runway", "runway": "06/24", "kind": "hold", "on": true}holds the runway: no clearances on it, but it stays the runway in use. Withoutkind, the runway is closed, and the runway in use changes.
delaySec: starts a beat that long after its cue.endActions: run however the scene ends, for example to release a held runway.
A beat’s listen switches the radio to that aircraft’s frequency from then on, or to a frequency given ("listen": "132.89"). move is one of the drone moves above (revealRise, topOrbit, mainGear, …), crane (the opening), or runwaySide / underApproach (fixed beside the runway, zooming from fov to fovTo).
Compositions and glides
Shots are composed first: a shot is a slow glide between two frames picked from stills, not a move judged only in motion. A frame is a move held still at one moment and distance. Its name is <move>_dist<back>_t<moment>; for example sideDolly_dist1.6_t50 is the middle of sideDolly, 1.6 times farther from what it looks at.
The picked frames come from a sweep at LKPR: every move at three distances and three moments, reviewed as stills. The close details (cockpit, lights, main gear, hero push-in, head-on) were all too tight and are not picked (sceneCompositions). Two rules apply to every glide:
- Never from behind. A frame with the camera behind the tail is left out.
- Clear of buildings. At a stand the camera never goes ahead of the nose (the terminal) or to the left (the jetway). Elsewhere it stays low only over the taxiways and aprons (within 35 m of the taxi graph); 30 m up, it is above the roofs.
A shot is one of:
{"from": "revealRise_dist2.4_t50", "to": "revealRise_dist1.6_t50"}: a glide from one frame to the next, at most 1.2 m/s. A glide longer than a shot allows is not played.{"from": "sideDolly_dist1_t50", "to": "dolly"}: a dolly, the camera and its aim sliding together along the aircraft, about 0.5 m/s. It is used only from a side frame. When one end is hidden, the slide starts there and comes out, showing the aircraft, never covering it.{"from": "…"}alone holds the frame.
The scene filler and the auto camera both play the glides in turn, never the same one twice until all have played.
Composing your own shots
cmd/scene-cli drives the map while you write a scene:
scene-cli spawn -tail DEMO009 [-model …] [-stand N] a departure parked, its push 2 h away
scene-cli car -near DEMO009 -right 30 -forward 5 a car to frame against (-at-camera, -lat/-lon); Ctrl+C removes it
scene-cli capture NAME [-tail DEMO009] [-dir DIR] the simulator's camera as NAME.json and NAME.jpg
scene-cli shot -tail DEMO009 -from sideDolly_dist1_t50 -to dolly one shot (-glide N, -move M -at 0.5 -back 1.6)
scene-cli scene NAME | off | glides | moves | vehicle-radio on|off
A capture reads the simulator’s own camera (CameraGet answers without taking it). It saves the camera’s position, heading, pitch and field of view, and its offset from the aircraft filmed: right, up and ahead, with the point aimed at. It also saves where the camera is on the airport: the nearest stand and taxiway, and its distance along and beside the runway. The picture is the simulator’s window, which must be on screen; a covered window gives a stale picture.
GET /api/camera mode, subject, shot; spotting: event, move (cut | travel | join | look)
POST /api/camera {mode, id} off | follow (id: the card) | auto
GET /api/camera/scenes the scenes
POST /api/camera/scene?name=&icao= play one
GET /api/camera/moves the moves a shot takes
GET /api/camera/glides the glides between picked frames
POST /api/camera/shot {icao, tail, move | from, to | glide, side, sec, back, fov, at} one shot; the camera goes back after it
POST /api/camera/capture {icao, name, tail} the simulator's camera, placed
POST /api/camera/spotting {icao, kinds, types, events, share, lock, cutM, travelMaxM, travelSpeed} the spotting director