#include "llmath.h"
Go to the source code of this file.
Defines | |
#define | B 0x100 |
#define | BM 0xff |
#define | N 0x1000 |
#define | NF32 (4096.f) |
#define | NP 12 |
#define | NM 0xfff |
#define | s_curve(t) ( t * t * (3.f - 2.f * t) ) |
#define | lerp_m(t, a, b) ( a + t * (b - a) ) |
#define | setup_noise(i, b0, b1, r0, r1) |
Functions | |
F32 | turbulence2 (F32 *v, F32 freq) |
F32 | turbulence3 (float *v, float freq) |
F32 | clouds3 (float *v, float freq) |
F32 | noise2 (float *vec) |
F32 | noise3 (float *vec) |
F32 | bias (F32 a, F32 b) |
F32 | gain (F32 a, F32 b) |
static void | init (void) |
void | fast_setup (F32 vec, U8 &b0, U8 &b1, F32 &r0, F32 &r1) |
F32 | noise1 (const F32 arg) |
F32 | fast_at2 (F32 rx, F32 ry, F32 *q) |
F32 | fast_at3 (F32 rx, F32 ry, F32 rz, F32 *q) |
static void | normalize2 (F32 v[2]) |
static void | normalize3 (F32 v[3]) |
Variables | |
S32 | p [B+B+2] |
F32 | g3 [B+B+2][3] |
F32 | g2 [B+B+2][2] |
F32 | g1 [B+B+2] |
S32 | gNoiseStart |
Copyright (c) 2000-2008, Linden Research, Inc.
Second Life Viewer Source Code The source code in this file ("Source Code") is provided by Linden Lab to you under the terms of the GNU General Public License, version 2.0 ("GPL"), unless you have obtained a separate licensing agreement ("Other License"), formally executed by you and Linden Lab. Terms of the GPL can be found in doc/GPL-license.txt in this distribution, or online at http://secondlifegrid.net/programs/open_source/licensing/gplv2
There are special exceptions to the terms and conditions of the GPL as it is applied to this Source Code. View the full text of the exception in the file doc/FLOSS-exception.txt in this software distribution, or online at http://secondlifegrid.net/programs/open_source/licensing/flossexception
By copying, modifying or distributing this software, you acknowledge that you have read and understood your obligations described above, and agree to abide by those obligations.
ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, COMPLETENESS OR PERFORMANCE. $/LicenseInfo$
Definition in file noise.h.
Definition at line 43 of file noise.h.
References indra::base::lllog::log().
Referenced by LLAgent::calcFocusOffset(), LLStringBase< T >::compareDict(), LLImageTGA::decodeAndProcess(), and LLFace::renderSelectedUV().
F32 clouds3 | ( | float * | v, | |
float | freq | |||
) | [inline] |
Definition at line 48 of file noise.h.
References indra::base::lllog::log(), and p.
Referenced by LLAudioEngine::mapWindVecToGain(), process_attached_sound(), process_attached_sound_gain_change(), process_sound_trigger(), LLViewerObject::processUpdateMessage(), and LLVOAvatar::updateCharacter().
static void init | ( | void | ) | [static] |
Definition at line 316 of file noise.h.
References B, g1, g2, g3, i, j, normalize2(), normalize3(), and p.
Referenced by tut::LLTemplateMessageBuilderTestData::defaultTemplate(), LLUUID::getCurrentTime(), idle_startup(), tut::LLMessageSystemTestData::LLMessageSystemTestData(), LLVFSFileBlock::LLVFSFileBlock(), noise1(), noise2(), and noise3().
Definition at line 148 of file noise.h.
References g1, gNoiseStart, init(), lerp_m, p, s_curve, and setup_noise.
Referenced by LLVOAvatar::idleUpdate(), and LLDrawPoolAvatar::renderAvatars().
F32 noise2 | ( | float * | vec | ) |
Definition at line 47 of file noise.cpp.
References fast_at2(), fast_setup(), g2, gNoiseStart, i, init(), j, lerp_m, p, S32, and s_curve.
Referenced by LLSurfacePatch::eval(), LLVLComposition::generateHeights(), LLBodyNoiseMotion::onUpdate(), and turbulence2().
F32 noise3 | ( | float * | vec | ) | [inline] |
Definition at line 183 of file noise.h.
References d, fast_at3(), fast_setup(), g3, gNoiseStart, i, init(), j, lerp_m, p, S32, and s_curve.
Referenced by clouds3(), and turbulence3().
Definition at line 62 of file noise.h.
References noise2().
Referenced by LLVLComposition::generateHeights().
F32 turbulence3 | ( | float * | v, | |
float | freq | |||
) | [inline] |
Definition at line 74 of file noise.h.
References noise3().
Referenced by LLVOTree::updateGeometry().