Alright, I know full well that löve only supports rectangular scissor buffers. What I'm wondering if there's any other way I could get an irregular viewport-like shape drawn to the screen. Could I, for example, draw to a framebuffer and then create an arbitrary shape that could clear part of that buffer and then flip that onto the screen buffer? Somehow, I get the feeling this is going to require me making a request on the issue tracker. Just wanted to check here first. Maybe I'm missing something.
I'm trying to emulate this kind of awesometastic splitscreening.
Arbitrary scissor shapes?
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Arbitrary scissor shapes?
mapPixel could work, but that would be horribly, horribly slow.
Help us help you: attach a .love.
- genericdave
- Citizen
- Posts: 53
- Joined: Tue Dec 15, 2009 9:08 am
Re: Arbitrary scissor shapes?
Yeah, that's basically what has me stumped here. Accessing image data directly is expensive. I don't think a reasonable implementation of this is possible with löve currently. I'm a bit surprised to find that Opengl restricts its scissors and viewports to rectangles as well. Looks like I would need some sort of clipping mask in order to achieve this.Robin wrote:that would be horribly, horribly slow.
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Arbitrary scissor shapes?
Think so, yeah. But it seems so unlovely to me.genericdave wrote:Looks like I would need some sort of clipping mask in order to achieve this.
Help us help you: attach a .love.
- genericdave
- Citizen
- Posts: 53
- Joined: Tue Dec 15, 2009 9:08 am
Re: Arbitrary scissor shapes?
Clipping masks in general are unlovely? Or are you talking about specifically as a solution to this?
- genericdave
- Citizen
- Posts: 53
- Joined: Tue Dec 15, 2009 9:08 am
Re: Arbitrary scissor shapes?
Hmm, looks like löve might eventually be able to do this with simple blending modes. Like this. I could be dead wrong, however.
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Denver, CO
- Contact:
Re: Arbitrary scissor shapes?
Does love.graphics.rotate not affect scissor?.
UPDATE: My gosh, it doesn't!
UPDATE: My gosh, it doesn't!
Re: Arbitrary scissor shapes?
How about ImageData:paste()? You could only split it horizontally or vertically, but still should be faster.Robin wrote:mapPixel could work, but that would be horribly, horribly slow.
My lovely code lives at GitHub: http://github.com/miko/Love2d-samples
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Arbitrary scissor shapes?
How would that be an improvement over using scissor?
Help us help you: attach a .love.
Who is online
Users browsing this forum: 1Minus2P1Stringer2 and 3 guests