Changeset View
Changeset View
Standalone View
Standalone View
source/blender/compositor/operations/COM_KeyingScreenOperation.cc
| Show First 20 Lines • Show All 297 Lines • ▼ Show 20 Lines | void KeyingScreenOperation::deinitializeTileData(rcti * /*rect*/, void *data) | ||||
| if (tile_data->triangles) { | if (tile_data->triangles) { | ||||
| MEM_freeN(tile_data->triangles); | MEM_freeN(tile_data->triangles); | ||||
| } | } | ||||
| MEM_freeN(tile_data); | MEM_freeN(tile_data); | ||||
| } | } | ||||
| void KeyingScreenOperation::determineResolution(unsigned int resolution[2], | void KeyingScreenOperation::determine_canvas(const rcti &preferred_area, rcti &r_area) | ||||
| unsigned int /*preferredResolution*/[2]) | |||||
| { | { | ||||
| resolution[0] = 0; | r_area = COM_AREA_NONE; | ||||
| resolution[1] = 0; | |||||
| if (this->m_movieClip) { | if (this->m_movieClip) { | ||||
| MovieClipUser user = {0}; | MovieClipUser user = {0}; | ||||
| int width, height; | int width, height; | ||||
| int clip_frame = BKE_movieclip_remap_scene_to_clip_frame(this->m_movieClip, | int clip_frame = BKE_movieclip_remap_scene_to_clip_frame(this->m_movieClip, | ||||
| this->m_framenumber); | this->m_framenumber); | ||||
| BKE_movieclip_user_set_frame(&user, clip_frame); | BKE_movieclip_user_set_frame(&user, clip_frame); | ||||
| BKE_movieclip_get_size(this->m_movieClip, &user, &width, &height); | BKE_movieclip_get_size(this->m_movieClip, &user, &width, &height); | ||||
| r_area = preferred_area; | |||||
| resolution[0] = width; | r_area.xmax = r_area.xmin + width; | ||||
| resolution[1] = height; | r_area.ymax = r_area.ymin + height; | ||||
| } | } | ||||
| } | } | ||||
| void KeyingScreenOperation::executePixel(float output[4], int x, int y, void *data) | void KeyingScreenOperation::executePixel(float output[4], int x, int y, void *data) | ||||
| { | { | ||||
| output[0] = 0.0f; | output[0] = 0.0f; | ||||
| output[1] = 0.0f; | output[1] = 0.0f; | ||||
| output[2] = 0.0f; | output[2] = 0.0f; | ||||
| ▲ Show 20 Lines • Show All 87 Lines • Show Last 20 Lines | |||||