Changeset 1401


Ignore:
Timestamp:
May 19, 2012, 2:42:33 AM (11 years ago)
Author:
sam
Message:

core: no longer deactivate std::ostream features on Android.

Location:
trunk/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/gpu/vertexbuffer.cpp

    r1337 r1401  
    4747#elif defined _XBOX
    4848    D3DVertexBuffer *m_vbo;
    49 #elif !defined __ANDROID__
     49#else
    5050    GLuint m_vbo;
    5151    uint8_t *m_memory;
     
    474474                                               D3DPOOL_MANAGED, &m_data->m_vbo, NULL)))
    475475        Abort();
    476 #elif !defined __CELLOS_LV2__ && !defined __ANDROID__
     476#elif !defined __CELLOS_LV2__
    477477    glGenBuffers(1, &m_data->m_vbo);
    478478    m_data->m_memory = new uint8_t[size];
     
    486486    if (FAILED(m_data->m_vbo->Release()))
    487487        Abort();
    488 #elif !defined __CELLOS_LV2__ && !defined __ANDROID__
     488#elif !defined __CELLOS_LV2__
    489489    glDeleteBuffers(1, &m_data->m_vbo);
    490490    delete[] m_data->m_memory;
     
    500500        Abort();
    501501    return ret;
    502 #elif !defined __CELLOS_LV2__ && !defined __ANDROID__
     502#elif !defined __CELLOS_LV2__
    503503    return m_data->m_memory + offset;
    504504#endif
     
    510510    if (FAILED(m_data->m_vbo->Unlock()))
    511511        Abort();
    512 #elif !defined __CELLOS_LV2__ && !defined __ANDROID__
     512#elif !defined __CELLOS_LV2__
    513513    glBindBuffer(GL_ARRAY_BUFFER, m_data->m_vbo);
    514514    glBufferData(GL_ARRAY_BUFFER, m_data->m_size, m_data->m_memory,
  • trunk/src/lol/math/vector.h

    r1381 r1401  
    1919#include <stdint.h>
    2020#include <cmath>
    21 #if !defined __ANDROID__
    22 #   include <iostream>
    23 #endif
     21#include <ostream>
     22#include <algorithm>
    2423
    2524#include "lol/math/half.h"
     
    236235    DECLARE_MEMBER_OPS(Vec2, x)
    237236
    238 #if !defined __ANDROID__
    239237    template<typename U>
    240238    friend std::ostream &operator<<(std::ostream &stream, Vec2<U> const &v);
    241 #endif
    242239};
    243240
     
    270267
    271268    inline T norm() const { return length(*this); }
    272 #if !defined __ANDROID__
    273269    template<typename U>
    274270    friend std::ostream &operator<<(std::ostream &stream, Cmplx<U> const &v);
    275 #endif
    276271
    277272    T x, y;
     
    494489    DECLARE_MEMBER_OPS(Vec3, x)
    495490
    496 #if !defined __ANDROID__
    497491    template<typename U>
    498492    friend std::ostream &operator<<(std::ostream &stream, Vec3<U> const &v);
    499 #endif
    500493};
    501494
     
    903896    DECLARE_MEMBER_OPS(Vec4, x)
    904897
    905 #if !defined __ANDROID__
    906898    template<typename U>
    907899    friend std::ostream &operator<<(std::ostream &stream, Vec4<U> const &v);
    908 #endif
    909900};
    910901
     
    984975    }
    985976
    986 #if !defined __ANDROID__
    987977    template<typename U>
    988978    friend std::ostream &operator<<(std::ostream &stream, Quat<U> const &v);
    989 #endif
    990979
    991980    /* XXX: storage order is wxyz, unlike vectors! */
     
    15931582    void printf() const;
    15941583
    1595 #if !defined __ANDROID__
    15961584    template<class U>
    15971585    friend std::ostream &operator<<(std::ostream &stream, Mat2<U> const &m);
    1598 #endif
    15991586
    16001587    inline Mat2<T> operator +(Mat2<T> const m) const
     
    17181705    void printf() const;
    17191706
    1720 #if !defined __ANDROID__
    17211707    template<class U>
    17221708    friend std::ostream &operator<<(std::ostream &stream, Mat3<U> const &m);
    1723 #endif
    17241709
    17251710    inline Mat3<T> operator +(Mat3<T> const m) const
     
    18851870    void printf() const;
    18861871
    1887 #if !defined __ANDROID__
    18881872    template<class U>
    18891873    friend std::ostream &operator<<(std::ostream &stream, Mat4<U> const &m);
    1890 #endif
    18911874
    18921875    inline Mat4<T> operator +(Mat4<T> const &m) const
  • trunk/src/math/vector.cpp

    r1352 r1401  
    3030#include <cstring> /* strdup() */
    3131
     32#include <ostream> /* std::ostream */
     33
    3234#include "core.h"
    3335
     
    238240}
    239241
    240 #if !defined __ANDROID__
    241242template<> std::ostream &operator<<(std::ostream &stream, ivec2 const &v)
    242243{
     
    305306    return stream;
    306307}
    307 #endif
    308308
    309309template<> mat3 mat3::scale(float x, float y, float z)
Note: See TracChangeset for help on using the changeset viewer.