Creating an app for organizing rooms

Hello

I would like to create a simple online app where users could define rooms size (x,y and z) and then place different objects (table, bed, closet …) in the room. Of course there needs to be a collision detection. Something very similar to Sims :slight_smile:

Is this possible with WebGL?

Thank you for your answer

Yes - it’s definitely possible. WebGL can draw anything you can describe with triangles, textures and shaders…which is pretty much anything. JavaScript is a general programming language - so you could certainly write collision detection code using it (although speed might be an issue). You can do your GUI design in HTML.

However, since you had to ask whether it’s possible, I would bet that you have no idea how much work it’s going to be!

Let’s look at what’s involved:

  • You need to be able to make 3D models of beds, tables, etc. How good are your 3D art skills? You’re going to need “blender”, “Maya” or “3DStudio” (probably). A good 3D artist could probably turn out simple blocky models of furniture at a rate of an object every hour or two, including textures. Realistic-looking furniture might take a day or more per object.
  • You’ll need lots of textures…painting them or grabbing stuff from photos requires some expertise in Photoshop or GIMP - and again, it can be a relatively fast process if you’re not looking for much realism - or a gigantic process if you want quality.
  • You’ll be writing lots of software - I’d guess probably 5,000 to 10,000 lines of JavaScript code and a few hundred lines of GLSL shader code. Certainly months of work…assuming you’re a reasonably expert programmer with some good graphics background and a working knowledge of JavaScript.
  • You’ll probably need some web design skills - HTML5, <canvas>, CSS…that stuff’s easy enough to learn - but it can take an inordinate amount of fiddling around to make nice pages.

But for sure it’s possible. I’m rendering detailed room interiors with lots of moveable furniture using WebGL in my online game “BarFight” at http://tubagames.net - you’d need more accurate collision detection than I do - but it’s no different in principle.

– Steve

Hi Steve

Thank you for your reply. Because I’m doing prototype, the detail work on the furniture is not important. For now I could just use blocks :slight_smile:

Main goal is to able users to move different objects (drag and drop) and support collision detection between objects and between object and the part of the room (window, door…).

Btw, really nice game

Best regards