Plan 9 from Bell Labs’s /usr/web/sources/contrib/steve/root/sys/man/8/webphoto

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


.TH WEBPHOTO 1
.SH NAME
webphoto \- internet photo album
.br
exifsrv \- expand EXIF metadata in digital camera files
.SH SYNOPSIS
.B webphoto
.br
exifsrv [
.I -m
.B perm
][
.I -s
.B name
]
.SH DESCRIPTION
.I Webphoto
renders simple directories of image files as an html photo album, Digital Camera
image files require no pre-processing, they just need to be placed in a
directories under /usr/photos. The name of the directory becomes the title
of the album, the image file name becomes the caption of the image.
.LP
.I Webphoto
renders images as a thumbnails, directories as a thumbnail of the first
image in that directory (with a down arrow), and directories containing no photos
or unreadable directories as a query icon.
.LP
Clicking on directory thumbnail decends into that image directory,
clicking on an image thumbnail displays the image with a drop shadow. Clicking
on this with display a thumbnail again, and any available camera metadata.
.LP
.I Webphoto
can operate unassisted but the thumbnail and metadata features require
.BR exifsrv(4) .
.I Exifserv
allows webphoto to extract thumbnails and EXIF metadata from digital camera
images rather than downloading full sized images and resizing them on the client's
browser.
.LP
The name that exifsrv(4) posts in /srv may be modified with the
.B -n
option, the default is
.IR exif ,
and its file permission flags changed
using -m. The file permissions must be modified for exif to work in conjunction with
webphoto as that is envoked from httpd and runs as none. Exifsrv takes care to
change its uid to none if the user mounting its /srv file is not the same as its
origional envoker. 
.SH EXAMPLE
.EX
	# add this line to /lib/namespace.html
	mount #s/exif /usr/photos /usr/photos

	# add these lines to cpurc
	exifsrv -m 666
	ip/httpd/httpd

	# populate /usr/web with your pictures,
	# these must be readable by anyone

	# follow this link
	http://www.yoursite.dom/magic/webphoto?dir=/
.EX
.SH BUGS
Its a shame that webphoto does not contain any resizing code. For JPEGs this could be
a lossless decode using just the DC coeficents from the DCTs, which would give an
8:1 size reduction for minimal processing.
.LP
The fullsize file created by exifsrv should present a reasonabbly sized image for
internet content rather than the entire photo file including metadata and thumbnail,
downsampling as required. This will become more important as very high
resolution digital cameras become common.

Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to webmaster@9p.io.