Skip to content

Implementation of Drawing engine#10

Open
gruszczrob wants to merge 2 commits into
mainfrom
drawingEngine
Open

Implementation of Drawing engine#10
gruszczrob wants to merge 2 commits into
mainfrom
drawingEngine

Conversation

@gruszczrob

Copy link
Copy Markdown
Owner

No description provided.


class DrawingEngine : public ClassFactory {
private:
shared_ptr<int> width = make_shared<int>();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not just ints, or even better unsigned ints as the width and height shall not be negative

shared_ptr<int> height = make_shared<int>();

public:
DrawingEngine(any widthI, any heightI);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why would you take any as width and height when only valid type is unsigned int?

#include <memory>
#include <any>
#include <vector>
#include "../Logs/Logs.h"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

relative paths shall not be used for includes

#include "../Logs/Logs.h"
#include "../ClassFactory/ClassFactory.h"

using namespace std;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

public:
DrawingEngine(any widthI, any heightI);

virtual void print(vector<vector<int>> grid) = 0;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DrawingEngine shall be able to draw the Drawables, not a buffer of ints.

The drawing engine shall have as a member a Framebuffer which would be a some type of container holding some representation of pixel, preferably (r,g,b) values

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants