Tagged: tutorial Toggle Comment Threads | Keyboard Shortcuts

  • frankiezafe 19:56 on 2017-01-29 Permalink | Reply
    Tags: Camera, , matrix, , tutorial   

    New example showing how to go from world space to camera space.

    A bit of explanation.

    The black sphere is attached to the pink camera. Therefore, it is located in the camera space, meaning that its position, rotation and scale depends on the camera ones. By default, the sphere is static in the point of view of pink camera.

    The pink camera is rotating around the world center.

    An empty, represented as a XYZ axis, follows the mouse position.
    If the space bar is hit, position & orientation of the empty is converted into camera coordinates.

    Vector3 p = custom_cam.worldToCam( empty.getTrans( ) );
    Quaternion q = custom_cam.worldToCam( empty.getOrientation( ) );
    

    The values are then applied on the sphere:

    ball_cam.move( p );
    ball_cam.orientation( q );
    

    By doing so, the ball is placed at the exact same location and orientation as the empty, relatively to the pink camera.

    note: the 256×256 square at the top left of the images is made with overlay manager, not yet simplified in polymorph namespace.

    The example is available in samples/0.1/example.cam_space

     
  • frankiezafe 20:13 on 2017-01-10 Permalink | Reply
    Tags: , , tutorial   

    screenshot01102017_200308117

    screenshot01102017_200310217

    screenshot01102017_200315718

    screenshot01102017_200318951

    screenshot01102017_200328133

    screenshot01102017_200347400

    New example about compositor and shader (example.compositor).

    The example concerns the definition of a custom compositor. In Ogre3d, a compositor is a serie of post-processing nodes attached to the camera. It is the place where the image displayed at each frame is created.

    In the example, there’s a shader attach to the background of the window that renders a blurred circle. The shader params can be modifed RT via the mouse.

    • Moving the mouse change the red and green channels of the center color.
    • Dragging with left button modify the radius of the circle.
    • Dragging with right button modify the center of the circle.
      • Compositor is a really strong feature of Ogre, even if it’s a quite difficult one!

     
  • frankiezafe 12:54 on 2017-01-04 Permalink | Reply
    Tags: , , , tutorial   

    012-new-project_734

    Updates the engine wiki done:

    • guide for project setup with cmake
    • guide for project import in netbeans

    I realise that the installation procedure is not complete yet, and it must be done before fosdem. It’s becoming urgent!

     
  • frankiezafe 19:35 on 2016-11-20 Permalink | Reply
    Tags: , , tutorial   

    selection_709

    Here is the output and the code of the empty example. It is using polymorph package.

    Once installed (the tricky part, soon fixed with a magic installation script), you just have to extends PolymorphApplication class and start working.

    As you may notice, the class CustomApp does nothing on its own. It just calls the mother class’ methods. The purpose of this empty project is to enlight crucial methods to overwrite in order to start coding something.

    I’m now working on a basic example, showing how to add primitives, load meshes, add lights and animate them.

     
    • frankiezafe 21:34 on 2016-11-20 Permalink | Reply

      @xuv & @balt : i think it’s important to be obvious on what is polymorph and what is ogre by keeping the namespaces as they are. For instance, creating a PNode requires to call polymorph::PNode. When you want to create a vec3, there you have to call Ogre::Vector3.
      In the example above, the using namespace is only used in cpp => for all class params (.h), they have to be set this way. It will be explained in the basic example.
      What d’u think?

      • xuv 14:19 on 2016-11-21 Permalink | Reply

        @frankiezafe : seems coherent.

        • frankiezafe 15:53 on 2016-11-21 Permalink | Reply

          i’ve started working on a “PObject”, wich is a common ground for PNodes, PLights and PSounds. It’s a abstract object defining anyhting located in the 3d world, with possibility to attach them together or add physics on them.
          Result: ultra tuff conceptual work, using an abstract class + a template class for PObject – will work in a few days.

  • frankiezafe 18:53 on 2016-10-12 Permalink | Reply
    Tags: , , , tutorial   

    Documentation about how to prepare meshes (structure, materials, etc.) usable by bullet in polymorph engine.

    >> https://bitbucket.org/polymorphteam/pe.2.0/wiki/blender-bullet-primitives

    The documentation of the project is not yet ready, as you might see if you surf a bit in the wiki…

    polymorph-physics-primitives-im

     
  • frankiezafe 08:56 on 2016-10-06 Permalink | Reply
    Tags: , tutorial   

    Notes about cones for tutorial.

    mine-screenshot02

    mine-screenshot01

    Report:
    Original Vertices: 1155
    Exported Vertices: 6527
    Original Faces: 2192
    Exported Triangles: 2222
    MESHES: 2
    MATERIALS: 22
    Extended Report:
    MESHES:
    . mine-physics
    . mine
    MATERIALS:
    . sphere_physcis01
    . cone_physics01
    . cone_physics02
    . cone_physics03
    . cone_physics04
    . cone_physics05
    . cone_physics06
    . cone_physics07
    . cone_physics08
    . cone_physcis09
    . cone_physcis10
    . cone_physcis11
    . cone_physcis12
    . cone_physics13
    . cone_physcis14
    . cone_physcis15
    . cone_physics16
    . cone_physics17
    . cone_physcis18
    . cone_physics19
    . cone_physics20
    . mine-mat

     
  • frankiezafe 18:17 on 2016-10-03 Permalink | Reply
    Tags: , , , tutorial,   

    How to prepare meshes and its physical version in blender usable in polymorph engine?

    How it’s looking like once done in the right way:

    For this mesh (a kind of quad pods not very well done):

    triball-screenshot01

    You can resume the shape with:

    • 4 boxes, surrounding the legs of the shape
    • and 4 spheres, surrounding the ends of each legs.

    To do so, design the collider using cubes and sphere (low resolution ones, i’ve used 10×5 just because it will look nicer in the screenshots :)).

    Attribute a different material to each part using this naming convention:

    • material for boxes starts with “box_”;
    • material for spheres starts with “sphere_”.

    The different colors of materials is just to make the screenshot clearer.

    triball-screenshot02

    Apply a triangulate modifier to ensure you don’t have any ngon in your meshes.

    Once all this is done, export the meshes using blender2ogre addon.

    The importation steps will be described in the full tutorial, with the complete documentation.

     
c
Compose new post
j
Next post/Next comment
k
Previous post/Previous comment
r
Reply
e
Edit
o
Show/Hide comments
t
Go to top
l
Go to login
h
Show/Hide help
shift + esc
Cancel