Blender V4.3
DNA_texture_types.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2001-2002 NaN Holding BV. All rights reserved.
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9#pragma once
10
11#include "DNA_ID.h"
12#include "DNA_defs.h"
13#include "DNA_image_types.h" /* ImageUser */
14
15struct AnimData;
16struct ColorBand;
17struct CurveMapping;
18struct Image;
19struct Ipo;
20struct Object;
21struct PreviewImage;
22struct Tex;
23
24/* -------------------------------------------------------------------- */
27
28typedef struct MTex {
30
32 char _pad2[2];
33 struct Object *object;
34 struct Tex *tex;
36 char uvname[68];
37
40
46
47 float ofs[3], size[3], rot, random_angle;
48
49 float r, g, b, k;
50 float def_var;
51
52 /* common */
53 float colfac;
54 float alphafac;
55
56 /* particles */
60 float twistfac;
62
64
65/* -------------------------------------------------------------------- */
68
69#ifndef DNA_USHORT_FIX
70# define DNA_USHORT_FIX
76typedef unsigned short dna_ushort_fix;
77#endif
78
79typedef struct CBData {
80 float r, g, b, a, pos;
81 int cur;
83
88typedef struct ColorBand {
89 short tot, cur;
92 char _pad[1];
93
96
98
99/* -------------------------------------------------------------------- */
102
152
154
155/* -------------------------------------------------------------------- */
158
159typedef struct Tex {
161
162 ID id;
164 struct AnimData *adt;
170
174 char _pad2[4];
175
176 /* newnoise: musgrave parameters */
178
179 /* newnoise: distorted noise amount, musgrave & voronoi output scale */
181
182 /* newnoise: voronoi nearest neighbor weights, minkovsky exponent,
183 * distance metric & color type */
184 float vn_w1;
185 float vn_w2;
186 float vn_w3;
187 float vn_w4;
188 float vn_mexp;
190
191 /* noisedepth MUST be <= 30 else we get floating point exceptions */
193
194 /* newnoise: noisebasis type for clouds/marble/etc, noisebasis2 only used for distorted noise */
196
197 short imaflag, flag;
198 short type, stype;
199
203 int afmax;
205 short extend;
206
207 /* Variables only used for versioning, moved to struct member `iuser`. */
208 short _pad0;
210 int frames DNA_DEPRECATED;
211 int offset DNA_DEPRECATED;
213
215 char _pad1[4];
216
218
220 /* old animation system, deprecated for 2.5 */
221 struct Ipo *ipo DNA_DEPRECATED;
222 struct Image *ima;
225
227 char _pad[7];
228
230
232typedef struct TexMapping {
233 float loc[3];
235 float rot[3];
236 float size[3];
237 int flag;
239 int type;
240
241 float mat[4][4];
242 float min[3], max[3];
243 struct Object *ob;
244
246
247typedef struct ColorMapping {
249
251 int flag;
252
253 float blend_color[3];
256 char _pad[4];
258
260
261/* -------------------------------------------------------------------- */
264
266enum {
270};
271
273enum {
278};
279
281enum {
283};
284
286
287/* -------------------------------------------------------------------- */
290
292enum {
301 // TEX_PLUGIN = 9, /* Deprecated */
302 // TEX_ENVMAP = 10, /* Deprecated */
306 // TEX_POINTDENSITY = 14, /* Deprecated */
307 // TEX_VOXELDATA = 15, /* Deprecated */
308 // TEX_OCEAN = 16, /* Deprecated */
309};
310
312enum {
318};
319
321enum {
332};
333
335enum {
343};
344
346enum {
347 TEX_INTERPOL = 1 << 0,
348 TEX_USEALPHA = 1 << 1,
349 TEX_MIPMAP = 1 << 2,
350 TEX_IMAROT = 1 << 4,
352 TEX_NORMALMAP = 1 << 11,
353 TEX_GAUSS_MIP = 1 << 12,
354 TEX_FILTER_MIN = 1 << 13,
356};
357
359enum {
360 TXF_BOX = 0, /* Blender's old texture filtering method. */
364};
365
367enum {
370 TEX_NEGALPHA = 1 << 2,
374 TEX_PRV_NOR = 1 << 6,
378 TEX_NO_CLAMP = 1 << 10,
379};
380
382enum {
388};
389
391enum {
394};
395
397enum {
401};
402
404enum {
409};
410
412enum {
415};
416
418enum {
422};
423
425enum {
433};
434
436enum {
440};
441
443enum {
448};
449
451enum {
454};
455
462enum {
466};
467
469
470/* -------------------------------------------------------------------- */
473
479enum {
484};
485
487
488/* -------------------------------------------------------------------- */
491
493enum {
498};
499
501enum {
518};
519
521enum {
528};
529
531enum {
534};
535
537
538/* -------------------------------------------------------------------- */
541
543enum {
547};
548
550enum {
556};
557
559enum {
564};
565
567
568/* -------------------------------------------------------------------- */
571
573enum {
577};
578
580enum {
588};
589
591enum {
595};
596
598enum {
601};
602
604enum {
606 // TEX_PD_NOISE_VEL = 1, /* Deprecated. */
607 // TEX_PD_NOISE_AGE = 2, /* Deprecated. */
608 // TEX_PD_NOISE_TIME = 3, /* Deprecated. */
609};
610
612enum {
614 /* color_source: particles */
618 /* color_source: vertices */
622};
623
ID and Library types, which are fundamental for SDNA.
#define DNA_DEFINE_CXX_METHODS(class_name)
Definition DNA_defs.h:66
@ TEX_BANDNOISE
@ TEX_RINGNOISE
@ TEX_RING
@ TEX_BAND
unsigned short dna_ushort_fix
@ TEX_INT
@ TEX_RGB
@ TEX_PD_FALLOFF_CURVE
@ TEX_PD_TURBULENCE
@ TEX_NOISEPERL
@ TEX_NOISESOFT
@ MTEX_MAP_MODE_AREA
@ MTEX_MAP_MODE_3D
@ MTEX_MAP_MODE_STENCIL
@ MTEX_MAP_MODE_TILED
@ MTEX_MAP_MODE_RANDOM
@ MTEX_MAP_MODE_VIEW
@ COLBAND_BLEND_RGB
@ COLBAND_BLEND_HSL
@ COLBAND_BLEND_HSV
@ TEX_SIN
@ TEX_SAW
@ TEX_TRI
@ COLBAND_HUE_FAR
@ COLBAND_HUE_CW
@ COLBAND_HUE_NEAR
@ COLBAND_HUE_CCW
@ TEX_PD_OBJECTSPACE
@ TEX_PD_OBJECTLOC
@ TEX_PD_WORLDSPACE
@ TEX_DIAG
@ TEX_EASE
@ TEX_HALO
@ TEX_QUAD
@ TEX_RAD
@ TEX_SPHERE
@ TEX_LIN
@ TEX_PD_NOISE_STATIC
@ TEX_PLASTIC
@ TEX_WALLIN
@ TEX_WALLOUT
@ TEX_NO_CLAMP
@ TEX_DS_EXPAND
@ TEX_REPEAT_YMIR
@ TEX_CHECKER_EVEN
@ TEX_PRV_NOR
@ TEX_FLIPBLEND
@ TEX_PRV_ALPHA
@ TEX_NEGALPHA
@ TEX_COLORBAND
@ TEX_REPEAT_XMIR
@ TEX_CHECKER_ODD
@ MTEX_ANGLE_RANDOM
@ MTEX_ANGLE_RAKE
@ MTEX_DIFF
@ MTEX_DIV
@ MTEX_BLEND_VAL
@ MTEX_MUL
@ MTEX_DARK
@ MTEX_BLEND_HUE
@ MTEX_LIGHT
@ MTEX_BLEND_COLOR
@ MTEX_BLEND
@ MTEX_SOFT_LIGHT
@ MTEX_LIN_LIGHT
@ MTEX_SUB
@ MTEX_ADD
@ MTEX_OVERLAY
@ MTEX_SCREEN
@ MTEX_BLEND_SAT
struct ColorBand ColorBand
@ TEX_PD_OBJECT
@ TEX_PD_FILE
@ TEX_PD_PSYS
struct TexMapping TexMapping
@ TEX_PR_OTHER
@ TEX_PR_BOTH
@ TEX_PR_TEXTURE
@ TEX_PD_COLOR_VERTWEIGHT
@ TEX_PD_COLOR_VERTNOR
@ TEX_PD_COLOR_VERTCOL
@ TEX_PD_COLOR_PARTAGE
@ TEX_PD_COLOR_CONSTANT
@ TEX_PD_COLOR_PARTVEL
@ TEX_PD_COLOR_PARTSPEED
@ TEX_DEFAULT
@ TEX_COLOR
@ TEX_CHEBYCHEV
@ TEX_DISTANCE_SQUARED
@ TEX_MINKOVSKY_FOUR
@ TEX_MINKOVSKY_HALF
@ TEX_MANHATTAN
@ TEX_DISTANCE
@ TEX_MINKOVSKY
@ TEXMAP_TYPE_NORMAL
@ TEXMAP_TYPE_POINT
@ TEXMAP_TYPE_TEXTURE
@ TEXMAP_TYPE_VECTOR
struct ColorMapping ColorMapping
@ TEX_SHARPER
@ TEX_SOFT
@ TEX_SHARP
@ COLBAND_INTERP_LINEAR
@ COLBAND_INTERP_CONSTANT
@ COLBAND_INTERP_B_SPLINE
@ COLBAND_INTERP_EASE
@ COLBAND_INTERP_CARDINAL
@ TEX_CLIP
@ TEX_EXTEND
@ TEX_CHECKER
@ TEX_REPEAT
@ TEX_CLIPCUBE
@ TEX_PD_FALLOFF_PARTICLE_VEL
@ TEX_PD_FALLOFF_PARTICLE_AGE
@ TEX_PD_FALLOFF_ROOT
@ TEX_PD_FALLOFF_STD
@ TEX_PD_FALLOFF_SMOOTH
@ TEX_PD_FALLOFF_SOFT
@ TEX_PD_FALLOFF_CONSTANT
@ MTEX_FLAT
@ MTEX_SPHERE
@ MTEX_CUBE
@ MTEX_TUBE
@ TEX_HYBRIDMF
@ TEX_MFRACTAL
@ TEX_HTERRAIN
@ TEX_FBM
@ TEX_RIDGEDMF
@ TEX_BLENDER
@ TEX_STDPERLIN
@ TEX_VORONOI_CRACKLE
@ TEX_VORONOI_F2
@ TEX_VORONOI_F2F1
@ TEX_NEWPERLIN
@ TEX_VORONOI_F1
@ TEX_VORONOI_F4
@ TEX_VORONOI_F3
@ TEX_CELLNOISE
struct CBData CBData
@ TEX_COL2
@ TEX_COL1
@ TEX_COL3
@ TEX_INTENSITY
@ TEX_BLEND
@ TEX_MARBLE
@ TEX_NOISE
@ TEX_IMAGE
@ TEX_WOOD
@ TEX_CLOUDS
@ TEX_DISTNOISE
@ TEX_VORONOI
@ TEX_STUCCI
@ TEX_MAGIC
@ TEX_MUSGRAVE
@ TEXMAP_CLIP_MIN
@ TEXMAP_UNIT_MATRIX
@ TEXMAP_CLIP_MAX
@ TXF_FELINE
@ TXF_BOX
@ TXF_AREA
@ TXF_EWA
@ TEX_USEALPHA
@ TEX_MIPMAP
@ TEX_CALCALPHA
@ TEX_INTERPOL
@ TEX_GAUSS_MIP
@ TEX_FILTER_MIN
@ TEX_IMAROT
@ TEX_DERIVATIVEMAP
@ TEX_NORMALMAP
@ COLORMAP_USE_RAMP
int len
CBData data[32]
struct ColorBand coba
Definition DNA_ID.h:413
short texco
float fieldfac
char brush_angle_mode
float roughfac
float kinkampfac
float colfac
float lifefac
float padensfac
char brush_map_mode
short blendtype
float kinkfac
float dampfac
float def_var
char _pad2[2]
float clumpfac
float ivelfac
short which_output
float ofs[3]
short mapto
float timefac
float alphafac
float lengthfac
float size[3]
float gravityfac
float random_angle
char uvname[68]
float twistfac
float sizefac
struct Tex * tex
struct CurveMapping * falloff_curve
struct ColorBand * coba
char vertex_attribute_name[68]
float mat[4][4]
struct Object * ob
float cropymin
float dist_amount
struct AnimData * adt
float noisesize
short xrepeat
float vn_w4
short noisedepth
float ns_outscale
short noisetype
float vn_w2
short imaflag
DrawDataList drawdata
float cropxmax
float checkerdist
float cropymax
struct PreviewImage * preview
short _pad0
char _pad2[4]
float mg_lacunarity
float mg_offset
float nabla
char use_nodes
float vn_mexp
float mg_gain
float saturation
short noisebasis2
short vn_coltype
int len DNA_DEPRECATED
float contrast
short stype
float mg_octaves
struct ImageUser iuser
struct ColorBand * coba
float bright
short vn_distm
float cropxmin
float vn_w3
char _pad[7]
struct bNodeTree * nodetree
char _pad1[4]
short noisebasis
float vn_w1
struct Image * ima
short extend
short yrepeat
float turbul
float filtersize