# New-ImageStory

Creates a generic source-to-result visual story from resolved scenes and declared outcomes.

 Command  

**Module**

`imageplayground`

**Inputs**

 `ChartForgeX.Stories.VisualStory` 

**Outputs**

 `ChartForgeX.Stories.VisualStory` 

Creates a generic source-to-result visual story from resolved scenes and declared outcomes.

## Syntax

```
New-ImageStory
[-AnimationScale <Int32>]
[-BundleFormats <String[]>]
[-BundlePath <String>]
[-CapturedAtUtc <DateTimeOffset>]
[-Description <String>]
[-EndHoldSeconds <Double>]
-FilePath <String>
[-FramesPerSecond <Int32>]
[-Height <Int32>]
[-MaximumFrames <Int32>]
[-NoLoop]
-Outcomes <ImageStoryOutcomeSpec[]>
[-PassThru]
[-PlayCount <Int32>]
[-Player]
-Scenes <ImageStorySceneSpec[]>
[-Show]
[-Theme <VisualStoryTheme>]
-Title <String>
[-TransitionSeconds <Double>]
[-Width <Int32>]
[<CommonParameters>]
```

 [#](#member-b267f452fbcae1ef81da57c9) 

Parameter set: `Parts`

```
New-ImageStory
[-AnimationScale <Int32>]
[-BundleFormats <String[]>]
[-BundlePath <String>]
[-CapturedAtUtc <DateTimeOffset>]
[-EndHoldSeconds <Double>]
-FilePath <String>
[-FramesPerSecond <Int32>]
[-MaximumFrames <Int32>]
[-NoLoop]
[-PassThru]
[-PlayCount <Int32>]
[-Player]
[-Show]
-Story <VisualStory>
[-TransitionSeconds <Double>]
[<CommonParameters>]
```

 [#](#method-new-imagestory-int32-string-string-datetimeoffset-double-string-int32-int32-switchparameter-switchparameter-int32-switchparameter-switchparameter-visualstory-double) 

Parameter set: `Story`

## Description

The cmdlet never executes displayed code. Callers or trusted build tooling capture real outputs first, then pass the resolved source, transcript, and media into the story.

## Examples

### Show PowerShell source and the chart it produced

```powershell
$source = ConvertTo-ImageStorySource -Text $code -Language PowerShell
$codePanel = New-ImageStoryPanel -Id source -Source $source -Title 'PowerShell'
$chartPanel = New-ImageStoryPanel -Id chart -MediaPath .\chart.png -AccessibleText 'Weekly builds chart' -Title 'Result'
$scenes = @(
  New-ImageStoryScene -Id source -Title 'Write the script' -Panels $codePanel
  New-ImageStoryScene -Id result -Title 'See the chart' -Layout Split -Panels @($codePanel, $chartPanel)
)
$outcome = New-ImageStoryOutcome -Id chart-created -Label 'The chart is visible' -PanelId chart
New-ImageStory -Title 'Chart in five lines' -Scenes $scenes -Outcomes $outcome -FilePath .\chart-story.gif
```

Produces a portable animated story whose final scene contains the promised chart.

## Parameters

**-AnimationScale Int32 optional**

Pixel density multiplier for animated SVG, HTML, GIF and APNG output.

**-BundleFormats String[] optional**

Formats emitted into BundlePath. The completed PNG is always included.

Possible values: `Svg`, `Html`, `Png`, `Gif`, `Apng`, `Transcript`

**-BundlePath String optional**

Optional directory that receives a portable PowerForge-compatible story bundle and manifest.

**-CapturedAtUtc DateTimeOffset optional**

Optional capture time recorded in the portable bundle. Omit it for deterministic bundle manifests.

**-Description String optionalsets: Parts**

Accessible story description.

**-EndHoldSeconds Double optional**

Completed-scene hold shared by all animated formats.

**-FilePath String required**

Output path. Supports SVG, HTML, PNG, GIF, APNG, and TXT.

**-FramesPerSecond Int32 optional**

Frame rate shared by animated SVG, HTML, GIF and APNG output.

**-Height Int32 optionalsets: Parts**

Logical output height.

**-MaximumFrames Int32 optional**

Maximum animated frame budget.

**-NoLoop SwitchParameter optional**

Produce one play in every animated format. Equivalent to PlayCount 1.

**-Outcomes ImageStoryOutcomeSpec[] requiredsets: Parts**

Outcomes that the completed scene must reveal.

**-PassThru SwitchParameter optional**

Write the resolved native story to the pipeline.

**-PlayCount Int32 optional**

Total plays for all animated formats. Zero repeats indefinitely.

**-Player SwitchParameter optional**

Add browser playback controls to HTML output and HTML bundle artifacts.

**-Scenes ImageStorySceneSpec[] requiredsets: Parts**

Resolved scenes in display order.

**-Show SwitchParameter optional**

Open the generated story after creation.

**-Theme VisualStoryTheme optionalsets: Parts**

Optional visual-story theme. Authored stories use the canonical dark theme by default; supply VisualStoryTheme.GraphiteLight() for its light counterpart or a custom theme.

**-Title String requiredsets: Parts**

Story title.

**-TransitionSeconds Double optional**

Cross-fade duration between scenes.

**-Width Int32 optionalsets: Parts**

Logical output width.

**-Story VisualStory requiredpipeline: True (ByValue)sets: Story**

Native resolved ChartForgeX visual story.

## Common Parameters

This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.

For more information, see [about_CommonParameters](https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_commonparameters).

<!-- PowerForge markdown artifact sha256:2E53E8CC3D7300A82D9C76261F26C216307CD769126C0AFDE16ACB472DC82D1A -->
