mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-22 08:58:47 +00:00
Geomorph is a height field generator and editor for the Linux
operating system. A height field is a kind of topographic map. It is a 2D projection of a 3D landscape. Geomorph generates square images and shows a 3D preview of the resulting landscape. The resulting 2D image can be processed with a tool like Povray for rendering the landscape. WWW: http://geomorph.sourceforge.net/ PR: ports/94521 Submitted by: Dmitry Marakasov <amdmi3@mail.ru>
This commit is contained in:
parent
0f3bde51ba
commit
195e1f0a24
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=157572
@ -141,6 +141,7 @@
|
||||
SUBDIR += gdk-pixbuf
|
||||
SUBDIR += gdtclft
|
||||
SUBDIR += geist
|
||||
SUBDIR += geomorph
|
||||
SUBDIR += geomview
|
||||
SUBDIR += geos
|
||||
SUBDIR += gephex
|
||||
|
41
graphics/geomorph/Makefile
Normal file
41
graphics/geomorph/Makefile
Normal file
@ -0,0 +1,41 @@
|
||||
# ports collection makefile for: geomorph
|
||||
# Date created: 24 Feb 2006
|
||||
# Whom: Dmitry Marakasov <amdmi3@mail.ru>
|
||||
#
|
||||
# $FreeBSD$
|
||||
#
|
||||
|
||||
PORTNAME= geomorph
|
||||
PORTVERSION= 0.31
|
||||
CATEGORIES= graphics
|
||||
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
|
||||
MASTER_SITE_SUBDIR= ${PORTNAME}
|
||||
EXTRACT_SUFX= .tgz
|
||||
|
||||
MAINTAINER= amdmi3@mail.ru
|
||||
COMMENT= Height field generator and editor
|
||||
|
||||
LIB_DEPENDS= gtkglext-x11-1.0.2:${PORTSDIR}/x11-toolkits/gtkglext
|
||||
|
||||
USE_X_PREFIX= yes
|
||||
USE_GL= yes
|
||||
USE_GMAKE= yes
|
||||
GNU_CONFIGURE= yes
|
||||
|
||||
PLIST_SUB= PORTVERSION=${PORTVERSION}
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
.if ${OSVERSION} < 500000
|
||||
EXTRA_PATCHES= ${PATCHDIR}/extra-patch-*
|
||||
.endif
|
||||
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's|libpng|libpng12|' ${WRKSRC}/configure
|
||||
@${REINPLACE_CMD} -e 's|/usr/local/share/geomorph|${DATADIR}|' ${WRKSRC}/install-step* ${WRKSRC}/install-user ${WRKSRC}/src/app/app.c
|
||||
@${REINPLACE_CMD} -e 's|\$$HOME/geomorph|\$$HOME/.geomorph|' ${WRKSRC}/install-step* ${WRKSRC}/install-user
|
||||
@${REINPLACE_CMD} -e 's|>&|>|' ${WRKSRC}/install-step2-rcfile
|
||||
@${REINPLACE_CMD} -e '/DEFAULT_DIR/ s|geomorph|.geomorph|' ${WRKSRC}/src/app/globals.h ${WRKSRC}/src/hf/globals.h
|
||||
@${RM} ${WRKSRC}/install-step*.bak ${WRKSRC}/install-user*.bak
|
||||
|
||||
.include <bsd.port.post.mk>
|
3
graphics/geomorph/distinfo
Normal file
3
graphics/geomorph/distinfo
Normal file
@ -0,0 +1,3 @@
|
||||
MD5 (geomorph-0.31.tgz) = 778b2ec4efba77b7efb402bc17dc90ac
|
||||
SHA256 (geomorph-0.31.tgz) = 8c505f6ee9a0d4c53565e608e68a62b54b966bbae41ced562fabcb191f0097a1
|
||||
SIZE (geomorph-0.31.tgz) = 1041449
|
34
graphics/geomorph/files/extra-patch-src-hf-gl_preview.c
Normal file
34
graphics/geomorph/files/extra-patch-src-hf-gl_preview.c
Normal file
@ -0,0 +1,34 @@
|
||||
--- src/hf/gl_preview.c.orig Wed Nov 23 06:44:22 2005
|
||||
+++ src/hf/gl_preview.c Mon Mar 6 12:59:24 2006
|
||||
@@ -337,10 +337,10 @@
|
||||
// printf ("Realize Event\n");
|
||||
|
||||
gl_preview_struct *gl_hf;
|
||||
- gl_hf = ((hf_wrapper_struct *) data)->gl_preview;
|
||||
|
||||
GdkGLContext *glcontext = gtk_widget_get_gl_context (widget);
|
||||
GdkGLDrawable *gldrawable = gtk_widget_get_gl_drawable (widget);
|
||||
+ gl_hf = ((hf_wrapper_struct *) data)->gl_preview;
|
||||
|
||||
/*** OpenGL BEGIN ***/
|
||||
if (!gdk_gl_drawable_gl_begin (gldrawable, glcontext)) {
|
||||
@@ -588,6 +588,8 @@
|
||||
gint i;
|
||||
camera_struct *camera;
|
||||
gl_preview_struct *gl_hf;
|
||||
+ GdkGLContext *glcontext;
|
||||
+ GdkGLDrawable *gldrawable;
|
||||
gl_hf = ((hf_wrapper_struct *) data)->gl_preview;
|
||||
camera = gl_hf->cameras[gl_hf->current_camera_id];
|
||||
/* Draw only on the last expose event. */
|
||||
@@ -600,8 +602,8 @@
|
||||
|
||||
// printf("************* GL DRAWING 2 ************** - HFW: %d\n", data);
|
||||
|
||||
- GdkGLContext *glcontext = gtk_widget_get_gl_context (widget);
|
||||
- GdkGLDrawable *gldrawable = gtk_widget_get_gl_drawable (widget);
|
||||
+ glcontext = gtk_widget_get_gl_context (widget);
|
||||
+ gldrawable = gtk_widget_get_gl_drawable (widget);
|
||||
|
||||
/*** OpenGL BEGIN ***/
|
||||
if (!gdk_gl_drawable_gl_begin (gldrawable, glcontext))
|
11
graphics/geomorph/files/extra-patch-src-hf-hf_calc.c
Normal file
11
graphics/geomorph/files/extra-patch-src-hf-hf_calc.c
Normal file
@ -0,0 +1,11 @@
|
||||
--- src/hf/hf_calc.c.orig Tue Nov 22 07:25:40 2005
|
||||
+++ src/hf/hf_calc.c Mon Mar 6 13:08:02 2006
|
||||
@@ -1298,6 +1298,8 @@
|
||||
overflow);
|
||||
}
|
||||
|
||||
+#define lround(x) (((x) - (gdouble)(long int)(x)) < 0.5 ? (x) : (x+1.0))
|
||||
+
|
||||
void hf_fast_rotate (hf_type *hf_in, hf_type *hf_out, gint hf_size, gint angle) {
|
||||
// Rotation of a square HF, preview style, with aliasing
|
||||
// "Wraps"
|
13
graphics/geomorph/files/extra-patch-src-hf-subdiv1_dialog.c
Normal file
13
graphics/geomorph/files/extra-patch-src-hf-subdiv1_dialog.c
Normal file
@ -0,0 +1,13 @@
|
||||
--- src/hf/subdiv1_dialog.c.orig Thu Apr 7 05:34:56 2005
|
||||
+++ src/hf/subdiv1_dialog.c Mon Mar 6 12:55:02 2006
|
||||
@@ -55,9 +55,9 @@
|
||||
}
|
||||
|
||||
gint change_subdiv1_seed(GtkWidget *entry, gpointer data) {
|
||||
+ unsigned int s;
|
||||
hf_wrapper_struct *hfw;
|
||||
hfw = (hf_wrapper_struct *) * (hf_wrapper_struct **) data;
|
||||
- unsigned int s;
|
||||
// Avoid double display... the callback seems always to be called twice,
|
||||
// the first time with an empty entry, I don't know why
|
||||
// (maybe because "gtk_entry_set_text" blanks the field before writing in it??)
|
65
graphics/geomorph/files/patch-src-app-main.c
Normal file
65
graphics/geomorph/files/patch-src-app-main.c
Normal file
@ -0,0 +1,65 @@
|
||||
--- src/app/main.c.orig Sun Nov 6 08:52:50 2005
|
||||
+++ src/app/main.c Tue Feb 28 04:00:28 2006
|
||||
@@ -19,6 +19,7 @@
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
+#include <sys/param.h>
|
||||
#include "./main.h"
|
||||
#include "./globals.h"
|
||||
// Gtkglext - 2005-11
|
||||
@@ -48,37 +49,21 @@
|
||||
if (command) free(command);
|
||||
}
|
||||
|
||||
+char *get_current_dir_name() {
|
||||
+ char *buf = malloc(MAXPATHLEN);
|
||||
+ getwd(buf);
|
||||
+ return buf;
|
||||
+}
|
||||
+
|
||||
gchar *find_config_file() {
|
||||
// Returns the config file name (name OPTIONS_FILE, defined in globals.h),
|
||||
// with its full path
|
||||
gchar *default_dir, *path_n_file, *buf, *command;
|
||||
gboolean shortcuts;
|
||||
|
||||
-// We try:
|
||||
-// 1. in the current directory. (./OPTIONS_FILE = ./geomorphrc)
|
||||
-// 2. if not found, we try ./DEFAULT_DIR/OPTIONS_FILE (./geomorph/geomorphrc)
|
||||
-// 3. if not found, we try $HOME/OPTIONS_FILE (~/geomorphrc)
|
||||
-// 4. if not found, we try in $HOME/DEFAULT_DIR (~/geomorph/geomorphrc)
|
||||
-// --> if OPTIONS_FILE was not found, and
|
||||
-// if $HOME/DEFAULT_DIR doesn't exist, we create the required files
|
||||
-// The directory where OPTIONS_FILE is found becomes the default one (DEF_DIR)
|
||||
-
|
||||
- // Try ./OPTIONS_FILE
|
||||
- default_dir = (gchar *) get_current_dir_name();
|
||||
- path_n_file = concat_dname_fname(default_dir,OPTIONS_FILE);
|
||||
- if (!filexists(path_n_file)) { // Try ./DEFAULT_DIR/OPTIONS_FILE
|
||||
- default_dir = concat_dname_fname(default_dir,DEFAULT_DIR);
|
||||
- if (path_n_file)
|
||||
- free(path_n_file);
|
||||
- path_n_file = concat_dname_fname(default_dir,OPTIONS_FILE);
|
||||
- if (!filexists(path_n_file)) { // Try in the home directory - ~/OPTIONS_FILE
|
||||
+ // Config file is located under $HOME/.geomorph/geomorphrc
|
||||
default_dir = getenv("HOME");
|
||||
- if (path_n_file)
|
||||
- free(path_n_file);
|
||||
- path_n_file = concat_dname_fname(default_dir, OPTIONS_FILE);
|
||||
- if (!filexists(path_n_file)) { // Try ~/DEFAULT_DIR/OPTIONS_FILE
|
||||
default_dir = concat_dname_fname(default_dir,DEFAULT_DIR);
|
||||
- if (path_n_file) free(path_n_file);
|
||||
path_n_file = concat_dname_fname(default_dir, OPTIONS_FILE);
|
||||
if (directory_exists(default_dir)) {
|
||||
if (!filexists(path_n_file)) {
|
||||
@@ -109,9 +94,6 @@
|
||||
}
|
||||
if (path_n_file) free(path_n_file);
|
||||
}
|
||||
- }
|
||||
- }
|
||||
- }
|
||||
return add_filesep(default_dir);
|
||||
}
|
||||
|
11
graphics/geomorph/pkg-descr
Normal file
11
graphics/geomorph/pkg-descr
Normal file
@ -0,0 +1,11 @@
|
||||
Geomorph is a height field generator and editor for the Linux
|
||||
operating system.
|
||||
|
||||
A height field is a kind of topographic map. It is a 2D projection
|
||||
of a 3D landscape.
|
||||
|
||||
Geomorph generates square images and shows a 3D preview of the
|
||||
resulting landscape. The resulting 2D image can be processed with
|
||||
a tool like Povray for rendering the landscape.
|
||||
|
||||
WWW: http://geomorph.sourceforge.net/
|
50
graphics/geomorph/pkg-plist
Normal file
50
graphics/geomorph/pkg-plist
Normal file
@ -0,0 +1,50 @@
|
||||
bin/geomorph
|
||||
%%DATADIR%%/%%PORTVERSION%%/AFAIRE
|
||||
%%DATADIR%%/%%PORTVERSION%%/FAQ
|
||||
%%DATADIR%%/%%PORTVERSION%%/FAQ-fr
|
||||
%%DATADIR%%/%%PORTVERSION%%/LISEZMOI
|
||||
%%DATADIR%%/%%PORTVERSION%%/README
|
||||
%%DATADIR%%/%%PORTVERSION%%/TODO
|
||||
%%DATADIR%%/%%PORTVERSION%%/geomorphrc
|
||||
%%DATADIR%%/%%PORTVERSION%%/geomorphrc_de
|
||||
%%DATADIR%%/%%PORTVERSION%%/geomorphrc_en
|
||||
%%DATADIR%%/%%PORTVERSION%%/geomorphrc_fr
|
||||
%%DATADIR%%/%%PORTVERSION%%/install-step1-dir
|
||||
%%DATADIR%%/%%PORTVERSION%%/install-step2-rcfile
|
||||
%%DATADIR%%/%%PORTVERSION%%/install-step3-desktop
|
||||
%%DATADIR%%/%%PORTVERSION%%/install-user
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/canyon.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/colmap
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/colmap.c
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/desert.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/desert_new.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/desert_with_tree.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/geomorph_txtr.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/global_settings.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/iced_satellite.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/maprock1.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/moon.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/mountains.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/olivier4.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/painted_desert.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/painted_desert_map1.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/painted_desert_map2.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/painted_desert_map3.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/sea_and_fog.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/sea_and_rocks.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/sea_n_moon.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/simple_terrain.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/slope_patterns.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/stars.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/sunseta.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/sunsetb.pov
|
||||
%%DATADIR%%/%%PORTVERSION%%/scenes/uranus.inc
|
||||
%%DATADIR%%/%%PORTVERSION%%/splash.jpg
|
||||
%%DATADIR%%/%%PORTVERSION%%/update-rc
|
||||
%%DATADIR%%/%%PORTVERSION%%/v0_30_new_sections
|
||||
%%DATADIR%%/GeoMorph.xpm
|
||||
%%DATADIR%%/Geomorph-gnome.desktop
|
||||
%%DATADIR%%/Geomorph-kde.desktop
|
||||
@dirrm %%DATADIR%%/%%PORTVERSION%%/scenes
|
||||
@dirrm %%DATADIR%%/%%PORTVERSION%%
|
||||
@dirrm %%DATADIR%%
|
Loading…
Reference in New Issue
Block a user