<commit_before>/*
 *  World.cpp
 *  Kepler
 *
 *  Created by <NAME> on 2/25/11.
 *  Copyright 2011 __MyCompanyName__. All rights reserved.
 *
 */


#include <deque>
#include "World.h"
#include "NodeArtist.h"
#include "cinder/gl/gl.h"
#include "cinder/Rect.h"
#include "cinder/Text.h"
#include "cinder/Rand.h"
#include "Globals.h"
#include "BloomSphere.h"

using std::stringstream;
using namespace ci;
using namespace ci::app;
using namespace ci::ipod;
using namespace std;

World::World()
{
    mPrevTotalStarVertices	= -1;
    mStarVerts				= NULL;
    mStarTexCoords			= NULL;
	mStarColors				= NULL;
	
	mPrevTotalConstellationVertices = -1;
	mConstellationVerts			= NULL;
	mConstellationTexCoords		= NULL;
    
}

void World::setup( Data *data )
{
    mData = data;

    // FIXME: this check for mIsInitialized looks wrong (it's set to false below)
    // ... when is it set to true? ... in anycase, these should only be set once :)
	if( !mIsInitialized ){
		// VERTEX ARRAY SPHERE
		if( G_IS_IPAD2 ){
            mHiSphere.setup(32);
            mMdSphere.setup(20);
            mLoSphere.setup(16);
            mTySphere.setup(10);
		} else {
            mHiSphere.setup(32);
            mMdSphere.setup(26); // FIXME: 16?
            mLoSphere.setup(12);
            mTySphere.setup(8);
		}
	}
	
	mAge			= 0;
	mEndRepulseAge	= 50;//200
	mIsRepulsing	= true;<commit_msg>fixed med-res sphere segments in ipad1<commit_after>/*
 *  World.cpp
 *  Kepler
 *
 *  Created by <NAME> on 2/25/11.
 *  Copyright 2011 __MyCompanyName__. All rights reserved.
 *
 */


#include <deque>
#include "World.h"
#include "NodeArtist.h"
#include "cinder/gl/gl.h"
#include "cinder/Rect.h"
#include "cinder/Text.h"
#include "cinder/Rand.h"
#include "Globals.h"
#include "BloomSphere.h"

using std::stringstream;
using namespace ci;
using namespace ci::app;
using namespace ci::ipod;
using namespace std;

World::World()
{
    mPrevTotalStarVertices	= -1;
    mStarVerts				= NULL;
    mStarTexCoords			= NULL;
	mStarColors				= NULL;
	
	mPrevTotalConstellationVertices = -1;
	mConstellationVerts			= NULL;
	mConstellationTexCoords		= NULL;
    
}

void World::setup( Data *data )
{
    mData = data;

    // FIXME: this check for mIsInitialized looks wrong (it's set to false below)
    // ... when is it set to true? ... in anycase, these should only be set once :)
	if( !mIsInitialized ){
		// VERTEX ARRAY SPHERE
		if( G_IS_IPAD2 ){
            mHiSphere.setup(32);
            mMdSphere.setup(20);
            mLoSphere.setup(16);
            mTySphere.setup(10);
		} else {
            mHiSphere.setup(32);
            mMdSphere.setup(16);
            mLoSphere.setup(12);
            mTySphere.setup(8);
		}
	}
	
	mAge			= 0;
	mEndRepulseAge	= 50;//200
	mIsRepulsing	= true;
{'fraction_non_alphanumeric': 0.12712785222745382, 'fraction_numerical': 0.024990945309670408, 'mean_word_length': 2.6826666666666665, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4174292', 'n_tokens_mistral': 1117, 'n_tokens_neox': 1032, 'n_words': 236}