Files
piskel/src/templates/dialogs/import-image.html
James Lissiak 48f24c0cf3 Adding spritesheet import
- Updated the import dialog to allow users to specify the number of frames in the image (which defaults to 1 x and 1 y)
- Setting the frame count for x and y will draw a dotted line in the preview that shows where the image will be split into individual frames
- When imported with a frame count above 1, the source image will be split into the different frames and loaded just as if it were an animated gif
- This allows users to import existing spritesheet pngs, including those produced by the piskel export function
2015-06-01 10:29:52 -07:00

32 lines
1.4 KiB
HTML

<div class="dialog-wrapper">
<h3 class="dialog-head">
Import Image
<span class="dialog-close">X</span>
</h3>
<div class="dialog-import-body">
<form action="" method="POST" name="import-image-form">
<div class="import-section">
<span class="dialog-section-title">Name :</span><span class="import-image-file-name"></span>
</div>
<div class="import-section">
<span class="dialog-section-title" style="vertical-align:top">Info :</span>
<div class="import-section-preview"></div>
</div>
<div class="import-section">
<span class="dialog-section-title">Size :</span>
<input type="text" class="textfield import-size-field" name="resize-width" />x
<input type="text" class="textfield import-size-field" name="resize-height" />
</div>
<div class="import-section">
<span class="dialog-section-title">Frames :</span>
<input type="text" class="textfield import-size-field" name="frame-count-x" />x
<input type="text" class="textfield import-size-field" name="frame-count-y" />
</div>
<div class="import-section">
<span class="import-section-title">Smooth resize :</span>
<input type="checkbox" checked="checked" name="smooth-resize-checkbox" value="1" />
</div>
<input type="submit" name="import-submit" class="button button-primary import-button" value="Import" />
</form>
</div>
</div>