Questions tagged [heightmap]

Heightmap is texture containing individual heights used to store terrain data.

Heightmaps textures are used to store geometric detail like terrain, object surface etc. It is used to simplify manipulation of such geometry and even speed up its rendering (if mesh generation moved into shaders).

In case the heightmap is stored in common raster image formats then for proper geometry restoration we need also additional info like: scale,position and orientation for such textures which are not stored in them. So those are usually stored in some separate config file, encoded into filename, or hardcoded into application that uses them.

180 questions
3
votes
2 answers

Draw thick, feathered line with variable thickness in plane C#

I'm creating a heightmap painting tool which uses a spline to paint the heightmap with a value from 0 to 1. The spline consists of several points each of which has different thickness (size/width) and this gets interpolated. The tool paints a…
Footch
  • 119
  • 1
  • 9
3
votes
2 answers

Drawing Road on Terrain Map

I have vertex Coordinates of Left and Right side of the road (Shown as green and black points). My terrain is an array which corners of squares represent a different height value. I was drawing my road by just giving interpolated heights to my each…
Berke Cagkan Toptas
  • 984
  • 2
  • 21
  • 31
3
votes
1 answer

OpenGL glVertexPointer returning 1281 - Can't figure out why

I have created a class to load Terrain points from a heightmap file; but drawing them causes a crash. I have narrowed down the error to the glVertexPointer() function which returns 1281 (invalid value I am led to believe). I have been through the…
jProg2015
  • 1,028
  • 8
  • 37
3
votes
1 answer

OpenGL: Terrain not drawing (heightmap)

EDIT: I'm thinking the problem might be when I'm loading the vertices and indices. Maybe focus on that section :) I'm trying to load a heightmap from a bmp file and displaying it in OpenGL. As with most things I try, everything compiles and runs…
RaptorDotCpp
  • 1,375
  • 12
  • 25
3
votes
1 answer

Normal map from height map artifact

I'm baking normal map on the fragment shader from a height map. The height map looks great and looks smooth. However, when I generate the normal map I get very weird result. Here are two rendered images that show the problem, one with all lighting…
Jón Trausti Arason
  • 4,021
  • 1
  • 30
  • 45
3
votes
1 answer

Heightmap in Shader not working

I'm trying to implement GPU-based geometry clipmapping and have problems to apply a simple heightmap to my terrain. For the heightmap I use a simple texture with the surface format "single". I've taken the texture from Catalinz's XNA blog. What I'm…
CShark
  • 1,178
  • 14
  • 23
2
votes
2 answers

OpenGL Terrain Colission Detection

Okay, I have some procedurally generated terrain (based loosely on http://www.swiftless.com/terraintuts.html) Ive got a teapot "plane" which you can fly around in (third person camera) Basically, the aim is to fly through the valleys etc... without…
James Bennet
  • 593
  • 2
  • 9
  • 22
2
votes
0 answers

How to create a terrain mesh from a heightmap in LibGdx

I am working on a top down game - currently the terrain is a tilemap that is generated based on a heightmap array that holds height values ranging from 0 to 255. I want to change this and instead render a terrain mesh. I understand the basic idea…
Mihai Fumarel
  • 105
  • 1
  • 12
2
votes
2 answers

SceneKit shader modifier for geometry entry points works in iOS but not OS X

I'm in the early stages of making a SceneKit shader modifier (for the geometry entry point) that displaces a plane's geometry according to a height-map texture. The plan is to use it for creating terrain. In iOS (edit: the iOS Simulator) the shader…
OliverD
  • 899
  • 12
  • 16
2
votes
2 answers

Procedural terrain generation with blocks

I am using three.js to create procedurally generated terrain using Perlin Noise. I am creating the terrain using a series of blocks, but their heights along their borders are not corresponding to one another as you can see below. How should I…
fabridigua
  • 53
  • 7
2
votes
1 answer

Finding height of point on height map triangles

This question has to exist somewhere, but I'm not sure what it would be called. Following a height map, a terrain exists of right angle triangles. Each point of each triangle takes its height (y) from the height map. If the character is at a…
2
votes
1 answer

make seamless height-map texture for sphere (planet)

I'm trying to generate height-map for spherical planet with perlin noise. How can I make it with seamless left/right borders? I smoothed heightmap in poles, but cannot understand how can I loop left and right sides. This is how my textures look…
Yuri
  • 209
  • 2
  • 11
2
votes
1 answer

PhysX Terrain - Heightfield vs TriangleMesh

I'm working on a project in which I need to create a terrain in my PhysX application. As input data I have dted file (elevation). Which is the better way for create a terrain in PhysX? I need to have a large terrain. I have try to create an…
DaxDeveloper
  • 128
  • 12
2
votes
0 answers

Java LWJGL - How can I create proper maps using heightmaps?

So right now I am using greyscale heightmaps to load the height of the terrain to my game. So far I cannot seem to create a heightmap in which I can actually control where land masses are etc. I just get something like this: These hills are…
Kyle Jensen
  • 389
  • 6
  • 22
2
votes
1 answer

Java LWJGL Heightmap rendering

Hello I wan't to do heightmap based game and I have optimization problem. I acctualy rendering in DisplayList but when I want to render heightmap 512x512 I have only 20-30 fps. I tried something in vbo but that don't work. Here is my sourcecode to…
NoName
  • 33
  • 7
1
2
3
11 12