本文整理汇总了C++中DrawableMap::find方法的典型用法代码示例。如果您正苦于以下问题:C++ DrawableMap::find方法的具体用法?C++ DrawableMap::find怎么用?C++ DrawableMap::find使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DrawableMap
的用法示例。
在下文中一共展示了DrawableMap::find方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: createDrawable
static glws::Drawable *
getDrawable(unsigned long long surface_ptr) {
if (surface_ptr == 0) {
return NULL;
}
DrawableMap::const_iterator it;
it = drawable_map.find(surface_ptr);
if (it == drawable_map.end()) {
// In Fennec we get the egl window surface from Java which isn't
// traced, so just create a drawable if it doesn't exist in here
createDrawable(0, surface_ptr);
it = drawable_map.find(surface_ptr);
assert(it != drawable_map.end());
}
return (it != drawable_map.end()) ? it->second : NULL;
}
示例2: return
static glws::Drawable *
getDrawable(unsigned long drawable_id) {
if (drawable_id == 0) {
return NULL;
}
DrawableMap::const_iterator it;
it = drawable_map.find(drawable_id);
if (it == drawable_map.end()) {
return (drawable_map[drawable_id] = ws->createDrawable(visual));
}
return it->second;
}
示例3: return
static glws::Drawable *
getDrawable(unsigned long long hdc) {
if (hdc == 0) {
return NULL;
}
DrawableMap::const_iterator it;
it = drawable_map.find(hdc);
if (it == drawable_map.end()) {
return (drawable_map[hdc] = glretrace::createDrawable());
}
return it->second;
}
示例4: return
static glws::Drawable *
getDrawable(unsigned long drawable_id, glprofile::Profile profile) {
if (drawable_id == 0) {
return NULL;
}
DrawableMap::const_iterator it;
it = drawable_map.find(drawable_id);
if (it == drawable_map.end()) {
return (drawable_map[drawable_id] = glretrace::createDrawable(profile));
}
return it->second;
}
示例5: return
static glws::Drawable *
getDrawableFromContext(unsigned long long ctx) {
if (ctx == 0) {
return NULL;
}
DrawableMap::const_iterator it;
it = context_drawable_map.find(ctx);
if (it == context_drawable_map.end()) {
return (context_drawable_map[ctx] = glretrace::createDrawable());
}
return it->second;
}
示例6: retrace_eglDestroySurface
static void retrace_eglDestroySurface(trace::Call &call) {
unsigned long long orig_surface = call.arg(1).toUIntPtr();
DrawableMap::iterator it;
it = drawable_map.find(orig_surface);
if (it != drawable_map.end()) {
glretrace::Context *currentContext = glretrace::getCurrentContext();
if (!currentContext || it->second != currentContext->drawable) {
// TODO: reference count
delete it->second;
}
drawable_map.erase(it);
}
}
示例7: return
static glws::Drawable *
getDrawable(unsigned long drawable_id) {
if (drawable_id == 0) {
return NULL;
}
/* XXX: Support multiple drawables. */
drawable_id = 1;
DrawableMap::const_iterator it;
it = drawable_map.find(drawable_id);
if (it == drawable_map.end()) {
return (drawable_map[drawable_id] = glws::createDrawable(visual));
}
return it->second;
}