Blender  V2.93
transform_convert_nla.c
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or
3  * modify it under the terms of the GNU General Public License
4  * as published by the Free Software Foundation; either version 2
5  * of the License, or (at your option) any later version.
6  *
7  * This program is distributed in the hope that it will be useful,
8  * but WITHOUT ANY WARRANTY; without even the implied warranty of
9  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  * GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License
13  * along with this program; if not, write to the Free Software Foundation,
14  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15  *
16  * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
17  * All rights reserved.
18  */
19 
24 #include "DNA_anim_types.h"
25 #include "DNA_space_types.h"
26 
27 #include "MEM_guardedalloc.h"
28 
29 #include "BLI_listbase.h"
30 #include "BLI_math.h"
31 
32 #include "BKE_context.h"
33 #include "BKE_nla.h"
34 
35 #include "ED_anim_api.h"
36 #include "ED_markers.h"
37 
38 #include "WM_api.h"
39 #include "WM_types.h"
40 
41 #include "RNA_access.h"
42 
43 #include "transform.h"
44 #include "transform_convert.h"
45 
47 typedef struct TransDataNla {
49  ID *id;
50 
52  struct NlaTrack *oldTrack;
54  struct NlaTrack *nlt;
55 
57  struct NlaStrip *strip;
58 
59  /* dummy values for transform to write in - must have 3 elements... */
61  float h1[3];
63  float h2[3];
64 
68  int handle;
70 
71 /* -------------------------------------------------------------------- */
76 {
77  Scene *scene = t->scene;
78  SpaceNla *snla = NULL;
79  TransData *td = NULL;
80  TransDataNla *tdn = NULL;
81 
82  bAnimContext ac;
83  ListBase anim_data = {NULL, NULL};
84  bAnimListElem *ale;
85  int filter;
86 
87  int count = 0;
88 
90 
91  /* determine what type of data we are operating on */
92  if (ANIM_animdata_get_context(C, &ac) == 0) {
93  return;
94  }
95  snla = (SpaceNla *)ac.sl;
96 
97  /* filter data */
99  ANIM_animdata_filter(&ac, &anim_data, filter, ac.data, ac.datatype);
100 
101  /* which side of the current frame should be allowed */
102  if (t->mode == TFM_TIME_EXTEND) {
103  t->frame_side = transform_convert_frame_side_dir_get(t, (float)CFRA);
104  }
105  else {
106  /* normal transform - both sides of current frame are considered */
107  t->frame_side = 'B';
108  }
109 
110  /* loop 1: count how many strips are selected (consider each strip as 2 points) */
111  for (ale = anim_data.first; ale; ale = ale->next) {
112  NlaTrack *nlt = (NlaTrack *)ale->data;
113  NlaStrip *strip;
114 
115  /* make some meta-strips for chains of selected strips */
117 
118  /* only consider selected strips */
119  for (strip = nlt->strips.first; strip; strip = strip->next) {
120  /* TODO: we can make strips have handles later on. */
121  /* transition strips can't get directly transformed */
122  if (strip->type != NLASTRIP_TYPE_TRANSITION) {
123  if (strip->flag & NLASTRIP_FLAG_SELECT) {
124  if (FrameOnMouseSide(t->frame_side, strip->start, (float)CFRA)) {
125  count++;
126  }
127  if (FrameOnMouseSide(t->frame_side, strip->end, (float)CFRA)) {
128  count++;
129  }
130  }
131  }
132  }
133  }
134 
135  /* stop if trying to build list if nothing selected */
136  if (count == 0) {
137  /* clear temp metas that may have been created but aren't needed now
138  * because they fell on the wrong side of CFRA
139  */
140  for (ale = anim_data.first; ale; ale = ale->next) {
141  NlaTrack *nlt = (NlaTrack *)ale->data;
142  BKE_nlastrips_clear_metas(&nlt->strips, 0, 1);
143  }
144 
145  /* cleanup temp list */
146  ANIM_animdata_freelist(&anim_data);
147  return;
148  }
149 
150  /* allocate memory for data */
151  tc->data_len = count;
152 
153  tc->data = MEM_callocN(tc->data_len * sizeof(TransData), "TransData(NLA Editor)");
154  td = tc->data;
155  tc->custom.type.data = tdn = MEM_callocN(tc->data_len * sizeof(TransDataNla),
156  "TransDataNla (NLA Editor)");
157  tc->custom.type.use_free = true;
158 
159  /* loop 2: build transdata array */
160  for (ale = anim_data.first; ale; ale = ale->next) {
161  /* only if a real NLA-track */
162  if (ale->type == ANIMTYPE_NLATRACK) {
163  AnimData *adt = ale->adt;
164  NlaTrack *nlt = (NlaTrack *)ale->data;
165  NlaStrip *strip;
166 
167  /* only consider selected strips */
168  for (strip = nlt->strips.first; strip; strip = strip->next) {
169  /* TODO: we can make strips have handles later on. */
170  /* transition strips can't get directly transformed */
171  if (strip->type != NLASTRIP_TYPE_TRANSITION) {
172  if (strip->flag & NLASTRIP_FLAG_SELECT) {
173  /* our transform data is constructed as follows:
174  * - only the handles on the right side of the current-frame get included
175  * - td structs are transform-elements operated on by the transform system
176  * and represent a single handle. The storage/pointer used (val or loc) depends on
177  * whether we're scaling or transforming. Ultimately though, the handles
178  * the td writes to will simply be a dummy in tdn
179  * - for each strip being transformed, a single tdn struct is used, so in some
180  * cases, there will need to be 1 of these tdn elements in the array skipped...
181  */
182  float center[3], yval;
183 
184  /* firstly, init tdn settings */
185  tdn->id = ale->id;
186  tdn->oldTrack = tdn->nlt = nlt;
187  tdn->strip = strip;
188  tdn->trackIndex = BLI_findindex(&adt->nla_tracks, nlt);
189 
190  yval = (float)(tdn->trackIndex * NLACHANNEL_STEP(snla));
191 
192  tdn->h1[0] = strip->start;
193  tdn->h1[1] = yval;
194  tdn->h2[0] = strip->end;
195  tdn->h2[1] = yval;
196 
197  center[0] = (float)CFRA;
198  center[1] = yval;
199  center[2] = 0.0f;
200 
201  /* set td's based on which handles are applicable */
202  if (FrameOnMouseSide(t->frame_side, strip->start, (float)CFRA)) {
203  /* just set tdn to assume that it only has one handle for now */
204  tdn->handle = -1;
205 
206  /* now, link the transform data up to this data */
207  if (ELEM(t->mode, TFM_TRANSLATION, TFM_TIME_EXTEND)) {
208  td->loc = tdn->h1;
209  copy_v3_v3(td->iloc, tdn->h1);
210 
211  /* store all the other gunk that is required by transform */
212  copy_v3_v3(td->center, center);
213  memset(td->axismtx, 0, sizeof(td->axismtx));
214  td->axismtx[2][2] = 1.0f;
215 
216  td->ext = NULL;
217  td->val = NULL;
218 
219  td->flag |= TD_SELECTED;
220  td->dist = 0.0f;
221 
222  unit_m3(td->mtx);
223  unit_m3(td->smtx);
224  }
225  else {
226  /* time scaling only needs single value */
227  td->val = &tdn->h1[0];
228  td->ival = tdn->h1[0];
229  }
230 
231  td->extra = tdn;
232  td++;
233  }
234  if (FrameOnMouseSide(t->frame_side, strip->end, (float)CFRA)) {
235  /* if tdn is already holding the start handle,
236  * then we're doing both, otherwise, only end */
237  tdn->handle = (tdn->handle) ? 2 : 1;
238 
239  /* now, link the transform data up to this data */
240  if (ELEM(t->mode, TFM_TRANSLATION, TFM_TIME_EXTEND)) {
241  td->loc = tdn->h2;
242  copy_v3_v3(td->iloc, tdn->h2);
243 
244  /* store all the other gunk that is required by transform */
245  copy_v3_v3(td->center, center);
246  memset(td->axismtx, 0, sizeof(td->axismtx));
247  td->axismtx[2][2] = 1.0f;
248 
249  td->ext = NULL;
250  td->val = NULL;
251 
252  td->flag |= TD_SELECTED;
253  td->dist = 0.0f;
254 
255  unit_m3(td->mtx);
256  unit_m3(td->smtx);
257  }
258  else {
259  /* time scaling only needs single value */
260  td->val = &tdn->h2[0];
261  td->ival = tdn->h2[0];
262  }
263 
264  td->extra = tdn;
265  td++;
266  }
267 
268  /* If both handles were used, skip the next tdn (i.e. leave it blank)
269  * since the counting code is dumb.
270  * Otherwise, just advance to the next one.
271  */
272  if (tdn->handle == 2) {
273  tdn += 2;
274  }
275  else {
276  tdn++;
277  }
278  }
279  }
280  }
281  }
282  }
283 
284  /* cleanup temp list */
285  ANIM_animdata_freelist(&anim_data);
286 }
287 
288 /* helper for recalcData() - for NLA Editor transforms */
290 {
291  SpaceNla *snla = (SpaceNla *)t->area->spacedata.first;
292  Scene *scene = t->scene;
293  double secf = FPS;
294  int i;
295 
297  TransDataNla *tdn = tc->custom.type.data;
298 
299  /* For each strip we've got, perform some additional validation of the values
300  * that got set before using RNA to set the value (which does some special
301  * operations when setting these values to make sure that everything works ok).
302  */
303  for (i = 0; i < tc->data_len; i++, tdn++) {
304  NlaStrip *strip = tdn->strip;
305  PointerRNA strip_ptr;
306  short iter;
307  int delta_y1, delta_y2;
308 
309  /* if this tdn has no handles, that means it is just a dummy that should be skipped */
310  if (tdn->handle == 0) {
311  continue;
312  }
313 
314  /* set refresh tags for objects using this animation,
315  * BUT only if realtime updates are enabled
316  */
317  if ((snla->flag & SNLA_NOREALTIMEUPDATES) == 0) {
318  ANIM_id_update(CTX_data_main(t->context), tdn->id);
319  }
320 
321  /* if canceling transform, just write the values without validating, then move on */
322  if (t->state == TRANS_CANCEL) {
323  /* clear the values by directly overwriting the originals, but also need to restore
324  * endpoints of neighboring transition-strips
325  */
326 
327  /* start */
328  strip->start = tdn->h1[0];
329 
330  if ((strip->prev) && (strip->prev->type == NLASTRIP_TYPE_TRANSITION)) {
331  strip->prev->end = tdn->h1[0];
332  }
333 
334  /* end */
335  strip->end = tdn->h2[0];
336 
337  if ((strip->next) && (strip->next->type == NLASTRIP_TYPE_TRANSITION)) {
338  strip->next->start = tdn->h2[0];
339  }
340 
341  /* flush transforms to child strips (since this should be a meta) */
343 
344  /* restore to original track (if needed) */
345  if (tdn->oldTrack != tdn->nlt) {
346  /* Just append to end of list for now,
347  * since strips get sorted in special_aftertrans_update(). */
348  BLI_remlink(&tdn->nlt->strips, strip);
349  BLI_addtail(&tdn->oldTrack->strips, strip);
350  }
351 
352  continue;
353  }
354 
355  /* firstly, check if the proposed transform locations would overlap with any neighboring strips
356  * (barring transitions) which are absolute barriers since they are not being moved
357  *
358  * this is done as a iterative procedure (done 5 times max for now)
359  */
360  NlaStrip *prev = strip->prev;
361  while (prev != NULL && (prev->type & NLASTRIP_TYPE_TRANSITION)) {
362  prev = prev->prev;
363  }
364 
365  NlaStrip *next = strip->next;
366  while (next != NULL && (next->type & NLASTRIP_TYPE_TRANSITION)) {
367  next = next->next;
368  }
369 
370  for (iter = 0; iter < 5; iter++) {
371 
372  const bool pExceeded = (prev != NULL) && (tdn->h1[0] < prev->end);
373  const bool nExceeded = (next != NULL) && (tdn->h2[0] > next->start);
374 
375  if ((pExceeded && nExceeded) || (iter == 4)) {
376  /* both endpoints exceeded (or iteration ping-pong'd meaning that we need a
377  * compromise)
378  * - Simply crop strip to fit within the bounds of the strips bounding it
379  * - If there were no neighbors, clear the transforms
380  * (make it default to the strip's current values).
381  */
382  if (prev && next) {
383  tdn->h1[0] = prev->end;
384  tdn->h2[0] = next->start;
385  }
386  else {
387  tdn->h1[0] = strip->start;
388  tdn->h2[0] = strip->end;
389  }
390  }
391  else if (nExceeded) {
392  /* move backwards */
393  float offset = tdn->h2[0] - next->start;
394 
395  tdn->h1[0] -= offset;
396  tdn->h2[0] -= offset;
397  }
398  else if (pExceeded) {
399  /* more forwards */
400  float offset = prev->end - tdn->h1[0];
401 
402  tdn->h1[0] += offset;
403  tdn->h2[0] += offset;
404  }
405  else { /* all is fine and well */
406  break;
407  }
408  }
409 
410  /* handle auto-snapping
411  * NOTE: only do this when transform is still running, or we can't restore
412  */
413  if (t->state != TRANS_CANCEL) {
414  switch (snla->autosnap) {
415  case SACTSNAP_FRAME: /* snap to nearest frame */
416  case SACTSNAP_STEP: /* frame step - this is basically the same,
417  * since we don't have any remapping going on */
418  {
419  tdn->h1[0] = floorf(tdn->h1[0] + 0.5f);
420  tdn->h2[0] = floorf(tdn->h2[0] + 0.5f);
421  break;
422  }
423 
424  case SACTSNAP_SECOND: /* snap to nearest second */
425  case SACTSNAP_TSTEP: /* second step - this is basically the same,
426  * since we don't have any remapping going on */
427  {
428  /* This case behaves differently from the rest, since lengths of strips
429  * may not be multiples of a second. If we just naively resize adjust
430  * the handles, things may not work correctly. Instead, we only snap
431  * the first handle, and move the other to fit.
432  *
433  * FIXME: we do run into problems here when user attempts to negatively
434  * scale the strip, as it then just compresses down and refuses
435  * to expand out the other end.
436  */
437  float h1_new = (float)(floor(((double)tdn->h1[0] / secf) + 0.5) * secf);
438  float delta = h1_new - tdn->h1[0];
439 
440  tdn->h1[0] = h1_new;
441  tdn->h2[0] += delta;
442  break;
443  }
444 
445  case SACTSNAP_MARKER: /* snap to nearest marker */
446  {
447  tdn->h1[0] = (float)ED_markers_find_nearest_marker_time(&t->scene->markers, tdn->h1[0]);
448  tdn->h2[0] = (float)ED_markers_find_nearest_marker_time(&t->scene->markers, tdn->h2[0]);
449  break;
450  }
451  }
452  }
453 
454  /* Use RNA to write the values to ensure that constraints on these are obeyed
455  * (e.g. for transition strips, the values are taken from the neighbors)
456  *
457  * NOTE: we write these twice to avoid truncation errors which can arise when
458  * moving the strips a large distance using numeric input T33852.
459  */
460  RNA_pointer_create(NULL, &RNA_NlaStrip, strip, &strip_ptr);
461 
462  RNA_float_set(&strip_ptr, "frame_start", tdn->h1[0]);
463  RNA_float_set(&strip_ptr, "frame_end", tdn->h2[0]);
464 
465  RNA_float_set(&strip_ptr, "frame_start", tdn->h1[0]);
466  RNA_float_set(&strip_ptr, "frame_end", tdn->h2[0]);
467 
468  /* flush transforms to child strips (since this should be a meta) */
470 
471  /* Now, check if we need to try and move track:
472  * - we need to calculate both,
473  * as only one may have been altered by transform if only 1 handle moved.
474  */
475  /* In LibOverride case, we cannot move strips across tracks that come from the linked data. */
476  const bool is_liboverride = ID_IS_OVERRIDE_LIBRARY(tdn->id);
478  continue;
479  }
480 
481  delta_y1 = ((int)tdn->h1[1] / NLACHANNEL_STEP(snla) - tdn->trackIndex);
482  delta_y2 = ((int)tdn->h2[1] / NLACHANNEL_STEP(snla) - tdn->trackIndex);
483 
484  if (delta_y1 || delta_y2) {
485  NlaTrack *track;
486  int delta = (delta_y2) ? delta_y2 : delta_y1;
487  int n;
488 
489  /* Move in the requested direction,
490  * checking at each layer if there's space for strip to pass through,
491  * stopping on the last track available or that we're able to fit in.
492  */
493  if (delta > 0) {
494  for (track = tdn->nlt->next, n = 0; (track) && (n < delta); track = track->next, n++) {
495  /* check if space in this track for the strip */
496  if (BKE_nlatrack_has_space(track, strip->start, strip->end) &&
498  /* move strip to this track */
499  BLI_remlink(&tdn->nlt->strips, strip);
500  BKE_nlatrack_add_strip(track, strip, is_liboverride);
501 
502  tdn->nlt = track;
503  tdn->trackIndex++;
504  }
505  else { /* can't move any further */
506  break;
507  }
508  }
509  }
510  else {
511  /* make delta 'positive' before using it, since we now know to go backwards */
512  delta = -delta;
513 
514  for (track = tdn->nlt->prev, n = 0; (track) && (n < delta); track = track->prev, n++) {
515  /* check if space in this track for the strip */
516  if (BKE_nlatrack_has_space(track, strip->start, strip->end) &&
518  /* move strip to this track */
519  BLI_remlink(&tdn->nlt->strips, strip);
520  BKE_nlatrack_add_strip(track, strip, is_liboverride);
521 
522  tdn->nlt = track;
523  tdn->trackIndex--;
524  }
525  else { /* can't move any further */
526  break;
527  }
528  }
529  }
530  }
531  }
532 }
533 
536 /* -------------------------------------------------------------------- */
541 {
542  bAnimContext ac;
543 
544  /* initialize relevant anim-context 'context' data */
545  if (ANIM_animdata_get_context(C, &ac) == 0) {
546  return;
547  }
548 
549  if (ac.datatype) {
550  ListBase anim_data = {NULL, NULL};
551  bAnimListElem *ale;
553 
554  /* get channels to work on */
555  ANIM_animdata_filter(&ac, &anim_data, filter, ac.data, ac.datatype);
556 
557  for (ale = anim_data.first; ale; ale = ale->next) {
558  NlaTrack *nlt = (NlaTrack *)ale->data;
559 
560  /* make sure strips are in order again */
562 
563  /* remove the temp metas */
564  BKE_nlastrips_clear_metas(&nlt->strips, 0, 1);
565  }
566 
567  /* General refresh for the outliner because the following might have happened:
568  * - strips moved between tracks
569  * - strips swapped order
570  * - duplicate-move moves to different track. */
572 
573  /* free temp memory */
574  ANIM_animdata_freelist(&anim_data);
575 
576  /* Perform after-transform validation. */
578  }
579 }
580 
typedef float(TangentPoint)[2]
struct Main * CTX_data_main(const bContext *C)
Definition: context.c:1018
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:1135
bool BKE_nlatrack_has_space(struct NlaTrack *nlt, float start, float end)
Definition: nla.c:1112
void BKE_nlastrips_clear_metas(ListBase *strips, bool only_sel, bool only_temp)
Definition: nla.c:833
void BKE_nlameta_flush_transforms(struct NlaStrip *mstrip)
Definition: nla.c:912
bool BKE_nlatrack_add_strip(struct NlaTrack *nlt, struct NlaStrip *strip, const bool is_liboverride)
Definition: nla.c:1149
void BKE_nlastrips_make_metas(ListBase *strips, bool is_temp)
Definition: nla.c:753
void BLI_addtail(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
Definition: listbase.c:110
void BLI_remlink(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
Definition: listbase.c:133
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:58
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:445
@ SACTSNAP_SECOND
@ SACTSNAP_TSTEP
@ SACTSNAP_MARKER
@ SACTSNAP_STEP
@ SACTSNAP_FRAME
@ NLASTRIP_FLAG_SELECT
@ NLASTRIP_TYPE_TRANSITION
#define CFRA
#define FPS
@ SNLA_NOREALTIMEUPDATES
@ ANIMTYPE_NLATRACK
Definition: ED_anim_api.h:246
void ED_nla_postop_refresh(bAnimContext *ac)
Definition: nla_edit.c:75
#define NLACHANNEL_STEP(snla)
Definition: ED_anim_api.h:451
@ ANIMFILTER_FOREDIT
Definition: ED_anim_api.h:315
@ ANIMFILTER_DATA_VISIBLE
Definition: ED_anim_api.h:295
@ ANIMFILTER_LIST_VISIBLE
Definition: ED_anim_api.h:298
@ TFM_TIME_EXTEND
Definition: ED_transform.h:68
@ TFM_TRANSLATION
Definition: ED_transform.h:46
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.
StructRNA RNA_NlaStrip
#define C
Definition: RandGen.cpp:39
#define NC_ANIMATION
Definition: WM_types.h:289
#define NA_ADDED
Definition: WM_types.h:464
#define ND_NLA
Definition: WM_types.h:397
void ANIM_animdata_freelist(ListBase *anim_data)
Definition: anim_deps.c:425
void ANIM_id_update(Main *bmain, ID *id)
Definition: anim_deps.c:119
bool ANIM_animdata_get_context(const bContext *C, bAnimContext *ac)
Definition: anim_filter.c:405
size_t ANIM_animdata_filter(bAnimContext *ac, ListBase *anim_data, eAnimFilter_Flags filter_mode, void *data, eAnimCont_Types datatype)
Definition: anim_filter.c:3442
int ED_markers_find_nearest_marker_time(ListBase *markers, float x)
Definition: anim_markers.c:193
Scene scene
DO_INLINE void filter(lfVector *V, fmatrix3x3 *S)
int count
#define floorf(x)
void *(* MEM_callocN)(size_t len, const char *str)
Definition: mallocn.c:45
static ulong * next
void RNA_pointer_create(ID *id, StructRNA *type, void *data, PointerRNA *r_ptr)
Definition: rna_access.c:146
void RNA_float_set(PointerRNA *ptr, const char *name, float value)
Definition: rna_access.c:6366
ListBase nla_tracks
Definition: DNA_ID.h:273
void * first
Definition: DNA_listBase.h:47
struct NlaStrip * next
struct NlaStrip * prev
ListBase strips
struct NlaTrack * next
struct NlaTrack * prev
short autosnap
TransCustomData type
Definition: transform.h:428
unsigned int use_free
Definition: transform.h:408
TransCustomDataContainer custom
Definition: transform.h:501
TransData * data
Definition: transform.h:448
struct NlaTrack * oldTrack
struct NlaTrack * nlt
struct NlaStrip * strip
float smtx[3][3]
float axismtx[3][3]
float mtx[3][3]
TransDataExtension * ext
float * val
short datatype
Definition: ED_anim_api.h:75
void * data
Definition: ED_anim_api.h:73
struct SpaceLink * sl
Definition: ED_anim_api.h:87
struct bAnimListElem * next
Definition: ED_anim_api.h:135
struct AnimData * adt
Definition: ED_anim_api.h:170
struct ID * id
Definition: ED_anim_api.h:168
#define TRANS_DATA_CONTAINER_FIRST_SINGLE(t)
Definition: transform.h:810
@ TRANS_CANCEL
Definition: transform.h:193
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.
void recalcData_nla(TransInfo *t)
struct TransDataNla TransDataNla
void special_aftertrans_update__nla(bContext *C, TransInfo *UNUSED(t))
void createTransNlaData(bContext *C, TransInfo *t)
@ TD_SELECTED
ccl_device_inline float2 floor(const float2 &a)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)