Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/space_graph/graph_draw.c
| Show First 20 Lines • Show All 1,103 Lines • ▼ Show 20 Lines | for (ale = anim_data.first, i = 0; ale; ale = ale->next, i++) { | ||||
| ANIM_channel_draw(ac, ale, yminc, ymaxc); | ANIM_channel_draw(ac, ale, yminc, ymaxc); | ||||
| } | } | ||||
| /* adjust y-position for next one */ | /* adjust y-position for next one */ | ||||
| y -= ACHANNEL_STEP; | y -= ACHANNEL_STEP; | ||||
| } | } | ||||
| } | } | ||||
| { /* second pass: widgets */ | { /* second pass: widgets */ | ||||
| uiBlock *block = uiBeginBlock(C, ar, __func__, UI_EMBOSS); | uiBlock *block = UI_block_begin(C, ar, __func__, UI_EMBOSS); | ||||
| size_t channel_index = 0; | size_t channel_index = 0; | ||||
| y = (float)ACHANNEL_FIRST; | y = (float)ACHANNEL_FIRST; | ||||
| /* set blending again, as may not be set in previous step */ | /* set blending again, as may not be set in previous step */ | ||||
| glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); | glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); | ||||
| glEnable(GL_BLEND); | glEnable(GL_BLEND); | ||||
| Show All 9 Lines | for (ale = anim_data.first, i = 0; ale; ale = ale->next, i++) { | ||||
| ANIM_channel_draw_widgets(C, ac, ale, block, yminc, ymaxc, channel_index); | ANIM_channel_draw_widgets(C, ac, ale, block, yminc, ymaxc, channel_index); | ||||
| } | } | ||||
| /* adjust y-position for next one */ | /* adjust y-position for next one */ | ||||
| y -= ACHANNEL_STEP; | y -= ACHANNEL_STEP; | ||||
| channel_index++; | channel_index++; | ||||
| } | } | ||||
| uiEndBlock(C, block); | UI_block_end(C, block); | ||||
| uiDrawBlock(C, block); | UI_block_draw(C, block); | ||||
| glDisable(GL_BLEND); | glDisable(GL_BLEND); | ||||
| } | } | ||||
| /* free tempolary channels */ | /* free tempolary channels */ | ||||
| ANIM_animdata_freelist(&anim_data); | ANIM_animdata_freelist(&anim_data); | ||||
| } | } | ||||