Coder Social home page Coder Social logo

Comments (7)

stephenwithav avatar stephenwithav commented on May 20, 2024

25 causes a slightly different issue: http://oi62.tinypic.com/wb82fs.jpg

        dest := image.NewRGBA(image.Rect(0, 25, 297, 210.0))

It appears that dest.Bounds().Min.Y is being subtracted from the bottom of the image.

from draw2d.

stephenwithav avatar stephenwithav commented on May 20, 2024

fmt.Println(dest.Pix[(dest.Bounds().Max.Y-dest.Bounds().Min.Y)*dest.Stride:]) returns all 0s, so the bottom pixels are definitely being clipped.

from draw2d.

stephenwithav avatar stephenwithav commented on May 20, 2024

What is the expected behavior here?

I assumed drawing using a GraphicContext would be like writing to a draw.Image, so this may not be an issue at all.

from draw2d.

llgcode avatar llgcode commented on May 20, 2024

I think the expected behavior is to have an image clipped. The GC coordinate do not change even if the image in parameter is a clipped image.

from draw2d.

stephenwithav avatar stephenwithav commented on May 20, 2024

Thanks, Laurent.

Is draw2d (or draw2dimg) supposed to behave like HTML5's canvas?

from draw2d.

llgcode avatar llgcode commented on May 20, 2024

it's inspired by it and postscript

-- Laurent.

On 19 August 2015 at 11:30, Steven Edwards [email protected] wrote:

Thanks, Laurent.

Is draw2d (or draw2d supposed to behave like HTML5's canvas?


Reply to this email directly or view it on GitHub
#76 (comment).

from draw2d.

stephenwithav avatar stephenwithav commented on May 20, 2024

I'll go ahead and close this, then. I can replicate the functionality I'm looking for another way. :)

from draw2d.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.