분류, 패키지 및 저장소 검색

image_painter 표지
패키지 상세v0.7.1

image_painter

이미지 위에 그림을 그리기 위한 플러터 패키지입니다. 색상, 선 두께, 다양한 페인트 모드 및 이미지 내보내기를 지원합니다.

AndroidiOSmacOSWindowsLinux
30일 다운로드
7.1천
좋아요
214
Pub 점수
150

패키지 설치

flutter pub add image_painter

패키지 개요

공개 정보를 바탕으로 생성한 선택 가이드입니다.

사용자가 사용자 정의 가능한 색상, 선 두께 및 페인트 모드로 이미지 위에 그릴 수 있도록 해주는 플러터 패키지입니다. 이미지 위에서 직접 상호작용하는 그림을 지원하며 결과를 내보낼 수 있습니다. 이미지 주석, 스케치 또는 플러터 앱 내에서 창의적인 편집이 필요한 애플리케이션에 적합합니다. 이 패키지는 크로스플랫폼으로, 안드로이드, iOS, macOS, Windows 및 리눅스에서 원활하게 작동합니다.

사용 사례

  • 이미지 주석
  • 크리에이티브 스케치
  • 디지털 서명 캡처
  • 사진 편집 도구
  • 인터랙티브 그림 앱

주요 기능

  • 사용자 지정 페인트 색상
  • 조정 가능한 스트로크 폭
  • 다중 페인트 모드
  • 그린 이미지 내보내기
  • 크로스 플랫폼 지원

적합한 대상

  • 그림 기능이 필요한 앱 개발자
  • 교육 또는 디자인 앱
  • 사용자 생성 콘텐츠 플랫폼
  • 모바일 및 데스크톱 멀티미디어 앱

고려 사항

  • 이미지 로딩 및 렌더링 처리가 필요합니다
  • 큰 이미지에서는 성능이 달라질 수 있습니다
  • 기본 페인팅 작업에 제한됨
  • 내장된 되돌리기/다시실행 기능 없음
  • 외부 이미지 소스 관리에 의존

원본 README

연결된 소스 저장소의 README 원문 스냅샷입니다. 최신 내용은 저장소에서 확인하세요.

image_painter

pub package style: effective dart Platform Badge License: MIT

A flutter implementation of painting over image.

Overview

demo!

Features

  • Seven available paint modes. Line, Box/Rectangle, Circle, Freestyle/Signature, Dotted Line, Arrow and Text.
  • Four constructors for adding image from Network Url, Asset Image, Image from file and from memory.
  • Export image as memory bytes which can be converted to image. Implementation provided on example
  • Ability to undo and clear drawings.
  • Built in control bar.

[Note] Tested and working only on flutter stable channel. Please make sure you are on stable channel of flutter before using the package.

Getting started

In the pubspec.yaml of your flutter project, add the following dependency:

dependencies:
  ...
  image_painter: latest

In your library add the following import:

import 'package:image_painter/image_painter.dart';

For help getting started with Flutter, view the online documentation.

Using the library

Check out the example

Basic usage of the libary:

  • ImagePainter.network: Painting over image from network url.
/// Initialize `ImagePainterController`. 
final imagePainterController = ImagePainterController();

/// Provide controller to the painter.
ImagePainter.network("https://sample_image.png",
                  controller: imagePainterController,scalable: true),

///Export the image:
Uint8List byteArray = await imagePainterController.exportImage();

/// Create a file or create a File instance of existing file. 
File imgFile =  File('directoryPath/fileName.png');

/// Now you use `Uint8List` data and write it into the file.
imgFile.writeAsBytesSync(image);

For more thorough implementation guide, check the example.

Issues and Support.

For any issues or support please visit the Issues.

카테고리

소스 저장소

이 패키지를 사용하는 프로젝트

아직 데이터가 없습니다.