The Love3D R1 Library [V 0.4.2]
- substitute541
- Party member
- Posts: 484
- Joined: Fri Aug 24, 2012 9:04 am
- Location: Southern Leyte, Visayas, Philippines
- Contact:
Re: [NEW] The Love3D Project (NEW PROJECTS)
Woo. Good thing there's love.graphics.polygon. If I had time I could (somehow) make a pyramid. And if I had LOTS of time, I could make a cylinder(that uses math functions, not hardcoded numbers... Whew, this is kinda hard...)
Currently designing themes for WordPress.
Sometimes lurks around the forum.
Sometimes lurks around the forum.
- substitute541
- Party member
- Posts: 484
- Joined: Fri Aug 24, 2012 9:04 am
- Location: Southern Leyte, Visayas, Philippines
- Contact:
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
New Perspective.lua! Haven't tested it though, so please, TEST IT . Found any bugs? Report to me by replying in this thread.
Currently designing themes for WordPress.
Sometimes lurks around the forum.
Sometimes lurks around the forum.
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
About perspective9, calculating the average Z position of every face's extremes (vertices? vertexes?), sorting the faces checking averageZ and then drawing them should do the trick
P.S: Use conf.lua and love.conf to set width and height
I know nothing about this topic. This is just a stupid idea that actually works.
P.S: Use conf.lua and love.conf to set width and height
I know nothing about this topic. This is just a stupid idea that actually works.
- Attachments
-
- perspectiveNix.love
- (1.41 KiB) Downloaded 165 times
Last edited by Nixola on Mon Sep 24, 2012 9:30 pm, edited 1 time in total.
lf = love.filesystem
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
You should consider a framework, instead of a hard-to-use perspective function. Such as a camera occupying 3D space and objects occupying 3D space. Then you can move the camera to view objects from a different angle. Something like this:
3D.camera.setMatrix(positionX, positionY, positionZ, lookatx, lookaty, lookatz, roll, fov)
Where 3D is the parent library, camera is the REQUIRED sublib (because without camera you're at 0, 0, 0 looking at 0,0,0 and can't control it.)
3D.camera.setMatrix(positionX, positionY, positionZ, lookatx, lookaty, lookatz, roll, fov)
Where 3D is the parent library, camera is the REQUIRED sublib (because without camera you're at 0, 0, 0 looking at 0,0,0 and can't control it.)
positionX: The x coordinate of the camera's position.
positionY: The y coordinate of the camera's position.
positionZ: The z coordinate of the camera's position.
Optional Arguments
lookAtX: The x coordinate of the point the camera faces.
lookAtY: The y coordinate of the point the camera faces.
lookAtZ: The z coordinate of the point the camera faces.
roll: The camera roll angle, -180 to 180. A value of 0 means the camera sits straight, positive values will turn it counter-clockwise and negative values will turn it clockwise. -180 or 180 means the camera is upside down.
fov: the field of view angle, 0 to 180. The higher this value is, the more you will be able to see what is to your sides.
Lua is not an acronym.
- substitute541
- Party member
- Posts: 484
- Joined: Fri Aug 24, 2012 9:04 am
- Location: Southern Leyte, Visayas, Philippines
- Contact:
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
Lol good job. Apparently, putting points in the table was good. I will try to edit it so it will fit other polygonal shapes. When I do, i will give you credit when I put the zSort function. . Working on the 2nd version of Perspective.lua ...Nixola wrote:About perspective9, calculating the average Z position of every face's extremes (vertices? vertexes?), sorting the faces checking averageZ and then drawing them should do the trick
P.S: Use conf.lua and love.conf to set width and height
I know nothing about this topic. This is just a stupid idea that actually works.
And it's vertices...
Currently designing themes for WordPress.
Sometimes lurks around the forum.
Sometimes lurks around the forum.
- substitute541
- Party member
- Posts: 484
- Joined: Fri Aug 24, 2012 9:04 am
- Location: Southern Leyte, Visayas, Philippines
- Contact:
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
qaisjp wrote:You should consider a framework, instead of a hard-to-use perspective function. Such as a camera occupying 3D space and objects occupying 3D space. Then you can move the camera to view objects from a different angle. Something like this:
3D.camera.setMatrix(positionX, positionY, positionZ, lookatx, lookaty, lookatz, roll, fov)
Where 3D is the parent library, camera is the REQUIRED sublib (because without camera you're at 0, 0, 0 looking at 0,0,0 and can't control it.)positionX: The x coordinate of the camera's position.
positionY: The y coordinate of the camera's position.
positionZ: The z coordinate of the camera's position.
Optional Arguments
lookAtX: The x coordinate of the point the camera faces.
lookAtY: The y coordinate of the point the camera faces.
lookAtZ: The z coordinate of the point the camera faces.
roll: The camera roll angle, -180 to 180. A value of 0 means the camera sits straight, positive values will turn it counter-clockwise and negative values will turn it clockwise. -180 or 180 means the camera is upside down.
fov: the field of view angle, 0 to 180. The higher this value is, the more you will be able to see what is to your sides.
That would be hard, but it's possible. . .
Currently designing themes for WordPress.
Sometimes lurks around the forum.
Sometimes lurks around the forum.
- substitute541
- Party member
- Posts: 484
- Joined: Fri Aug 24, 2012 9:04 am
- Location: Southern Leyte, Visayas, Philippines
- Contact:
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
New PerspectiveTwo.lua .. As before, haven't tested it yet, but it has the zSort functions. Credit to Nixola! .
Currently designing themes for WordPress.
Sometimes lurks around the forum.
Sometimes lurks around the forum.
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
Love2D doesn't consist of one function to draw one pixel, which then you can design your own patterns (for example a for loop for rectangles) - it consists of one simple function. perspective.lua just gives you x, y, w, h and some other stuff - not a real Love3D project/framework.
It isn't very hard. You just need to make use of simple matrixes and have a frontend and backend.
I would actually help you out, but only once I am complete with my current project FULLY.
It isn't very hard. You just need to make use of simple matrixes and have a frontend and backend.
I would actually help you out, but only once I am complete with my current project FULLY.
Lua is not an acronym.
- substitute541
- Party member
- Posts: 484
- Joined: Fri Aug 24, 2012 9:04 am
- Location: Southern Leyte, Visayas, Philippines
- Contact:
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
Perspective.lua, and PerspectiveTwo.lua are being fixed.
Currently designing themes for WordPress.
Sometimes lurks around the forum.
Sometimes lurks around the forum.
Re: [6 Demos] The Love3D Project (NEW PERSPECTIVE.LUA)
Jesus christ... subsitute541, pseudo 3D projects don't use perspective functions, they create a library to handle it for them, and then the real job is just doing this: 3D.physics.createBall(x, y, z, radius)
perspective functions are useless, and the project name is very bad if you say that its only going to consists of one perspective function.. seriously.
It's not my time being wasted, anyway.
perspective functions are useless, and the project name is very bad if you say that its only going to consists of one perspective function.. seriously.
It's not my time being wasted, anyway.
Lua is not an acronym.
Who is online
Users browsing this forum: Ahrefs [Bot] and 0 guests