Lines Matching refs:get_ref
81 template <typename T> T* get_ref(lua_State* L, int index) { in get_ref() function
457 get_ref<SkCanvas>(L, 1)->clear(0); in lcanvas_clear()
462 get_ref<SkCanvas>(L, 1)->drawColor(lua2color(L, 2)); in lcanvas_drawColor()
467 get_ref<SkCanvas>(L, 1)->drawPaint(*get_obj<SkPaint>(L, 2)); in lcanvas_drawPaint()
475 get_ref<SkCanvas>(L, 1)->drawRect(rect, *paint); in lcanvas_drawRect()
481 get_ref<SkCanvas>(L, 1)->drawOval(*lua2rect(L, 2, &rect), in lcanvas_drawOval()
487 get_ref<SkCanvas>(L, 1)->drawCircle(lua2scalar(L, 2), in lcanvas_drawCircle()
509 SkCanvas* canvas = get_ref<SkCanvas>(L, 1); in lcanvas_drawImage()
510 SkImage* image = get_ref<SkImage>(L, 2); in lcanvas_drawImage()
523 SkCanvas* canvas = get_ref<SkCanvas>(L, 1); in lcanvas_drawImageRect()
524 SkImage* image = get_ref<SkImage>(L, 2); in lcanvas_drawImageRect()
563 get_ref<SkCanvas>(L, 1)->drawPatch(cubics, colors, texs, NULL, *get_obj<SkPaint>(L, 5)); in lcanvas_drawPatch()
568 get_ref<SkCanvas>(L, 1)->drawPath(*get_obj<SkPath>(L, 2), in lcanvas_drawPath()
575 SkCanvas* canvas = get_ref<SkCanvas>(L, 1); in lcanvas_drawPicture()
576 SkPicture* picture = get_ref<SkPicture>(L, 2); in lcanvas_drawPicture()
597 get_ref<SkCanvas>(L, 1)->drawText(text, len, in lcanvas_drawText()
605 const SkTextBlob* blob = get_ref<SkTextBlob>(L, 2); in lcanvas_drawTextBlob()
609 get_ref<SkCanvas>(L, 1)->drawTextBlob(blob, x, y, paint); in lcanvas_drawTextBlob()
614 lua_pushnumber(L, get_ref<SkCanvas>(L, 1)->getSaveCount()); in lcanvas_getSaveCount()
619 SkLua(L).pushMatrix(get_ref<SkCanvas>(L, 1)->getTotalMatrix()); in lcanvas_getTotalMatrix()
624 SkLua(L).pushClipStack(*get_ref<SkCanvas>(L, 1)->getClipStack()); in lcanvas_getClipStack()
630 const SkCanvas* canvas = get_ref<SkCanvas>(L, 1); in lcanvas_getReducedClipStack()
668 lua_pushinteger(L, get_ref<SkCanvas>(L, 1)->save()); in lcanvas_save()
674 lua_pushinteger(L, get_ref<SkCanvas>(L, 1)->saveLayer(NULL, lua2OptionalPaint(L, 2, &paint))); in lcanvas_saveLayer()
679 get_ref<SkCanvas>(L, 1)->restore(); in lcanvas_restore()
686 get_ref<SkCanvas>(L, 1)->scale(sx, sy); in lcanvas_scale()
693 get_ref<SkCanvas>(L, 1)->translate(tx, ty); in lcanvas_translate()
699 get_ref<SkCanvas>(L, 1)->rotate(degrees); in lcanvas_rotate()
704 get_ref<SkCanvas>(L, 1)->concat(*get_obj<SkMatrix>(L, 2)); in lcanvas_concat()
712 SkSurface* surface = get_ref<SkCanvas>(L, 1)->newSurface(info); in lcanvas_newSurface()
722 get_ref<SkCanvas>(L, 1)->unref(); in lcanvas_gc()
764 push_ref(L, get_ref<SkDocument>(L, 1)->beginPage(lua2scalar(L, 2), in ldocument_beginPage()
771 get_ref<SkDocument>(L, 1)->endPage(); in ldocument_endPage()
776 get_ref<SkDocument>(L, 1)->close(); in ldocument_close()
781 get_ref<SkDocument>(L, 1)->unref(); in ldocument_gc()
921 get_obj<SkPaint>(L, 1)->setTypeface(get_ref<SkTypeface>(L, 2)); in lpaint_setTypeface()
1094 paint->setImageFilter(get_ref<SkImageFilter>(L, 2)); in lpaint_setImageFilter()
1110 paint->setShader(get_ref<SkShader>(L, 2)); in lpaint_setShader()
1199 SkShader* shader = get_ref<SkShader>(L, 1); in lshader_isOpaque()
1204 SkShader* shader = get_ref<SkShader>(L, 1); in lshader_asABitmap()
1226 SkShader* shader = get_ref<SkShader>(L, 1); in lshader_asAGradient()
1257 get_ref<SkShader>(L, 1)->unref(); in lshader_gc()
1272 SkPathEffect* pe = get_ref<SkPathEffect>(L, 1); in lpatheffect_asADash()
1288 get_ref<SkPathEffect>(L, 1)->unref(); in lpatheffect_gc()
1301 get_ref<SkImageFilter>(L, 1)->unref(); in lpimagefilter_gc()
1632 lua_pushinteger(L, get_ref<SkImage>(L, 1)->width()); in limage_width()
1637 lua_pushinteger(L, get_ref<SkImage>(L, 1)->height()); in limage_height()
1644 SkAutoTUnref<SkShader> shader(get_ref<SkImage>(L, 1)->newShader(tmode, tmode, localM)); in limage_newShader()
1650 get_ref<SkImage>(L, 1)->unref(); in limage_gc()
1665 lua_pushinteger(L, get_ref<SkSurface>(L, 1)->width()); in lsurface_width()
1670 lua_pushinteger(L, get_ref<SkSurface>(L, 1)->height()); in lsurface_height()
1675 SkCanvas* canvas = get_ref<SkSurface>(L, 1)->getCanvas(); in lsurface_getCanvas()
1690 SkImage* image = get_ref<SkSurface>(L, 1)->newImageSnapshot(); in lsurface_newImageSnapshot()
1703 SkSurface* surface = get_ref<SkSurface>(L, 1)->newSurface(info); in lsurface_newSurface()
1713 get_ref<SkSurface>(L, 1)->unref(); in lsurface_gc()
1783 lua_pushnumber(L, get_ref<SkPicture>(L, 1)->cullRect().width()); in lpicture_width()
1788 lua_pushnumber(L, get_ref<SkPicture>(L, 1)->cullRect().height()); in lpicture_height()
1793 get_ref<SkPicture>(L, 1)->unref(); in lpicture_gc()
1807 SkLua(L).pushRect(get_ref<SkTextBlob>(L, 1)->bounds()); in ltextblob_bounds()
1812 SkSafeUnref(get_ref<SkTextBlob>(L, 1)); in ltextblob_gc()
1826 get_ref<SkTypeface>(L, 1)->getFamilyName(&str); in ltypeface_getFamilyName()
1832 lua_pushnumber(L, (double)get_ref<SkTypeface>(L, 1)->style()); in ltypeface_getStyle()
1837 SkSafeUnref(get_ref<SkTypeface>(L, 1)); in ltypeface_gc()