Search found 17 matches
- Tue Mar 22, 2022 4:34 am
- Forum: Support and Development
- Topic: problem using stencil function
- Replies: 8
- Views: 3874
Re: problem using stencil function :) Problem resolved
Thank you pgimeno and ReFreezed , your suggestions were very helpful, restoring the canvas solved my problem and my program has started behaving the way I wanted. I understand that, I have wasted your time by not posing .love file along with the .png files. In future post I will certainly do that. I...
- Sat Mar 19, 2022 2:59 pm
- Forum: Support and Development
- Topic: problem using stencil function
- Replies: 8
- Views: 3874
Re: problem using stencil function
push = require 'push' VIRTUAL_WIDTH = 384 VIRTUAL_HEIGHT = 216 WINDOW_HEIGHT = 720 WINDOW_WIDTH = 1280 WALK_SPEED = 40 function love.load() push:setupScreen(VIRTUAL_WIDTH,VIRTUAL_HEIGHT,WINDOW_WIDTH,WINDOW_HEIGHT,{ fullscreen = false, vsync = true, resizable = true }) Ctexture = love.graphics.newIm...
- Fri Mar 18, 2022 5:09 am
- Forum: Support and Development
- Topic: problem using stencil function
- Replies: 8
- Views: 3874
Re: problem using stencil function
Thank you for your reply, I have tried with 'gequal', but it does not work, I thing the problem is that the stencil buffer is not getting synchronized with canvas, is there any other way to set stencil = true other than using setCanvas? or other way to use the stencil?
- Thu Mar 17, 2022 8:29 am
- Forum: Support and Development
- Topic: problem using stencil function
- Replies: 8
- Views: 3874
problem using stencil function
function love.draw() push:start() love.graphics.setCanvas({canvas,stencil=true}) love.graphics.stencil(function() love.graphics.rectangle('fill',VIRTUAL_WIDTH/2 - 40,VIRTUAL_HEIGHT/2 - 10, 30,30) end,'replace',1,false) love.graphics.setStencilTest('less',1) love.graphics.draw(Ctexture,Cquads[1],pos...
- Tue Dec 21, 2021 1:12 pm
- Forum: Support and Development
- Topic: AUTOMATIC QUAD DETECTOR
- Replies: 14
- Views: 7862
- Tue Dec 21, 2021 1:10 pm
- Forum: Support and Development
- Topic: AUTOMATIC QUAD DETECTOR
- Replies: 14
- Views: 7862
Re: AUTOMATIC QUAD DETECTOR
That's very nice. Your code is a god one too. But if you know any function in love2d which can detect an optimum quad from an image file , that would be better, otherwise we have to manually fixed the image file first , then able to perform our operations e.g extracting quads etc. There is nothing ...
- Tue Dec 21, 2021 4:18 am
- Forum: Support and Development
- Topic: AUTOMATIC QUAD DETECTOR
- Replies: 14
- Views: 7862
Re: AUTOMATIC QUAD DETECTOR
can someone please help with love2d function which can detect a quad from RPG sprite automatically. currently I am guessing the quad dimension and generating it with love.graphics.newQuad(). Please help me in this regard. That depends entirely on how you index your quads. Personally, I index them a...
- Mon Dec 20, 2021 2:25 pm
- Forum: Support and Development
- Topic: AUTOMATIC QUAD DETECTOR
- Replies: 14
- Views: 7862
Re: AUTOMATIC QUAD DETECTOR
EngineerSmith , sorry to say , but I am not particularly clear with your explanation. For example, from your first picture how would you know what will be the size of the fist quad so that the figure of first cat fits in exactly.
- Sun Dec 19, 2021 4:52 am
- Forum: Support and Development
- Topic: AUTOMATIC QUAD DETECTOR
- Replies: 14
- Views: 7862
AUTOMATIC QUAD DETECTOR
can someone please help with love2d function which can detect a quad from RPG sprite automatically. currently I am guessing the quad dimension and generating it with love.graphics.newQuad(). Please help me in this regard.
- Fri Dec 17, 2021 4:08 am
- Forum: Support and Development
- Topic: CAN SOMEONE EXPLAIN THE FOLLOWING CODE PLEASE, I AM STUCK HERE
- Replies: 9
- Views: 5589
Re: CAN SOMEONE EXPLAIN THE FOLLOWING CODE PLEASE, I AM STUCK HERE
At last my doubt is clear any of the following lines testTable[temp2.x][temp2.y] = temp1 testTable[temp2.x][temp2.y] = temp3 will work. Thank you for your effort and time. The examples you used to elaborate the topic were excellent and very easy to understand. It will be nice to have conversation li...