mirror of
https://github.com/xiaoqidun/ofdgo.git
synced 2026-10-29 08:46:55 +08:00
This commit is contained in:
1 parent
bcb9f98f8b
commit
3959664448
52 files changed
+1864
-407
No files matched your search
@@ -87,7 +87,7 @@ func (img *EncodedImage) At(x, y int) color.Color {
|
||||
// 入参: id 图片资源标识
|
||||
// 返回: image.Image 图片资源, error 读取错误
|
||||
func (r *Renderer) ImageResource(id string) (image.Image, error) {
|
||||
path, ok := r.Reader.ResMap[id]
|
||||
path, ok := resourceValue(r.Reader.ResMap, id)
|
||||
if !ok {
|
||||
return nil, fmt.Errorf("image resource %q not found", id)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user