[gimp] plug-ins: improve formatting and comments related to resolution export ...
- From: Jacob Boerema <jboerema src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] plug-ins: improve formatting and comments related to resolution export ...
- Date: Wed, 24 Aug 2022 18:19:59 +0000 (UTC)
commit fac6b2f3f1d8251ff7b0d99736c5b06f86ce1fa6
Author: Jacob Boerema <jgboerema gmail com>
Date: Wed Aug 24 14:19:30 2022 -0400
plug-ins: improve formatting and comments related to resolution export ...
for PSD's
plug-ins/file-psd/psd-save.c | 10 +++++-----
plug-ins/file-psd/psd.h | 6 +++---
2 files changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/plug-ins/file-psd/psd-save.c b/plug-ins/file-psd/psd-save.c
index 99ae48ca17..ef70c9483a 100644
--- a/plug-ins/file-psd/psd-save.c
+++ b/plug-ins/file-psd/psd-save.c
@@ -824,10 +824,10 @@ save_resources (GOutputStream *output,
/* --------------- Write resolution data ------------------- */
{
- gdouble xres = 0, yres = 0;
- guint32 xres_fix, yres_fix;
+ gdouble xres = 0, yres = 0;
+ guint32 xres_fix, yres_fix;
GimpUnit g_unit;
- gint16 psd_unit;
+ gint16 psd_unit;
g_unit = gimp_image_get_unit (image);
gimp_image_get_resolution (image, &xres, &yres);
@@ -850,10 +850,10 @@ save_resources (GOutputStream *output,
write_gint16(output, 0x03ed, "0x03ed Id (resolution)"); /* 1005 */
write_gint16 (output, 0, "Id name"); /* Set to null string (two zeros) */
write_gint32 (output, 16, "0x0400 resource size");
- write_gint32 (output, xres_fix, "hRes (16.16 fixed point)");
+ write_gint32 (output, xres_fix, "hRes (16.16 fixed point)");
write_gint16 (output, psd_unit, "hRes unit");
write_gint16 (output, psd_unit, "width unit");
- write_gint32 (output, yres_fix, "vRes (16.16 fixed point)");
+ write_gint32 (output, yres_fix, "vRes (16.16 fixed point)");
write_gint16 (output, psd_unit, "vRes unit");
write_gint16 (output, psd_unit, "height unit");
}
diff --git a/plug-ins/file-psd/psd.h b/plug-ins/file-psd/psd.h
index cd86019bf1..1236faa4b6 100644
--- a/plug-ins/file-psd/psd.h
+++ b/plug-ins/file-psd/psd.h
@@ -435,11 +435,11 @@ typedef struct
/* Image resolution data */
typedef struct {
Fixed hRes; /* Horizontal resolution pixels/inch */
- gint16 hResUnit; /* Horizontal display resolution unit */
- gint16 widthUnit; /* Width unit ?? */
+ gint16 hResUnit; /* Horizontal display resolution unit (1=pixels per inch, 2=pixels
per cm) */
+ gint16 widthUnit; /* Display width unit (1=inches; 2=cm; 3=points; 4=picas; 5=columns)
*/
Fixed vRes; /* Vertical resolution pixels/inch */
gint16 vResUnit; /* Vertical display resolution unit */
- gint16 heightUnit; /* Height unit ?? */
+ gint16 heightUnit; /* Display height unit */
} ResolutionInfo;
/* Grid & guide header */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]