Blender  V3.3
transform_convert_nla.c
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2001-2002 NaN Holding BV. All rights reserved. */
3 
8 #include "DNA_anim_types.h"
9 #include "DNA_space_types.h"
10 
11 #include "MEM_guardedalloc.h"
12 
13 #include "BLI_listbase.h"
14 #include "BLI_math.h"
15 
16 #include "BKE_context.h"
17 #include "BKE_nla.h"
18 
19 #include "ED_anim_api.h"
20 #include "ED_markers.h"
21 
22 #include "WM_api.h"
23 #include "WM_types.h"
24 
25 #include "RNA_access.h"
26 #include "RNA_prototypes.h"
27 
28 #include "transform.h"
29 #include "transform_convert.h"
30 #include "transform_mode.h"
31 #include "transform_snap.h"
32 
34 typedef struct TransDataNla {
36  ID *id;
37 
39  struct NlaTrack *oldTrack;
41  struct NlaTrack *nlt;
42 
44  struct NlaStrip *strip;
45 
46  /* dummy values for transform to write in - must have 3 elements... */
48  float h1[3];
50  float h2[3];
51 
55  int handle;
57 
58 /* -------------------------------------------------------------------- */
63 {
64  Scene *scene = t->scene;
65  SpaceNla *snla = NULL;
66  TransData *td = NULL;
67  TransDataNla *tdn = NULL;
68 
69  bAnimContext ac;
70  ListBase anim_data = {NULL, NULL};
71  bAnimListElem *ale;
72  int filter;
73 
74  int count = 0;
75 
77 
78  /* determine what type of data we are operating on */
79  if (ANIM_animdata_get_context(C, &ac) == 0) {
80  return;
81  }
82  snla = (SpaceNla *)ac.sl;
83 
84  /* filter data */
87  ANIM_animdata_filter(&ac, &anim_data, filter, ac.data, ac.datatype);
88 
89  /* which side of the current frame should be allowed */
90  if (t->mode == TFM_TIME_EXTEND) {
91  t->frame_side = transform_convert_frame_side_dir_get(t, (float)scene->r.cfra);
92  }
93  else {
94  /* normal transform - both sides of current frame are considered */
95  t->frame_side = 'B';
96  }
97 
98  /* loop 1: count how many strips are selected (consider each strip as 2 points) */
99  for (ale = anim_data.first; ale; ale = ale->next) {
100  NlaTrack *nlt = (NlaTrack *)ale->data;
101  NlaStrip *strip;
102 
103  /* make some meta-strips for chains of selected strips */
105 
106  /* only consider selected strips */
107  for (strip = nlt->strips.first; strip; strip = strip->next) {
108  /* TODO: we can make strips have handles later on. */
109  /* transition strips can't get directly transformed */
110  if (strip->type != NLASTRIP_TYPE_TRANSITION) {
111  if (strip->flag & NLASTRIP_FLAG_SELECT) {
112  if (FrameOnMouseSide(t->frame_side, strip->start, (float)scene->r.cfra)) {
113  count++;
114  }
115  if (FrameOnMouseSide(t->frame_side, strip->end, (float)scene->r.cfra)) {
116  count++;
117  }
118  }
119  }
120  }
121  }
122 
123  /* stop if trying to build list if nothing selected */
124  if (count == 0) {
125  /* clear temp metas that may have been created but aren't needed now
126  * because they fell on the wrong side of scene->r.cfra
127  */
128  for (ale = anim_data.first; ale; ale = ale->next) {
129  NlaTrack *nlt = (NlaTrack *)ale->data;
130  BKE_nlastrips_clear_metas(&nlt->strips, 0, 1);
131  }
132 
133  /* cleanup temp list */
134  ANIM_animdata_freelist(&anim_data);
135  return;
136  }
137 
138  /* allocate memory for data */
139  tc->data_len = count;
140 
141  tc->data = MEM_callocN(tc->data_len * sizeof(TransData), "TransData(NLA Editor)");
142  td = tc->data;
143  tc->custom.type.data = tdn = MEM_callocN(tc->data_len * sizeof(TransDataNla),
144  "TransDataNla (NLA Editor)");
145  tc->custom.type.use_free = true;
146 
147  /* loop 2: build transdata array */
148  for (ale = anim_data.first; ale; ale = ale->next) {
149  /* only if a real NLA-track */
150  if (ale->type == ANIMTYPE_NLATRACK) {
151  AnimData *adt = ale->adt;
152  NlaTrack *nlt = (NlaTrack *)ale->data;
153  NlaStrip *strip;
154 
155  /* only consider selected strips */
156  for (strip = nlt->strips.first; strip; strip = strip->next) {
157  /* TODO: we can make strips have handles later on. */
158  /* transition strips can't get directly transformed */
159  if (strip->type != NLASTRIP_TYPE_TRANSITION) {
160  if (strip->flag & NLASTRIP_FLAG_SELECT) {
161  /* our transform data is constructed as follows:
162  * - only the handles on the right side of the current-frame get included
163  * - td structs are transform-elements operated on by the transform system
164  * and represent a single handle. The storage/pointer used (val or loc) depends on
165  * whether we're scaling or transforming. Ultimately though, the handles
166  * the td writes to will simply be a dummy in tdn
167  * - for each strip being transformed, a single tdn struct is used, so in some
168  * cases, there will need to be 1 of these tdn elements in the array skipped...
169  */
170  float center[3], yval;
171 
172  /* firstly, init tdn settings */
173  tdn->id = ale->id;
174  tdn->oldTrack = tdn->nlt = nlt;
175  tdn->strip = strip;
176  tdn->trackIndex = BLI_findindex(&adt->nla_tracks, nlt);
177 
178  yval = (float)(tdn->trackIndex * NLACHANNEL_STEP(snla));
179 
180  tdn->h1[0] = strip->start;
181  tdn->h1[1] = yval;
182  tdn->h2[0] = strip->end;
183  tdn->h2[1] = yval;
184 
185  center[0] = (float)scene->r.cfra;
186  center[1] = yval;
187  center[2] = 0.0f;
188 
189  /* set td's based on which handles are applicable */
190  if (FrameOnMouseSide(t->frame_side, strip->start, (float)scene->r.cfra)) {
191  /* just set tdn to assume that it only has one handle for now */
192  tdn->handle = -1;
193 
194  /* Now, link the transform data up to this data. */
195  td->loc = tdn->h1;
196  copy_v3_v3(td->iloc, tdn->h1);
197 
198  if (ELEM(t->mode, TFM_TRANSLATION, TFM_TIME_EXTEND)) {
199  /* Store all the other gunk that is required by transform. */
200  copy_v3_v3(td->center, center);
201  td->axismtx[2][2] = 1.0f;
202  td->flag |= TD_SELECTED;
203  unit_m3(td->mtx);
204  unit_m3(td->smtx);
205  }
206 
207  td->extra = tdn;
208  td++;
209  }
210  if (FrameOnMouseSide(t->frame_side, strip->end, (float)scene->r.cfra)) {
211  /* if tdn is already holding the start handle,
212  * then we're doing both, otherwise, only end */
213  tdn->handle = (tdn->handle) ? 2 : 1;
214 
215  /* Now, link the transform data up to this data. */
216  td->loc = tdn->h2;
217  copy_v3_v3(td->iloc, tdn->h2);
218 
219  if (ELEM(t->mode, TFM_TRANSLATION, TFM_TIME_EXTEND)) {
220  /* Store all the other gunk that is required by transform. */
221  copy_v3_v3(td->center, center);
222  td->axismtx[2][2] = 1.0f;
223  td->flag |= TD_SELECTED;
224  unit_m3(td->mtx);
225  unit_m3(td->smtx);
226  }
227 
228  td->extra = tdn;
229  td++;
230  }
231 
232  /* If both handles were used, skip the next tdn (i.e. leave it blank)
233  * since the counting code is dumb.
234  * Otherwise, just advance to the next one.
235  */
236  if (tdn->handle == 2) {
237  tdn += 2;
238  }
239  else {
240  tdn++;
241  }
242  }
243  }
244  }
245  }
246  }
247 
248  /* cleanup temp list */
249  ANIM_animdata_freelist(&anim_data);
250 }
251 
253 {
254  SpaceNla *snla = (SpaceNla *)t->area->spacedata.first;
255 
257 
258  /* handle auto-snapping
259  * NOTE: only do this when transform is still running, or we can't restore
260  */
261  if (t->state != TRANS_CANCEL) {
262  const short autosnap = getAnimEdit_SnapMode(t);
263  if (autosnap != SACTSNAP_OFF) {
264  TransData *td = tc->data;
265  for (int i = 0; i < tc->data_len; i++, td++) {
266  transform_snap_anim_flush_data(t, td, autosnap, td->loc);
267  }
268  }
269  }
270 
271  /* For each strip we've got, perform some additional validation of the values
272  * that got set before using RNA to set the value (which does some special
273  * operations when setting these values to make sure that everything works ok).
274  */
275  TransDataNla *tdn = tc->custom.type.data;
276  for (int i = 0; i < tc->data_len; i++, tdn++) {
277  NlaStrip *strip = tdn->strip;
278  PointerRNA strip_ptr;
279  int delta_y1, delta_y2;
280 
281  /* if this tdn has no handles, that means it is just a dummy that should be skipped */
282  if (tdn->handle == 0) {
283  continue;
284  }
285 
286  /* set refresh tags for objects using this animation,
287  * BUT only if realtime updates are enabled
288  */
289  if ((snla->flag & SNLA_NOREALTIMEUPDATES) == 0) {
290  ANIM_id_update(CTX_data_main(t->context), tdn->id);
291  }
292 
293  /* if canceling transform, just write the values without validating, then move on */
294  if (t->state == TRANS_CANCEL) {
295  /* clear the values by directly overwriting the originals, but also need to restore
296  * endpoints of neighboring transition-strips
297  */
298 
299  /* start */
300  strip->start = tdn->h1[0];
301 
302  if ((strip->prev) && (strip->prev->type == NLASTRIP_TYPE_TRANSITION)) {
303  strip->prev->end = tdn->h1[0];
304  }
305 
306  /* end */
307  strip->end = tdn->h2[0];
308 
309  if ((strip->next) && (strip->next->type == NLASTRIP_TYPE_TRANSITION)) {
310  strip->next->start = tdn->h2[0];
311  }
312 
313  /* flush transforms to child strips (since this should be a meta) */
315 
316  /* restore to original track (if needed) */
317  if (tdn->oldTrack != tdn->nlt) {
318  /* Just append to end of list for now,
319  * since strips get sorted in special_aftertrans_update(). */
320  BLI_remlink(&tdn->nlt->strips, strip);
321  BLI_addtail(&tdn->oldTrack->strips, strip);
322  }
323 
324  continue;
325  }
326 
327  /* firstly, check if the proposed transform locations would overlap with any neighboring strips
328  * (barring transitions) which are absolute barriers since they are not being moved
329  *
330  * this is done as a iterative procedure (done 5 times max for now)
331  */
332  NlaStrip *prev = strip->prev;
333  while (prev != NULL && (prev->type & NLASTRIP_TYPE_TRANSITION)) {
334  prev = prev->prev;
335  }
336 
337  NlaStrip *next = strip->next;
338  while (next != NULL && (next->type & NLASTRIP_TYPE_TRANSITION)) {
339  next = next->next;
340  }
341 
342  for (short iter = 0; iter < 5; iter++) {
343  const bool pExceeded = (prev != NULL) && (tdn->h1[0] < prev->end);
344  const bool nExceeded = (next != NULL) && (tdn->h2[0] > next->start);
345 
346  if ((pExceeded && nExceeded) || (iter == 4)) {
347  /* both endpoints exceeded (or iteration ping-pong'd meaning that we need a
348  * compromise)
349  * - Simply crop strip to fit within the bounds of the strips bounding it
350  * - If there were no neighbors, clear the transforms
351  * (make it default to the strip's current values).
352  */
353  if (prev && next) {
354  tdn->h1[0] = prev->end;
355  tdn->h2[0] = next->start;
356  }
357  else {
358  tdn->h1[0] = strip->start;
359  tdn->h2[0] = strip->end;
360  }
361  }
362  else if (nExceeded) {
363  /* move backwards */
364  float offset = tdn->h2[0] - next->start;
365 
366  tdn->h1[0] -= offset;
367  tdn->h2[0] -= offset;
368  }
369  else if (pExceeded) {
370  /* more forwards */
371  float offset = prev->end - tdn->h1[0];
372 
373  tdn->h1[0] += offset;
374  tdn->h2[0] += offset;
375  }
376  else { /* all is fine and well */
377  break;
378  }
379  }
380 
381  /* Use RNA to write the values to ensure that constraints on these are obeyed
382  * (e.g. for transition strips, the values are taken from the neighbors)
383  *
384  * NOTE: we write these twice to avoid truncation errors which can arise when
385  * moving the strips a large distance using numeric input T33852.
386  */
387  RNA_pointer_create(NULL, &RNA_NlaStrip, strip, &strip_ptr);
388 
389  RNA_float_set(&strip_ptr, "frame_start", tdn->h1[0]);
390  RNA_float_set(&strip_ptr, "frame_end", tdn->h2[0]);
391 
392  RNA_float_set(&strip_ptr, "frame_start", tdn->h1[0]);
393  RNA_float_set(&strip_ptr, "frame_end", tdn->h2[0]);
394 
395  /* flush transforms to child strips (since this should be a meta) */
397 
398  /* Now, check if we need to try and move track:
399  * - we need to calculate both,
400  * as only one may have been altered by transform if only 1 handle moved.
401  */
402  /* In LibOverride case, we cannot move strips across tracks that come from the linked data. */
403  const bool is_liboverride = ID_IS_OVERRIDE_LIBRARY(tdn->id);
405  continue;
406  }
407 
408  delta_y1 = ((int)tdn->h1[1] / NLACHANNEL_STEP(snla) - tdn->trackIndex);
409  delta_y2 = ((int)tdn->h2[1] / NLACHANNEL_STEP(snla) - tdn->trackIndex);
410 
411  /* If we cannot find the strip in the track, this strip has moved tracks already (if multiple
412  * strips using the same action from equal IDs such as meshes or shapekeys are selected) so can
413  * be skipped. */
414  if ((delta_y1 || delta_y2) && BLI_findindex(&tdn->nlt->strips, strip) != -1) {
415  NlaTrack *track;
416  int delta = (delta_y2) ? delta_y2 : delta_y1;
417  int n;
418 
419  /* Move in the requested direction,
420  * checking at each layer if there's space for strip to pass through,
421  * stopping on the last track available or that we're able to fit in.
422  */
423  if (delta > 0) {
424  for (track = tdn->nlt->next, n = 0; (track) && (n < delta); track = track->next, n++) {
425  /* check if space in this track for the strip */
426  if (BKE_nlatrack_has_space(track, strip->start, strip->end) &&
428  /* move strip to this track */
429  BLI_remlink(&tdn->nlt->strips, strip);
430  BKE_nlatrack_add_strip(track, strip, is_liboverride);
431 
432  tdn->nlt = track;
433  tdn->trackIndex++;
434  }
435  else { /* can't move any further */
436  break;
437  }
438  }
439  }
440  else {
441  /* make delta 'positive' before using it, since we now know to go backwards */
442  delta = -delta;
443 
444  for (track = tdn->nlt->prev, n = 0; (track) && (n < delta); track = track->prev, n++) {
445  /* check if space in this track for the strip */
446  if (BKE_nlatrack_has_space(track, strip->start, strip->end) &&
448  /* move strip to this track */
449  BLI_remlink(&tdn->nlt->strips, strip);
450  BKE_nlatrack_add_strip(track, strip, is_liboverride);
451 
452  tdn->nlt = track;
453  tdn->trackIndex--;
454  }
455  else { /* can't move any further */
456  break;
457  }
458  }
459  }
460  }
461  }
462 }
463 
466 /* -------------------------------------------------------------------- */
471 {
472  bAnimContext ac;
473 
474  /* initialize relevant anim-context 'context' data */
475  if (ANIM_animdata_get_context(C, &ac) == 0) {
476  return;
477  }
478 
479  if (ac.datatype) {
480  ListBase anim_data = {NULL, NULL};
481  bAnimListElem *ale;
483 
484  /* get channels to work on */
485  ANIM_animdata_filter(&ac, &anim_data, filter, ac.data, ac.datatype);
486 
487  for (ale = anim_data.first; ale; ale = ale->next) {
488  NlaTrack *nlt = (NlaTrack *)ale->data;
489 
490  /* make sure strips are in order again */
492 
493  /* remove the temp metas */
494  BKE_nlastrips_clear_metas(&nlt->strips, 0, 1);
495  }
496 
497  /* General refresh for the outliner because the following might have happened:
498  * - strips moved between tracks
499  * - strips swapped order
500  * - duplicate-move moves to different track. */
502 
503  /* free temp memory */
504  ANIM_animdata_freelist(&anim_data);
505 
506  /* Perform after-transform validation. */
508  }
509 }
510 
514  /* flags */ (T_POINTS | T_2D_EDIT),
515  /* createTransData */ createTransNlaData,
516  /* recalcData */ recalcData_nla,
517  /* special_aftertrans_update */ special_aftertrans_update__nla,
518 };
typedef float(TangentPoint)[2]
struct Main * CTX_data_main(const bContext *C)
Definition: context.c:1074
bool BKE_nlatrack_is_nonlocal_in_liboverride(const struct ID *id, const struct NlaTrack *nlt)
void BKE_nlatrack_sort_strips(struct NlaTrack *nlt)
Definition: nla.c:1157
bool BKE_nlatrack_has_space(struct NlaTrack *nlt, float start, float end)
Definition: nla.c:1137
void BKE_nlastrips_clear_metas(ListBase *strips, bool only_sel, bool only_temp)
Definition: nla.c:877
void BKE_nlameta_flush_transforms(struct NlaStrip *mstrip)
Definition: nla.c:950
bool BKE_nlatrack_add_strip(struct NlaTrack *nlt, struct NlaStrip *strip, bool is_liboverride)
Definition: nla.c:1168
void BKE_nlastrips_make_metas(ListBase *strips, bool is_temp)
Definition: nla.c:802
void BLI_addtail(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
Definition: listbase.c:80
void BLI_remlink(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
Definition: listbase.c:100
int BLI_findindex(const struct ListBase *listbase, const void *vlink) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
void unit_m3(float m[3][3])
Definition: math_matrix.c:40
MINLINE void copy_v3_v3(float r[3], const float a[3])
#define UNUSED(x)
#define ELEM(...)
#define ID_IS_OVERRIDE_LIBRARY(_id)
Definition: DNA_ID.h:588
@ SACTSNAP_OFF
@ NLASTRIP_FLAG_SELECT
@ NLASTRIP_TYPE_TRANSITION
@ SNLA_NOREALTIMEUPDATES
@ ANIMTYPE_NLATRACK
Definition: ED_anim_api.h:238
void ED_nla_postop_refresh(bAnimContext *ac)
Definition: nla_edit.c:59
#define NLACHANNEL_STEP(snla)
Definition: ED_anim_api.h:466
@ ANIMFILTER_FOREDIT
Definition: ED_anim_api.h:312
@ ANIMFILTER_DATA_VISIBLE
Definition: ED_anim_api.h:292
@ ANIMFILTER_LIST_VISIBLE
Definition: ED_anim_api.h:295
@ ANIMFILTER_FCURVESONLY
Definition: ED_anim_api.h:328
@ TFM_TIME_EXTEND
Definition: ED_transform.h:53
@ TFM_TRANSLATION
Definition: ED_transform.h:30
NSNotificationCenter * center
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble y2 _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat y2 _GL_VOID_RET _GL_VOID GLint GLint GLint y2 _GL_VOID_RET _GL_VOID GLshort GLshort GLshort y2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLuint *buffer _GL_VOID_RET _GL_VOID GLdouble t _GL_VOID_RET _GL_VOID GLfloat t _GL_VOID_RET _GL_VOID GLint t _GL_VOID_RET _GL_VOID GLshort t _GL_VOID_RET _GL_VOID GLdouble t
Read Guarded memory(de)allocation.
#define C
Definition: RandGen.cpp:25
#define NC_ANIMATION
Definition: WM_types.h:338
#define NA_ADDED
Definition: WM_types.h:525
#define ND_NLA
Definition: WM_types.h:445
void ANIM_animdata_freelist(ListBase *anim_data)
Definition: anim_deps.c:397
void ANIM_id_update(Main *bmain, ID *id)
Definition: anim_deps.c:99
bool ANIM_animdata_get_context(const bContext *C, bAnimContext *ac)
Definition: anim_filter.c:379
size_t ANIM_animdata_filter(bAnimContext *ac, ListBase *anim_data, eAnimFilter_Flags filter_mode, void *data, eAnimCont_Types datatype)
Definition: anim_filter.c:3447
Scene scene
DO_INLINE void filter(lfVector *V, fmatrix3x3 *S)
int count
ccl_gpu_kernel_postfix ccl_global float int int int int float bool int offset
void *(* MEM_callocN)(size_t len, const char *str)
Definition: mallocn.c:31
static ulong * next
SymEdge< T > * prev(const SymEdge< T > *se)
Definition: delaunay_2d.cc:105
void RNA_pointer_create(ID *id, StructRNA *type, void *data, PointerRNA *r_ptr)
Definition: rna_access.c:136
void RNA_float_set(PointerRNA *ptr, const char *name, float value)
Definition: rna_access.c:4968
#define TRANS_DATA_CONTAINER_FIRST_SINGLE(t)
ListBase nla_tracks
Definition: DNA_ID.h:368
void * first
Definition: DNA_listBase.h:31
struct NlaStrip * next
struct NlaStrip * prev
ListBase strips
struct NlaTrack * next
struct NlaTrack * prev
struct RenderData r
struct NlaTrack * oldTrack
struct NlaTrack * nlt
struct NlaStrip * strip
float smtx[3][3]
float axismtx[3][3]
float mtx[3][3]
short datatype
Definition: ED_anim_api.h:62
void * data
Definition: ED_anim_api.h:60
struct SpaceLink * sl
Definition: ED_anim_api.h:74
struct bAnimListElem * next
Definition: ED_anim_api.h:127
struct AnimData * adt
Definition: ED_anim_api.h:162
struct ID * id
Definition: ED_anim_api.h:160
bool FrameOnMouseSide(char side, float frame, float cframe)
char transform_convert_frame_side_dir_get(TransInfo *t, float cframe)
conversion and adaptation of different datablocks to a common struct.
static void recalcData_nla(TransInfo *t)
TransConvertTypeInfo TransConvertType_NLA
static void createTransNlaData(bContext *C, TransInfo *t)
struct TransDataNla TransDataNla
static void special_aftertrans_update__nla(bContext *C, TransInfo *UNUSED(t))
@ TD_SELECTED
transform modes used by different operators.
short getAnimEdit_SnapMode(TransInfo *t)
void transform_snap_anim_flush_data(TransInfo *t, TransData *td, eAnimEdit_AutoSnap autosnap, float *r_val_final)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)